Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » using acceleo to M2M(acceleo)
using acceleo to M2M [message #676237] Fri, 03 June 2011 06:54 Go to next message
charfi asma is currently offline charfi asma
Messages: 17
Registered: July 2009
Junior Member
Hello,
I have a uml model (MyModel.uml) that contains: class + state machine + activity diagrams. I waould like to transform my model to another model (MyModel.ggraph(not uml) which is conform to an ecore metamodel (Ggraph.ecore) that I created using EMF tools. I generated code related to my metamodel (EMF genmodel) to edit and create my instance model by hand (after running another eclipse instance).
what I would like to do, is to generate MyModel.ggraph automatically from the UML model and not manually using the GGraph Editor that EMF do generate.

I am aware that it is M2M and not M2T (I have both metamodel : uml2 and ggraph as well as my uml model, so I can use ATL, QVT to generate my ggraph model) but I have not enough time to learn a M2M tranfo tool, I used Acceleo for many projects to transfrom uml models to java, c++ and other text formats, so my question is can I use acceleo for this kind of transfo ? if yes, should I create resources ? can I do it using java ( a plugin that I run on uml model to produce ggraph model) ?

thank you very much

Asma
Re: using acceleo to M2M [message #676322 is a reply to message #676237] Fri, 03 June 2011 12:37 Go to previous messageGo to next message
Ed Merks is currently offline Ed Merks
Messages: 25916
Registered: July 2009
Senior Member
Asma,

Sure you could use any template language to produce a correct XMI/XML
serialization of your ggraph model and stuff those results into a
*.ggraph resource, but seems quite a complicated way of doing it. You
don't have to use a transformation language; you could just use the Java
APIs for the two models (much like we do in XSDEcoreBuilder and
EcoreSchemaBuilder to transform *.xsd to *.ecore or *.ecore to *.xsd).


charfi asma wrote:
> Hello,
> I have a uml model (MyModel.uml) that contains: class + state machine
> + activity diagrams. I waould like to transform my model to another
> model (MyModel.ggraph(not uml) which is conform to an ecore metamodel
> (Ggraph.ecore) that I created using EMF tools. I generated code
> related to my metamodel (EMF genmodel) to edit and create my instance
> model by hand (after running another eclipse instance). what I would
> like to do, is to generate MyModel.ggraph automatically from the UML
> model and not manually using the GGraph Editor that EMF do generate.
>
> I am aware that it is M2M and not M2T (I have both metamodel : uml2
> and ggraph as well as my uml model, so I can use ATL, QVT to generate
> my ggraph model) but I have not enough time to learn a M2M tranfo
> tool, I used Acceleo for many projects to transfrom uml models to
> java, c++ and other text formats, so my question is can I use acceleo
> for this kind of transfo ? if yes, should I create resources ? can I
> do it using java ( a plugin that I run on uml model to produce ggraph
> model) ?
>
> thank you very much
>
> Asma
Re: using acceleo to M2M [message #760699 is a reply to message #676322] Sun, 04 December 2011 06:18 Go to previous message
radwane  is currently offline radwane
Messages: 27
Registered: April 2011
Junior Member
hi! charfi asma help me please im searching the metamodel of C++ thx.
Previous Topic:'.emtl' not found
Next Topic:[ACCELEO] Argument cannot be null
Goto Forum:
  


Current Time: Wed Jul 23 14:04:22 EDT 2014

Powered by FUDForum. Page generated in 0.02967 seconds