Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » ATL » How to Conditional Transformation in Rules ?
How to Conditional Transformation in Rules ? [message #1830207] Mon, 20 July 2020 18:19 Go to next message
Burak Karaduman is currently offline Burak KaradumanFriend
Messages: 84
Registered: July 2018
Member
Dear All I have an EClass named "Event" in MetaModel_AB and it has a feature of "Name:String".

In MetaModel_B I have two EClasses named Event_A and Event_B

What I am trying to achieve is, when the name attribute of Event is inputted as "Event_A" I want to transform Event to Event_A and If the user inputs "Event_B" to Event's Name field, I want to transform Event to Event_B.

is It possible do define these conditions just using one Rule.

Thanks.
Re: How to Conditional Transformation in Rules ? [message #1830650 is a reply to message #1830207] Thu, 30 July 2020 13:54 Go to previous messageGo to next message
Burak Karaduman is currently offline Burak KaradumanFriend
Messages: 84
Registered: July 2018
Member
Help please?
Re: How to Conditional Transformation in Rules ? [message #1830725 is a reply to message #1830650] Sat, 01 August 2020 14:25 Go to previous messageGo to next message
Dennis Wagelaar is currently offline Dennis WagelaarFriend
Messages: 589
Registered: September 2012
Location: Belgium
Senior Member

No, ATL would use two rules for this. Why do you need this to be in a single rule?

Cheers,
Dennis
Re: How to Conditional Transformation in Rules ? [message #1831088 is a reply to message #1830725] Tue, 11 August 2020 12:53 Go to previous message
Burak Karaduman is currently offline Burak KaradumanFriend
Messages: 84
Registered: July 2018
Member
Dennis Wagelaar wrote on Sat, 01 August 2020 14:25
No, ATL would use two rules for this. Why do you need this to be in a single rule?


Dear Dennis,

I have solved my problem using -> select(), I selected desired A values and B values and transformed them to necessary features.

Can you help me with the following topic ?

https://www.eclipse.org/forums/index.php/t/1104722/

Thank you!
Previous Topic:Casting in ATL
Next Topic:ATL Generic Type Helper ?
Goto Forum:
  


Current Time: Wed Apr 24 18:23:59 GMT 2024

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

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

Back to the top