Skip to main content



      Home
Home » Eclipse Projects » Sirius » Edge creation tool not working
Edge creation tool not working [message #1750777] Wed, 28 December 2016 10:54 Go to next message
Eclipse UserFriend
Hello,

I am doing my master dissertation on developing a tool for modeling Entity-Relationship Diagrams for the University of Ghent with no prior knowledge of modeling, in order to test the usability of Sirius.

It is a rather simple modeling tool that allows you to create 'entities', give them 'attributes' and define 'relationships' between these entities.

I have created an Element Based Edge for the relationships, they work when I define them within the example model. But it's not possible to use the palette to create a relationship.

I included my metamodel, the example model + editing palette and odesign file + properties of my edge creation tool.

index.php/fa/27965/0/
index.php/fa/27964/0/
index.php/fa/27966/0/

Please consider that I have no prior modeling knowledge, as that is the purpose of my dissertation, so if you can point me to any valuable resources, it will be much appreciated.

I am looking forward to your response.

Thank you.
Re: Edge creation tool not working [message #1750780 is a reply to message #1750777] Wed, 28 December 2016 11:21 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

From the screenshot it looks like the tool definition is *almost* right, except for one point: as mentioned in the documentation, the operations executed by your tool will start in the context of the semantic element of the source of the new edge. That's where your "Create Instance" operation will be executed, and it will probably be either an Entity or an Attribute. Sirius will try to attach the newly created element in that element, using the "Reference Name" you configured, "relationships". Neither Entity nor Attribute defines such a relationship, so the new instance can not be attached.

The solution is probably just to wrap your "Create Instance" operation inside a "Change Context" which navigates to the enclosing "EntityRelationShip" element first, as this is the one defining the "relationships" containment reference and this is where the new instance must be attached.

Regards,
Pierre-Charles David
Re: Edge creation tool not working [message #1750878 is a reply to message #1750780] Fri, 30 December 2016 12:44 Go to previous message
Eclipse UserFriend
Hey,

It worked when I added a "Change Context" with [source.eContainer()/] as Browse Expression.

Thank you very much, and may 2017 be the best year for you!

Kind regards,

Sonny

Previous Topic:External Java Action
Next Topic:Center multiline Title
Goto Forum:
  


Current Time: Thu Jun 19 00:25:21 EDT 2025

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

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

Back to the top