Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » how to link references
how to link references [message #1060330] Fri, 24 May 2013 03:41 Go to next message
Andrea Sindico is currently offline Andrea Sindico
Messages: 266
Registered: November 2010
Senior Member

In the Graphiti tutorial references among objects of the model, which in the tutorial is an instance of the ECORE meta-meta-model, are stored via a EReference instance like this

link(connection, addedEReference);


The problem is that in the instance of my own ECORE meta-model references ar just properties of the involved meta-classes. How should I link these to the related connections?

Regards


Follow me on Twitter @andreasindico

Re: how to link references [message #1060367 is a reply to message #1060330] Fri, 24 May 2013 06:15 Go to previous messageGo to next message
Michael Wenz is currently offline Michael Wenz
Messages: 1590
Registered: July 2009
Location: Walldorf, Germany
Senior Member
Andrea,

you may link to the source and/or target instance of the object containing
the reference. Additionally you may store the name of the reference as a
name-value-property along with the connection (e.g. in case there are
several references that might connect the 2 objects).

Michael
Re: how to link references [message #1060501 is a reply to message #1060367] Sat, 25 May 2013 09:28 Go to previous message
Aljoscha Hark is currently offline Aljoscha Hark
Messages: 24
Registered: March 2012
Junior Member
Hi,

you could also link the connection to the "feature" which it represents.

E.g. XPackage.Literals.XX_YY : EReference

With this connection you can handle everything when the connection is selected, I think.

See the thread under [1] for a more detailed explanation.

Aljoscha

[1] http://www.eclipse.org/forums/index.php/m/924268/#msg_924268
Previous Topic:Question about Link Model
Next Topic:Graphiti and EMF Properties View
Goto Forum:
  


Current Time: Sun Aug 31 04:44:42 EDT 2014

Powered by FUDForum. Page generated in 0.01589 seconds