Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » edge creation automatically
edge creation automatically [message #1810612] Wed, 14 August 2019 10:38 Go to next message
maryam mehrabi is currently offline maryam mehrabiFriend
Messages: 8
Registered: May 2019
Junior Member
hello all.
I am new sirius user and I have 2 questions. I will appreciate if you help me.

I have a meta-model that I attached that. I wanna to make a graphical editor for it. I have created nodes pallette but for creating relations I have some problems.

q1: according to my meta model, is there any way when the end user create nodes from A, B, C, D, E and F using pallete, the d, e and f relations
creates automatically without edge creation tools? if yes how can I do that?

q2: how can I create one edge creation tool for ed and fe relations? I see this topic(Edge creation for several relations) in the forum but I couldnt write a suitable aql in node creation tool to do that. can you explain the solution in detail or give me an example with same solution?!

[Updated on: Thu, 15 August 2019 10:32]

Report message to a moderator

Re: edge creation automatically [message #1810704 is a reply to message #1810612] Fri, 16 August 2019 16:28 Go to previous messageGo to next message
maryam mehrabi is currently offline maryam mehrabiFriend
Messages: 8
Registered: May 2019
Junior Member
any one?
Re: edge creation automatically [message #1811007 is a reply to message #1810704] Fri, 23 August 2019 13:51 Go to previous messageGo to next message
Florian Barbin is currently offline Florian BarbinFriend
Messages: 228
Registered: August 2010
Senior Member
Hello,

q1: In your node creation tool, you are free to set features or attributes to the new created element by defining a "Set" operation. This operation will set the reference "fe" for instance if an other E object exist when creating an object F. But if you have several instance of E when creating a new F, the end user will have to choose which one the relation fe needs to reference.
q2: You can use the If operation that will, according to the instance type of the source and/or target, will set the appropriate relation.

You can find a good example of odesign in the EcoreTools project: https://github.com/eclipse/ecoretools/tree/master/org.eclipse.emf.ecoretools.design/description
Here the model operation documentation: https://www.eclipse.org/sirius/doc/specifier/general/Model_Operations.html

Regards,

Florian
Re: edge creation automatically [message #1811076 is a reply to message #1811007] Mon, 26 August 2019 14:24 Go to previous message
maryam mehrabi is currently offline maryam mehrabiFriend
Messages: 8
Registered: May 2019
Junior Member
Everything works fine now. Thanks for your help

mary
Previous Topic:EObjectQuery on external ressource
Next Topic:[AQL] allInstances operator not available
Goto Forum:
  


Current Time: Thu Oct 17 02:53:00 GMT 2019

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

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

Back to the top