Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » M2M (model-to-model transformation) » [ATL]should i use resolve temp??
[ATL]should i use resolve temp?? [message #34271] Wed, 25 April 2007 19:04 Go to next message
Eclipse UserFriend
Originally posted by: touzitou.enstimac.fr

Hi all
i work in this example

rule generatePackage {
from
a : BPMN!SDM

to

out :UML2!Model

(
name<-'alloula',
packagedElement <- thisModule.resolveTemp(
BPMN!MessageFlow?? ,'m')

)}



rule generateMessage {
from
a : BPMN!MessageFlow

to

m :UML2!Class

(
)


}

I want to add all elements generated by the second rules as children
(packaged element) of the UML model generated by the rule 1..
How can i do ...???
The use of the resolvetemp like i do return a mistake
message: ERROR: could not find operation getNamedTargetFromSource on
Void having supertypes: [OclAny]

P.S: i don't want to use lazy rules.. i know i can do it but the problem
lazy rules don't work easy with profiles that's why i prefer using
simple rule.


Thxs much
Re: [ATL]should i use resolve temp?? [message #34307 is a reply to message #34271] Thu, 26 April 2007 08:05 Go to previous message
Eclipse UserFriend
Originally posted by: mikael.barbero.gmail.com

Hi jihed,

Suppose you have a reference messageFlow on your BPMN!SDM instance, you
can do something like this :

rule generatePackage {
from
a : BPMN!SDM
to
out :UML2!Model (
name<-'alloula',
packagedElement <- a.messageFlow
)}

This will bind every elements of a.messageFlow to element created in
generateMessage. You do not need resolveTemp here because your
generateMessage rule does not have multiple output elements.

Best regards,
Mikael

jihed wrote:
> Hi all
> i work in this example
>
> rule generatePackage {
> from
> a : BPMN!SDM
>
> to
>
> out :UML2!Model
>
> (
> name<-'alloula',
> packagedElement <- thisModule.resolveTemp(
> BPMN!MessageFlow?? ,'m')
>
> )}
>
>
>
> rule generateMessage {
> from
> a : BPMN!MessageFlow
>
> to
>
> m :UML2!Class
>
> (
> )
>
>
> }
>
> I want to add all elements generated by the second rules as children
> (packaged element) of the UML model generated by the rule 1..
> How can i do ...???
> The use of the resolvetemp like i do return a mistake
> message: ERROR: could not find operation getNamedTargetFromSource on
> Void having supertypes: [OclAny]
>
> P.S: i don't want to use lazy rules.. i know i can do it but the problem
> lazy rules don't work easy with profiles that's why i prefer using
> simple rule.
>
>
> Thxs much



--
Mikaël Barbero - PhD Candidate
ATLAS Group (INRIA & LINA) - University of Nantes
2, rue de la Houssinière
44322 Nantes Cedex 3 - France
tel. +33 2 51 12 58 08 /\ cell.+33 6 07 63 19 00
email: Mikael.Barbero@{gmail.com, univ-nantes.fr}
http://www.sciences.univ-nantes.fr/lina/atl/
Previous Topic:Can't find "Register metamodel"
Next Topic:[ATL] problem with generating Ecore DataTypes
Goto Forum:
  


Current Time: Mon Jan 18 08:45:52 GMT 2021

Powered by FUDForum. Page generated in 0.01386 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top