Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » After i Inject the XML using the AM3, the created model or XMI does not conform the XMI model(XML injection output compatibility problem)
After i Inject the XML using the AM3, the created model or XMI does not conform the XMI model [message #685992] Tue, 21 June 2011 06:05 Go to next message
Emwedish Endargachew is currently offline Emwedish Endargachew
Messages: 27
Registered: April 2011
Junior Member
HI All,
I am currently working on model to model transformation using ATL. I am trying to make two way transformation where both the source and target models are represented in XML Schema and XML. for the sake of compatibility, i inject the source XML model using AM3 injector in order to create the ecore model which is represented in XMI. However, after i made this transformation i find out that the XMI model does not conform the metamodel, which is source metamodel, but to the XML model which is general. So i find additional attributes called startLine, startColumn etc in the created XMI model. So when i try to make the model to model transformation i find out that the model does not conform to the given meta model. and i really need it to be conformed. I come to the thought that may be i can use both the XML and my metamodel as input metamodels, but i am not sure whether it will work or not. If you think this can solve my problem how can i make transformation from two input metamodels? If this does not work, what do you suggest me to do, in order to make the XMI model conformed to its metamodel, which is my project metamodel.

I really appreciate fast reply,

thanks in advance,
emwedish
Re: After i Inject the XML using the AM3, the created model or XMI does not conform the XMI model [message #691267 is a reply to message #685992] Fri, 01 July 2011 02:26 Go to previous message
Emwedish Endargachew is currently offline Emwedish Endargachew
Messages: 27
Registered: April 2011
Junior Member
If there is any one who wants why it did not conform, here i got the solution. It is true the injected XML can not conform to the source meta model, because it needs one more transformation. Here is the process, first we inject our model and we got model.xmi. This model.xmi conforms to the XML meta model, therefore we need to make one more transformation to get the source model in XMI format. For the source model to get it in XMI format we need to use XML XMI model as source model and XML meta model as source metamodel and your source metamodel as target metamodel and write the ATL for this transformation. Then at the end you will able to get the source model in XMI format which conforms to the source metamodel.
Previous Topic:QVTO iteration() operation, acc returns nothing
Next Topic:multi-reference transformation problem
Goto Forum:
  


Current Time: Fri Apr 18 01:35:07 EDT 2014

Powered by FUDForum. Page generated in 0.29330 seconds