[ATL]Specification attribute not set in uml:Activity [message #97666] |
Thu, 15 January 2009 10:25 |
Eclipse User |
|
|
|
Hello,
I am doing an ATL transformation for an UML Activity diagram.
This model transformation contains a reference to another UML class file,
that is the attribute "Specification" of the UML Activity element is
referencing a method of a UML class.
Unfortunately, after the ATL transformation is finished, the
"Specification" attribute is not set in the target model.
I am using Eclipse 3.4.1 and ATL 2.0.2 and I tried the EMF-specific VM and
the regular ATL VM.
I also set the check mark " Allow inter-Model references" but it doesn't
help.
My ATL rule:
rule Act2Act {
from s : UML2!"uml::Activity"
to out: UML2!"uml::Activity"(
name <- s.name,
node<-s.node,
edge<-s.edge,
partition<-s.partition,
--this will be ignored by the ATL:
specification<-s.specification)
}
Cheers,
Thomas
|
|
|
Re: [ATL]Specification attribute not set in uml:Activity [message #97698 is a reply to message #97666] |
Thu, 15 January 2009 13:25 |
Tristan Faure Messages: 460 Registered: July 2009 |
Senior Member |
|
|
hi thomas
specification is a reference but not a containment
check you have a rule which transforms the element targeted by
s.specification and which affects the object in other in a containment
reference
Thomas Winkler a écrit :
> Hello,
>
> I am doing an ATL transformation for an UML Activity diagram.
> This model transformation contains a reference to another UML class
> file, that is the attribute "Specification" of the UML Activity element
> is referencing a method of a UML class.
>
> Unfortunately, after the ATL transformation is finished, the
> "Specification" attribute is not set in the target model.
>
> I am using Eclipse 3.4.1 and ATL 2.0.2 and I tried the EMF-specific VM
> and the regular ATL VM.
>
> I also set the check mark " Allow inter-Model references" but it doesn't
> help.
>
> My ATL rule:
>
> rule Act2Act {
>
> from s : UML2!"uml::Activity"
>
> to out: UML2!"uml::Activity"(
> name <- s.name,
> node<-s.node,
> edge<-s.edge,
> partition<-s.partition,
>
> --this will be ignored by the ATL:
> specification<-s.specification)
> }
>
>
> Cheers,
>
> Thomas
>
>
>
|
|
|
Re: [ATL]Specification attribute not set in uml:Activity [message #97712 is a reply to message #97698] |
Thu, 15 January 2009 23:45 |
Eclipse User |
|
|
|
Hi Tristan,
Thanks for your reply but the the s.specification element (method from a
class) won't be transformed so I have no rule for it.
And there are no other rules affecting that method in my ATL rules.
Regards,
Thomas
Tristan FAURE wrote:
> hi thomas
> specification is a reference but not a containment
> check you have a rule which transforms the element targeted by
> s.specification and which affects the object in other in a containment
> reference
|
|
|
|
Re: [ATL]Specification attribute not set in uml:Activity [message #97967 is a reply to message #97847] |
Wed, 21 January 2009 11:38 |
Eclipse User |
|
|
|
Thanks Tristan for your explanation !
Since I don't need any transformation for that element (it must be
referenced only) I will try using the initialization that is applying the
entrypoint rule for it.
Regards,
Thomas
Tristan FAURE wrote:
> Okay that's why it doesn't work you have to create a rule transforming
> this element (or just copying it) to contain it
> how atl works (approximatively)
> -----> i apply this rule for each activity
> rule Act2Act {
> from s : UML2!"uml::Activity"
> to out: UML2!"uml::Activity"(
> name <- s.name,
> node<-s.node,
> edge<-s.edge,
> partition<-s.partition,
> -----> okay i have to affect s.specification to my attribute specification
> -----> is s.specification needs to be contain by Activity ?
> -> no it is contained by other element not by an activity
> -----> where this element is transformed ?
> -> anywhere so i can't affect it
> specification<-s.specification)
> }
> If you don't tell ATL to keep trace of operations you will not be able
> to reference it
> so you have to write a rule Operation2Operation (or using High Level
> Type) and Rules ton contain them (Class2Class, Package2Package ...)
> When ATL will match your s.specification it will we able to search in
> its registry that it already (or will) transform the object and can
> affect it
> Thomas Winkler a écrit :
>> Hi Tristan,
>>
>> Thanks for your reply but the the s.specification element (method from a
>> class) won't be transformed so I have no rule for it.
>>
>> And there are no other rules affecting that method in my ATL rules.
>>
>> Regards,
>>
>> Thomas
>>
>> Tristan FAURE wrote:
>>
>>> hi thomas
>>> specification is a reference but not a containment
>>> check you have a rule which transforms the element targeted by
>>> s.specification and which affects the object in other in a containment
>>> reference
>>
>>
|
|
|
Powered by
FUDForum. Page generated in 0.03378 seconds