Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Loop in the query of acceleo(Loop in the query of acceleo)
Loop in the query of acceleo [message #1809078] Mon, 08 July 2019 13:05 Go to next message
Mohammad Inayatullah is currently offline Mohammad InayatullahFriend
Messages: 21
Registered: May 2019
Junior Member
Can any one please give some example of loop inside query of acceleo. i want to implement loop inside following query.

[query public getClassPropertyFromAssociation(p : Property) : OclAny =
if p.upper = -1 then
'public IList<''> '+ +'s { get; set; }'
'public '+' '' { get; set; }'
Re: Loop in the query of acceleo [message #1809080 is a reply to message #1809078] Mon, 08 July 2019 13:16 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7635
Registered: July 2009
Senior Member

You don't provide any clue as to what ou want to loop over or with waht.

One common idiom is

Sequence{1..anOrderedCollection->size()}->iterate(i : Integer ... anOrderedCollection->at(i) ... )


Ed Willink
Previous Topic:Class properties from Element
Next Topic:Refer one mtl file in another
Goto Forum:

Current Time: Sat Dec 02 13:05:49 GMT 2023

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

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

Back to the top