[Xtext 2.4.1] Resolve cross references without 'name' in target file [message #1200955] |
Thu, 21 November 2013 08:59  |
Eclipse User |
|
|
|
Hey again,
I need a few hints for a quite tricky situation. I am currently developing a grammar for a multiple file language. Basically, the involved files and folders are organized as follows:
/project/root/root
/project/subfolder/data
/project/another_subfolder/data
The 'root' file contains the names of all the subfolders that are contained within the project:
PROJECT_PART {
... some information ...
NAME=SUBFOLDER
}
PROJECT_PART {
... some information ...
NAME=ANOTHER_SUBFOLDER
}
I want to establish cross references from the root file to specific files within the project.
The problem now is that the names are NOT contained within the 'data' files, but are derived from their path.
I played around with a custom scope provider, but this does not solve the problem as it is 'too late' to deal with the situation when the scope provider is executed.
A possible solution would be adding the derived name to a PROJECT_PART entity at parse-time. Is there a way to do so? Is there a better solution? Is there a solution at all?
Many thanks in advance!
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04109 seconds