Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » Element Based Edge in one editor across different metamodels
Element Based Edge in one editor across different metamodels [message #1840510] Fri, 16 April 2021 20:49 Go to next message
Thomas Chiang is currently offline Thomas ChiangFriend
Messages: 83
Registered: March 2020
Member
Hi,

I have 2 metamodels that are dependent upon one another, show in the picture below:
index.php/fa/40349/0/

I am trying to define the Input and Output classes that inherit from Global_Reference in my Sirius editor however for whatever reason when I define them the graphics for those classes do not appear in my editor. Is there a reason for this? As far as I can tell I have the fields filled out properly. Is this a bug?

My goal is to be able to have the source of an Input class be a Global_Data class while the target is a Public_Process class.

[Updated on: Tue, 20 April 2021 18:14]

Report message to a moderator

Re: Element Based Edge in one editor across different metamodels [message #1840643 is a reply to message #1840510] Wed, 21 April 2021 09:29 Go to previous messageGo to next message
Pierre-Charles David is currently offline Pierre-Charles DavidFriend
Messages: 644
Registered: July 2009
Senior Member
Hi,

The Ecore Tools modeler used here uses _unsynchronized_ elements, meaning a concrete diagram will not automatically display all the elements that exist in your model.

When you create a new element (e.g. an EClass) directly from the diagram a graphical view for it will automatically be created, but if an EClass is created from another diagram or via a non-graphical operation, Sirius will not automatically create one.
This is a specific choice of Ecore Tools, other Sirius modelers choose to have all (or some of) their elements synchronized.

To manually create a graphical representation of an existing element on your diagram, you can either drag and drop it from the model explorer to the diagram, or use the "Add" tool in the "Existing Elements" category in the palette.
It will open a dialog where you can choose which additional elements (e.g. the Input and Output classes) should be represented on the diagram.


Pierre-Charles David - Obeo

Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Re: Element Based Edge in one editor across different metamodels [message #1840662 is a reply to message #1840643] Wed, 21 April 2021 14:39 Go to previous messageGo to next message
Thomas Chiang is currently offline Thomas ChiangFriend
Messages: 83
Registered: March 2020
Member
Hi,

I have used the add elements tool in order to create the inter-dependent metamodels. The issue comes when I try to make an instance of them in Sirius. I have set all my concrete syntax definitions now to be synchronized but it still doesn't seem to create a graphical representation of my Input and Output classes in my editor. I suspected it was because the 'src' feature of the Input class is from one metamodel while the 'tgt' feature is from another, but then creating graphical representations for all of the non-reference classes works just fine so I was wondering if there was something else that I am missing now as well as the synchronized issue that you brought up.
index.php/fa/40377/0/

If it helps the image above is how I currently have the element based edge for the Input class defined.

[Updated on: Wed, 21 April 2021 16:32]

Report message to a moderator

Re: Element Based Edge in one editor across different metamodels [message #1840704 is a reply to message #1840662] Thu, 22 April 2021 08:56 Go to previous message
Pierre-Charles David is currently offline Pierre-Charles DavidFriend
Messages: 644
Registered: July 2009
Senior Member
Hi,

From the screeshot, your Input edge mapping uses source and target mappings like Public Progress and Data Element which are from another diagram definition. This is not supported, a diagram instance will only display instances of mappings from its own definition.

The Sirius Specification Editor unfortunately allows to chose all elements from anywhere in the file when choosing a source/target mapping, but ideally it should restrict the choices to the current diagram definition.

You can either create copies of the Public Progress mapping (and others) inside the WFP diagram (but it's more work to maintain), or define in WFP mapping imports which point to the original definitions from the other diagram definition.


Pierre-Charles David - Obeo

Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Previous Topic:creation tools are not working
Next Topic:New Element Based Edge not working
Goto Forum:
  


Current Time: Sun Sep 25 20:55:14 GMT 2022

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

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

Back to the top