Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » ATL » ATL Transformation Order Problem
ATL Transformation Order Problem [message #1040621] Sat, 13 April 2013 22:45 Go to next message
Eclipse UserFriend
Dears,

I have a problem in an ATL program.
I need the input items to be transformed in the same order they appear in the input file. But they are transformed in the order of the firing of rules.

I used "ordered reference" in the input metamodel, but this doesn't work.

Any one have a clue?
Re: ATL Transformation Order Problem [message #1048256 is a reply to message #1040621] Wed, 24 April 2013 08:24 Go to previous messageGo to next message
Ronan B is currently offline Ronan BFriend
Messages: 273
Registered: July 2009
Senior Member
Hi,
Take a look at http://www.eclipse.org/forums/index.php/t/197319/. You cannot rely on the order of matched rules. However, this is rarely a problem if you write your ATL as your should.
Regards,
Ronan
Re: ATL Transformation Order Problem [message #1057752 is a reply to message #1048256] Wed, 08 May 2013 14:52 Go to previous message
Eclipse UserFriend
Thanks a lot.

It worked as follows:

The order is going to be determined by the reference (in another model element) that will actually "contain" these -to be ordered- elements.

For instance:

rule XXXtoYYY {
from
x: MM!XXX
to
y: NN!YYY (
Ys<- x.Xs->sortedBy(n | n.id)
)
}


then write the rules that convert each sub element X to Y.
Note: it worked with me without (->sortedBy(n | n.id))

Also check this Link:
http://www.eclipse.org/forums/index.php/mv/msg/474693/1039633/#msg_1039633
Previous Topic:Problem with multivalued field
Next Topic:EMFTVM/ATL How to assign the result of a rule matching several elements
Goto Forum:
  


Current Time: Thu Apr 18 12:26:35 GMT 2024

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

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

Back to the top