Registering EMF EPackage for Xtext [message #1027409] |
Tue, 26 March 2013 23:50 |
Roza Ghamari Messages: 82 Registered: January 2013 |
Member |
|
|
I am re-posting this message here.
Hi everyone,
This might be a repeated question but I really tried to do my best to find an answer before posting, didn't succeed as you can see.
I have created two EMF models using ecore, model2 referencing model1 and they both have a single genmodel. Now, I want to use these ecore models in my xtext grammar partially for the parts that are exactly matching with the grammar. I also generate another model as the AST for my DSL. As a result the generated AST has references to model1 and model2.
After much of search and reading, I found that it is recommended to use namesapceURI for referring to a model in xtext. I am doing so and the workflow runs correctly (after including genmodel and registering packages in standalone setup and setting the platform URI correctly). However, as you know xtext editor looks for registered packages to find the namespace URI, which in my case it fails to find. I find it very annoying and misleading to get errors in my editor and as a result package explorer, while everything is fine. My understanding is that I need to register my packages, but how I don't know. Do you have any link to tutorials on how to register the ecore models on your development instance of eclipse? Can you explain the steps here? I really couldn't find anything.
I know that it is possible to register the model in standalone setup of wrokflow, but hwat I want is registering model (i.e. processing the package registry extension pint of ecore model) for my editor.
This is something that took 3 days of me and my colleagues! I am sure if you answer this you'll help many others.
Thanks in advance!
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02893 seconds