|
Re: Delete Element Based Edge together with its Target/Source [message #1743776 is a reply to message #1743651] |
Mon, 19 September 2016 14:49   |
|
Hi Xi,
There are several errors in "var:element.incomingEdges" :
. var:element is an access to the variable element: you can't add nothing after.
. if you want to navigate the model from the element, just use another interpreter, like AQL for exemple: "aql:element.incomingEdges"
. i think that incomingEdges is not a feature of your metamodel, you should replace it by your domain feature or service to retrieve the element to remove from the current element to delete.
. there might be several edges to delete: a "For" model operation would be a better idea than the "Change context"
. you can also navigate on the "view" model and retrieve the semantic element you want to delete.
For the last point, the "elementView" variable is the clicked element which will be delete among the semantic element when you will call the delete tool:
"aql:elementView.incomingEdges.concat(elementView.outgoingEdges).target->asOrderedSet()"
.target is used to navigate from the "graphical" model to your domain model.
->asOrderedSet is used to transform the result in a set and avoid duplicates.
Regards,
Maxime - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02236 seconds