I use ATL to transform an ecore model. My problem is that there are severeal references with the same name but in different classes. in my target metamodel(OWL) references are modeled as independend concepts, so I have a problem with my transformation. I haven't found a way to name each resulting reference uniquely. At the moment my references are all mixed together. Is there a solution to this in ATL or do you think it's easier to change the ecore model?

Le 22/09/2010 22:00, moggi a écrit :
> I use ATL to transform an ecore model. My problem is that there are
> severeal references with the same name but in different classes. in my
> target metamodel(OWL) references are modeled as independend concepts, so
> I have a problem with my transformation. I haven't found a way to name
> each resulting reference uniquely. At the moment my references are all
> mixed together. Is there a solution to this in ATL or do you think it's
> easier to change the ecore model?

Can you give few examples so we may visualize the problem?
--
Cordialement

Here a n ObjectProperty represents a reference. It's no longer part of the class, but an independendt concept. But I want that my two references are not not modeled into the same object, so I suppose I must give the resulting reference an unique name.

I suppose your ecore file is processed as a model (with Ecore.ecore as
metamodel).
So you can transform directly each EReference into corresponding element
in ontology (I'm not familiar with ontologies):

rule EReference2ObjectProperty {
from
er : ecore:EReference
to
op : owl:ObjectProperty (
< different attributes where to store
the EClass of the "er" object >
)
}
As this, you process each reference (despite names are equals) and you
can access every element you need within the reference (type,
multiplicity,...).
--
Cordialement