[ATL] Call lazy rule not for a collection [message #671859] |
Thu, 19 May 2011 03:54  |
Eclipse User |
|
|
|
I am using following example to call a lazy rule for a collection:
create OUT : B from IN : A;
rule RootElement {
from
billOfMaterial : A!BillOfMaterial
to
target : B!BCModel (
categories <- billOfMaterial.armature.parts->collect(e | thisModule.Part2Category(e))
)
}
lazy rule Part2Category {
from
s : A!Part
to
t : B!Category(
)
}
Can anybody tell me how to call a lazy rule for a single object? In my case i want to call it for billOfMaterial.armature(which is not a collection), but did not find such a case in the documentation.
Second problem is how to get information from billOfMaterial to that lazy rule function??
Sorry for my stupid questions, in my opinion ATL is quite difficult to understand for beginners.
Cheers
Patrick
[Updated on: Thu, 19 May 2011 03:56] by Moderator
|
|
|
|
|
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.06465 seconds