Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc)  » Mwe2.xtext:15 type reference ecore
Mwe2.xtext:15 type reference ecore [message #622980] Thu, 03 June 2010 06:06 Go to next message
Pierrick is currently offline Pierrick
Messages: 15
Registered: May 2010
Junior Member
Hi,

I didn't know where to post this message, TMF / EMF or EMFT, so here I am.

I would like to know how the reference to ecore type is done for the xtext gramar ( http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.emf/org .eclipse.emf.mwe/plugins/org.eclipse.emf.mwe2.language/src/o rg/eclipse/emf/mwe2/language/Mwe2.xtext?revision=1.12&ro ot=Modeling_Project&view=markup line 15)

import " platform:/resource/org.eclipse.xtext.common.types/model/Java VMTypes.ecore " as types

DeclaredProperty:
'var' (type=[types::JvmType|FQN])? name=FQN ('=' default=Value)?;
(type=[types::JvmType|FQN])

I was looking in the http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.tmf/org .eclipse.xtext/plugins/org.eclipse.xtext.common.types/?root= Modeling_Project package, where I found the model, and the Java class.

But I don't get how the link is made between those two plugins, for instance when I try to reuse this simple line, I got an error in generation saying that I should register the package.
The generated EPackage references an external EPackage, but 'referencedGenModels' hasn't been registered.

according to the http://www.eclipse.org/Xtext/documentation/latest/xtext.html #syntax , I modified the mwe2 generator file, but no change.

Thank you for your answers,
Pierrick
Re: Mwe2.xtext:15 type reference ecore [message #622985 is a reply to message #622980] Fri, 04 June 2010 03:52 Go to previous message
Sven Efftinge is currently offline Sven Efftinge
Messages: 1759
Registered: July 2009
Senior Member
Pierrick schrieb:
> Hi,
>
> I didn't know where to post this message, TMF / EMF or EMFT, so here I am.

TMF would have been best.

>
> I would like to know how the reference to ecore type is done for the
> xtext gramar
> ( http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.emf/org .eclipse.emf.mwe/plugins/org.eclipse.emf.mwe2.language/src/o rg/eclipse/emf/mwe2/language/Mwe2.xtext?revision=1.12&ro ot=Modeling_Project&view=markup
> line 15)
>

We have just written up some documentation for this topic.
Please see the Eclipse Help in the latest RC3 build.

Feedback is highly appreciated!

Sven

--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de


--
Need professional support on Xtext or Xtend?
Mail to: xtext (at) itemis.com
Twitter : @svenefftinge
Blog : blog.efftinge.de
Previous Topic:Mwe2.xtext:15 type reference ecore
Next Topic:How validation constraints may have been disabled
Goto Forum:
  


Current Time: Tue Jul 22 05:27:11 EDT 2014

Powered by FUDForum. Page generated in 0.02153 seconds