Skip to main content



      Home
Home » Modeling » TMF (Xtext) » No elements in the index when doing Project Clean(No model elements in the index (resourceDescriptions) when doing Project Clean)
No elements in the index when doing Project Clean [message #1741748] Mon, 29 August 2016 05:07 Go to next message
Eclipse UserFriend
Greetings,

I have an issue when I am doing project Clean and a full rebuild commences. When I infer types I need to look up in the global index to find an element. I do it this way:

resourceDescriptions.getExportedObjects(MyDslPackage.Literals.TYPE_X, elementQualifiedName, false).forEach [

var typeXObject = EcoreUtil.resolve(it.getEObjectOrProxy(), modelElement.eResource.resourceSet) as Type_X
]

When I invoke a build manually or modify/save a model file all works fine and the elements are found in the index.

When I run Project Clean, it cleans up the generated sources folder and then starts a full build. At that point the index isn't populated.

resourceDescriptions is wired into the Inferrer in the following way:

@Inject IResourceDescriptions resourceDescriptions

I would appreciate guidance on how to fix the issue.

Best regards,
Oleg Cohen

[Updated on: Mon, 29 August 2016 05:09] by Moderator

Re: No elements in the index when doing Project Clean [message #1741750 is a reply to message #1741748] Mon, 29 August 2016 05:21 Go to previous messageGo to next message
Eclipse UserFriend
are you sure you respect the inferrer phases?
Re: No elements in the index when doing Project Clean [message #1741787 is a reply to message #1741750] Mon, 29 August 2016 11:21 Go to previous messageGo to next message
Eclipse UserFriend
I am not entirely sure. Is there a good guide or a good example on how this must be done properly? At what phase does the index get built?

Thank you!
Oleg
Re: No elements in the index when doing Project Clean [message #1741788 is a reply to message #1741787] Mon, 29 August 2016 11:27 Go to previous message
Eclipse UserFriend
the esiest in you share a minimal example (e.g. based on domainmodel) reproducing your problem
Previous Topic:Quickfix for syntactical errors
Next Topic:xtext unnamed tree
Goto Forum:
  


Current Time: Tue Jul 29 06:29:49 EDT 2025

Powered by FUDForum. Page generated in 0.04372 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top