Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » Refer one mtl file in another(Refer one mtl file in another)
Refer one mtl file in another [message #1809140] Wed, 10 July 2019 06:41 Go to next message
Mohammad Inayatullah is currently offline Mohammad InayatullahFriend
Messages: 21
Registered: May 2019
Junior Member
I have a very long code in acceleo. Now i wan to divide this in multiple file. So, is there any way they i would have multiple mtl files and i refer one in another.
If this is possible can any one please send me a link of tutorial for this.

Thanks
Mohammad Inayatullah

Re: Refer one mtl file in another [message #1809142 is a reply to message #1809140] Wed, 10 July 2019 07:09 Go to previous messageGo to next message
Vittorio Niespolo is currently offline Vittorio NiespoloFriend
Messages: 11
Registered: May 2019
Junior Member
You have to use [import /] like for java and add the fully qualifying name of the mtl module you would like to use.
Here is an example:

[import it::mice::acceleogenerator::library::springboot::commonUtils/]

Re: Refer one mtl file in another [message #1809154 is a reply to message #1809142] Wed, 10 July 2019 09:37 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7680
Registered: July 2009
Senior Member
Hi

IIRC you may encounter problems with incremental rebuilds not rebuilding.

You may sometimes find you need to do a dummy edit on the most deeply imported file to force the rebuilds.

Regards

Ed Willink
Re: Refer one mtl file in another [message #1809172 is a reply to message #1809154] Wed, 10 July 2019 13:59 Go to previous messageGo to next message
Vittorio Niespolo is currently offline Vittorio NiespoloFriend
Messages: 11
Registered: May 2019
Junior Member
Hi, i am in this situation.
Besides bulding's issues i am also getting some random problems with autocomplete, and "GoTo method" (using CRTL + click).

Is there a way to solve or to avoid this kind of problems?
How many import's level would you suggest to have?
Are there any other possible causes of this scalability troubles?
Re: Refer one mtl file in another [message #1809181 is a reply to message #1809172] Wed, 10 July 2019 17:02 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7680
Registered: July 2009
Senior Member
Hi

Autocomplete is hard. The user has an expectation that a particular suggestion is 'obvious'. The tooling, even when well-coded, may be confounded by a variety of errors that obfuscate the 'obvious'. Also developers do not always have enough time to handle all the autocomplete dark corners.

GoTo is not always well supported. If there, it should work. Hovertext may explain what it might do. But may be it's a symptom of a failed rebuild.

I found many problems which, in combination with the URI resolution issues and difficulties of using OCL both as a development model and tooling model forced me to migrate to Xtend where M2T functionality is just one of the many Java++ capabilities; see String Templates.

Regards

Ed Willink
Previous Topic:Loop in the query of acceleo
Next Topic:Acceleo standalone generation
Goto Forum:
  


Current Time: Sat Dec 14 08:21:14 GMT 2024

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

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

Back to the top