Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Editor gives problems, when using external metamodel, eventhough MM is registered.(A registered, external metamodel causes the editor to show red error lines, whilst it shouldn't)
Editor gives problems, when using external metamodel, eventhough MM is registered. [message #499836] Tue, 24 November 2009 10:36 Go to next message
Marten Sijtema is currently offline Marten Sijtema
Messages: 67
Registered: November 2009
Member
Hello,

If I use a metamodel from an external project using:

	<!-- set up EMF for standalone execution -->
	<bean class="org.eclipse.emf.mwe.utils.StandaloneSetup" >
		<platformUri value=".."/>
	       <registerEcoreFile value="platform:/resource/ecore2gwt/metamodels/myMM..ecore" /> 
	</bean>


then my editor shows all these red 'error lines' in the .xpt file.
But, if i run the transformation it does work. But still, this is annoying, because if I do make an error, my Problems view reports a bunch of irrelevant errors also, possibly 'hiding' the error i want to catch.

If i copy the metamodel inside the xpand project's metamodel dir, and put comments around the <registerEcoreFile > element, it works. But i would like to keep it external, since i'm still working on the metamodel.

Hope someone can help

Regards,

Marten


My company: Sytematic, building business software from models.
Re: Editor gives problems, when using external metamodel, eventhough MM is registered. [message #500076 is a reply to message #499836] Tue, 24 November 2009 21:05 Go to previous message
Sven Efftinge is currently offline Sven Efftinge
Messages: 1762
Registered: July 2009
Senior Member
The editor will only see *.ecore files which are on the classpath of the
project where you have the templates.
It does not use any information from *.mwe files.

Cheers,
Sven

Marten Sijtema schrieb:
> Hello,
>
> If I use a metamodel from an external project using:
>
>
> <!-- set up EMF for standalone execution -->
> <bean class="org.eclipse.emf.mwe.utils.StandaloneSetup" >
> <platformUri value=".."/>
> <registerEcoreFile
> value="platform:/resource/ecore2gwt/metamodels/myMM..ecore" /> </bean>
>
>
> then my editor shows all these red 'error lines' in the .xpt file.
> But, if i run the transformation it does work. But still, this is
> annoying, because if I do make an error, my Problems view reports a
> bunch of irrelevant errors also, possibly 'hiding' the error i want to
> catch.
>
> If i copy the metamodel inside the xpand project's metamodel dir, and
> put comments around the <registerEcoreFile > element, it works. But i
> would like to keep it external, since i'm still working on the metamodel.
>
> Hope someone can help
>
> Regards,
>
> Marten
>


--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com


--
Need professional support on Xtext or Xtend?
Mail to: xtext (at) itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
Previous Topic:which metamodell to use
Next Topic:[XPAND] Reader does not find UML Profile Package
Goto Forum:
  


Current Time: Sat Sep 20 06:03:12 GMT 2014

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

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