Metamodel composition using ATL [message #101461] |
Mon, 09 March 2009 12:23  |
Eclipse User |
|
|
|
Hi,
I'm currently trying to realise a small POC application dealing with
metamodel merging/composition in ATL.
Problem description:
I have two meta models which conform to the ecore (EMF) meta metamodel.
Each of these meta models has a concept named CC, defined using an
EClass. I'll refer to the two meta models as MetamodelA and MetamodelB.
My goal is to create an transformation which "copies" the CC EClass
instance of MetamodelA to MetamodelB, using an ATL rule which
principally would look something like this:
MetamodelB!CC <- MetamodelA!CC
MetamodelA is the INput model, while MetamodelB is the OUTput model.
Furthermore, this means that ecore (EMF) must be specified as the meta
model for MetamodelA and MetamodelA in the ATL configuration (under the
Model Choice tab -> Path Editor).
My questions are:
- Is this kind of transformation possible, and how can ecore be
specified as meta model for MetamodelA and MetamodelB?
- Is it possible to have ecore or MOF models with nested (inner)
classes? I've inspected the ecore meta metamodel and it seems like this
is not possible. However, I've read that it is possible to have nested
packages. What I seek is a way of defining inner classes. Any
suggestions are welcome!
Any hint or comments are highly appreciated! :)
tee
|
|
|
|
Re: Metamodel composition using ATL [message #101909 is a reply to message #101697] |
Mon, 16 March 2009 08:19  |
Eclipse User |
|
|
|
Great, thank you!
Yes, I was a bit confused with regard to the ecore meta model, but I
clearly see that it is possible to define meta models which support
nested classes.
On 12.03.2009 22:02, Ronan wrote:
> Hi,
> Okay I think you need to consider a few things.
>
> 1) Your meta-model in this case should be a Java meta-model defined in
> ecore. See http://www.eclipse.org/m2m/atl/atlTransformations/#Java2Tabl e
> for inspiration
>
> 2) I don't see why you can't define inner classes in your Java
> meta-model using ecore. Your perhaps confusing the fact that MOF and
> Ecore don't have inner class structures as being the reason that such
> definitions are not possible. In fact you can use ecore to model such a
> structure
>
> 3) I think you should have a read of the wikis for a good overview of
> M2M in general as well as ATL, see http://wiki.eclipse.org/index.php/ATL
>
> Cheers,
> Ronan
>
|
|
|
Powered by
FUDForum. Page generated in 0.03578 seconds