Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » working with imported models
working with imported models [message #1848169] Tue, 23 November 2021 10:28 Go to next message
Ilja Kraval is currently offline Ilja KravalFriend
Messages: 38
Registered: October 2021
Member
Hi all,
I am new to Acceleo and I have this question:
Can Acceleo work with imported models and elements in it?
For example:
I have the CORE model and the User class in CORE, CORE is imported (LOAD) in model X .
I need to get the User class name and User attributes (or other classes) using a template working on the X model (not on the CORE model).

Is it possible?

Thanks for the answer,

Ilya

[Updated on: Tue, 23 November 2021 17:50]

Report message to a moderator

Re: working with imported models [message #1848170 is a reply to message #1848169] Tue, 23 November 2021 11:38 Go to previous messageGo to next message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

Absolutely. Models that can't refer to others would be pretty useless.

Regards

Ed Willink
Re: working with imported models [message #1848171 is a reply to message #1848169] Tue, 23 November 2021 11:55 Go to previous messageGo to next message
Ilja Kraval is currently offline Ilja KravalFriend
Messages: 38
Registered: October 2021
Member
Hi Ed,

thanks,

Ilya
Re: working with imported models [message #1848172 is a reply to message #1848171] Tue, 23 November 2021 12:17 Go to previous messageGo to next message
Carsten Pitz is currently offline Carsten PitzFriend
Messages: 479
Registered: May 2015
Location: Germany
Senior Member
Hi Ilya,

to extend Ed's answer.

You can
1. either use a query like self.eContents(uml::PackageImport) to query for PackageImport child elements of self
2. or drag'n'drop the imported package into the model and navigate to it as with a "normal" Package element.

/Carsten
Re: working with imported models [message #1848176 is a reply to message #1848172] Tue, 23 November 2021 17:57 Go to previous message
Ilja Kraval is currently offline Ilja KravalFriend
Messages: 38
Registered: October 2021
Member
Hi Carsten,

thanks!

Ilya
Previous Topic:M2T
Next Topic:correct downcast from Element to other UML types
Goto Forum:
  


Current Time: Fri Apr 19 23:03:33 GMT 2024

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

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

Back to the top