|
Re: How do I link by ID instead of hierarchy [message #999315 is a reply to message #999194] |
Fri, 11 January 2013 15:02   |
Eclipse User |
|
|
|
Hi,
This is actually and EMF question, since it's EMF that determines how to
encode the fragment part (the part after the #) of the URI pointing to
an object within a resource.
Try using the id or key feature of the attribute, to tell the resource
that this attribute is either unique within the whole resource or unique
within its eContainer. This should affect the fragment.
Hallvard
On 11.01.13 11.13, Roman U wrote:
> Hi
>
> I am trying to use Graphiti to define relationships between some
> business objects. The objects themselves are not created within Graphiti
> but in another editor.
>
> Dragging the objects into the Graphiti editor and defining relationships
> works find. However, when I create or delete business objects in the
> other editor, Graphiti gets confused. It exchanges the objects for the
> ones that were directly below or above them.
> Looking at the saved file, this seems to be the case because Graphiti
> links to the business objects by means of their hierarchical position
> within my original xmi file. If the other editor changes the hierarchy,
> that becomes a problem.
>
> Browsing the forum for help, I already found out that one can also link
> the business objects by ID. (for example
> http://www.eclipse.org/forums/index.php/m/409120/?srch=link+hierarchical#msg_409120)
>
> I did not find any information on how to do it though, neither here nor
> in the documentation.
>
> Now I am starting to be afraid that this is to trivial to merit any
> documentation :)
> Simply defining an ID in the model changed nothing for me, as did
> setting the EReference.eKeys.
>
> Should it be that simple (automatic) and simply is not working for me,
> or can someone point me to what I need to know to change this behavior?
|
|
|
Re: How do I link by ID instead of hierarchy [message #999581 is a reply to message #999194] |
Sat, 12 January 2013 09:42  |
Eclipse User |
|
|
|
Maybe I do not know enough about EMF yet.
But if I understand it correctly, you are saying that if in my model I defined a a field as an ID (I did) or defined an EKey for the containment (I did) the path/fragment should change automatically?
In that case maybe I should remake my model to see if I forgot anything, as it does not seem to happen.
|
|
|
Powered by
FUDForum. Page generated in 0.04052 seconds