|href of elements changes when saving GMF editor [message #198166]
||Mon, 21 July 2008 18:46
Registered: July 2009
I have a metamodel A which refers to another metamodel B (here:
UML.ecore; one of the classes of A has an EReference of type
In addition, I have a metamodel C which contains a reference of type
EPackage, which shall hold references to other metamodels (here: A and
B). In addition, classes of C have a reference of type EClass which
shall hold classes contained in the mentioned packages.
Finally, I have a GMF editor for C. When creating a diagram, I choose
"Load resource" and load A. This then allows me to add A and B to the
packages reference of c. I can then type my elements accordingly.
Now the problem is that GMF saves the instance of C such like this:
href=" ../../../plugin/org.eclipse.uml2.uml/model/UML.ecore#//Activ ityNode "/>
Unfortunately, I run into problems with other code also working on
models of type C. If I replace all occurences of the href attribute with
href=" platform:/plugin/org.eclipse.uml2.uml/model/UML.ecore#//Acti vityNode "/>
, my other code works fine. But working again on such a model with my
GMF editor (and finally saving) changes everything back to the above.
I guess that my other code does not find the UML.ecore metamodel since
it is linked in a relative way. Any way around this?
And since I'm not very comfortable with the whole resource stuff: Does
anybody know a good link or two with information about that?
Thanks in advance,
John Lennon: "Life is what happens to you while you're busy making other
Powered by FUDForum
. Page generated in 0.01789 seconds