|
|
|
Re: Transforming UML2 models and profiles [message #472094 is a reply to message #472090] |
Fri, 30 March 2007 16:20 |
Dennis Wagelaar Messages: 147 Registered: July 2009 |
Senior Member |
|
|
Jean.Bezivin schreef:
> Paul,
>
> I copy your post also to the M2M and AMW newsgroups.
>
> Jean
>
>
> "Paul Gribben" <paul.gribben@gmail.com> a écrit dans le message de news:
> 7cc228c8343830cbb7ab0acc7886cafb$1@www.eclipse.org...
>> Hello.
>>
>> I have defined a UML2 profile (using UML2 editor), and used it
>> successfully generate a UML2 model with stereotypes applied, etc. I now
>> want to perform model transformations (using ATL and AMW) on the model and
>> am unsure which path to take. It seems that ATL2006 will work with UML2
>> files although I'm not sure about AMW just yet.
ATL will work, but different approaches are required for UML2 v.1.1
(Eclipse 3.1) and UML2 v.2.0 (Eclipse 3.2).
See also:
http://wiki.eclipse.org/index.php/ATL_Language_Troubleshoote r#UML2_Profiles
Example model transformations for UML2 v.2.0 can be found here:
http://ssel.vub.ac.be/viewcvs/viewcvs.py/UML2CaseStudies/uml 2cs-transformations/
>>
>> My guess is that it may be easier to convert my model file to an ecore
>> model file, which would require me to create an ecore metamodel for my
>> profile (hopefully I can find an ATL transformation to do this!).
I thought that the UML2 plugin includes tools for translating between
Ecore and UML?
UML profiles are definitely difficult for the purpose of model
transformation. They are more complex than a simple meta-model.
Modelling of profiles is done on UML level. You can't apply any
stereotypes directly from the profile, however, since Stereotype
instances cannot exist at the UML level (M2). That's why you need to
"define" your profile, which generates an Ecore representation of your
profile. Now that your Stereotypes are promoted to EClasses (M3 level),
they can be instantiated at UML level (M2).
If you stick to meta-models vs. models, you don't need any meta-level
voodoo like this. Mind you: the voodoo is correct and all (cf. Welty's
"spanning objects"), but not easy to understand.
>>
>> Could anyone advise on the the best approach to adopt?
>> Thanks
>> Paul
>>
>
>
If you plan to transform your UML + profiles to Ecore first by using
ATL, then the damage is already done: you need to access your stereotype
applications. You might as well transform your UML model directly.
If you can use the UML2 tools to convert your models/profiles to Ecore,
then that makes model transformation in ATL easier.
--
Cheers,
Dennis
|
|
|
|
|
|
Re: Transforming UML2 models and profiles [message #604151 is a reply to message #472090] |
Fri, 30 March 2007 16:20 |
Dennis Wagelaar Messages: 147 Registered: July 2009 |
Senior Member |
|
|
Jean.Bezivin schreef:
> Paul,
>
> I copy your post also to the M2M and AMW newsgroups.
>
> Jean
>
>
> "Paul Gribben" <paul.gribben@gmail.com> a écrit dans le message de news:
> 7cc228c8343830cbb7ab0acc7886cafb$1@www.eclipse.org...
>> Hello.
>>
>> I have defined a UML2 profile (using UML2 editor), and used it
>> successfully generate a UML2 model with stereotypes applied, etc. I now
>> want to perform model transformations (using ATL and AMW) on the model and
>> am unsure which path to take. It seems that ATL2006 will work with UML2
>> files although I'm not sure about AMW just yet.
ATL will work, but different approaches are required for UML2 v.1.1
(Eclipse 3.1) and UML2 v.2.0 (Eclipse 3.2).
See also:
http://wiki.eclipse.org/index.php/ATL_Language_Troubleshoote r#UML2_Profiles
Example model transformations for UML2 v.2.0 can be found here:
http://ssel.vub.ac.be/viewcvs/viewcvs.py/UML2CaseStudies/uml 2cs-transformations/
>>
>> My guess is that it may be easier to convert my model file to an ecore
>> model file, which would require me to create an ecore metamodel for my
>> profile (hopefully I can find an ATL transformation to do this!).
I thought that the UML2 plugin includes tools for translating between
Ecore and UML?
UML profiles are definitely difficult for the purpose of model
transformation. They are more complex than a simple meta-model.
Modelling of profiles is done on UML level. You can't apply any
stereotypes directly from the profile, however, since Stereotype
instances cannot exist at the UML level (M2). That's why you need to
"define" your profile, which generates an Ecore representation of your
profile. Now that your Stereotypes are promoted to EClasses (M3 level),
they can be instantiated at UML level (M2).
If you stick to meta-models vs. models, you don't need any meta-level
voodoo like this. Mind you: the voodoo is correct and all (cf. Welty's
"spanning objects"), but not easy to understand.
>>
>> Could anyone advise on the the best approach to adopt?
>> Thanks
>> Paul
>>
>
>
If you plan to transform your UML + profiles to Ecore first by using
ATL, then the damage is already done: you need to access your stereotype
applications. You might as well transform your UML model directly.
If you can use the UML2 tools to convert your models/profiles to Ecore,
then that makes model transformation in ATL easier.
--
Cheers,
Dennis
|
|
|
|
Powered by
FUDForum. Page generated in 0.05998 seconds