Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Strange Xtext error
Strange Xtext error [message #1007296] Tue, 05 February 2013 12:23 Go to next message
Nicolas is currently offline Nicolas
Messages: 21
Registered: July 2009
Junior Member
I have two plugins A and B :
- A contains an ecore model mmA.ecore that defines a single EClass named classA
- B depends on plugin A and contains an ecore model mmB.ecore that defines
an EClass named classB with classA as its superclass.

I build these two plugins and install them in the running eclipse.

In a separate workspace. initially empty, and using the eclipse in which plugins A
and B have been installed, I create a third plugin C, with an ecore model mmC.ecore
that defines a class named classC, the superclass of which is classB.

As soon as I add the Xtext nature to the project of plugin C, there is a error that
appears in the Problems view :

The feature 'eAllSuperTypes' of 'org.eclipse.emf.ecore.impl.EClassImpl@43b8d0fa{platform:/resource/pluginC/model/mmC.ecore#//classC}'
contains an unresolved proxy
'org.eclipse.emf.ecore.impl.EClassImpl@58c50c93{archive:file:/<absolute-path-of-the-eclipse-installation>/plugins/pluginB_1.0.0.201302050856.jar!/../pluginA/model/mmA.ecore#//classA}'

What's going wrong ?

Eclipse if juno SR1, and Xtext is version 2.3.1.v201208210947

Thanks for any hint.

Nicolas.
Re: Strange Xtext error [message #1007317 is a reply to message #1007296] Tue, 05 February 2013 13:53 Go to previous message
Jan Koehnlein is currently offline Jan Koehnlein
Messages: 656
Registered: July 2009
Senior Member
The problem is that the Ecore editor uses relative URIs to refer to
EModelElements in other ecore files. This doesn't work with Xtext once
they are installed. As a workaround, open your Ecore files with a text
editor and replace all relative URIs with platform resource URIs, e.g.
by replacing all occurrences of "../../" with "platform:/resource/"
before exporting and installing the plug-ins. The bad thing is, you have
to fix all these URIs ever time you have saved an Ecore editor with the
resource loaded.

Am 05.02.13 13:23, schrieb Nicolas:
>
> I have two plugins A and B :
> - A contains an ecore model mmA.ecore that defines a single EClass named
> classA
> - B depends on plugin A and contains an ecore model mmB.ecore that defines
> an EClass named classB with classA as its superclass.
>
> I build these two plugins and install them in the running eclipse.
>
> In a separate workspace. initially empty, and using the eclipse in which
> plugins A
> and B have been installed, I create a third plugin C, with an ecore
> model mmC.ecore
> that defines a class named classC, the superclass of which is classB.
>
> As soon as I add the Xtext nature to the project of plugin C, there is a
> error that
> appears in the Problems view :
>
> The feature 'eAllSuperTypes' of
> 'org.eclipse.emf.ecore.impl.EClassImpl@43b8d0fa{platform:/resource/pluginC/model/mmC.ecore#//classC}'
>
> contains an unresolved proxy
> 'org.eclipse.emf.ecore.impl.EClassImpl@58c50c93{archive:file:/<absolute-path-of-the-eclipse-installation>/plugins/pluginB_1.0.0.201302050856.jar!/../pluginA/model/mmA.ecore#//classA}'
>
>
> What's going wrong ?
>
> Eclipse if juno SR1, and Xtext is version 2.3.1.v201208210947
>
> Thanks for any hint.
>
> Nicolas.


--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com
Previous Topic:Documentation View
Next Topic:Adding static imports to XExpressions scope
Goto Forum:
  


Current Time: Fri Sep 19 03:47:32 GMT 2014

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

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