|
|
|
Re: Refresh diagram representation! [message #1690260 is a reply to message #1690177] |
Thu, 26 March 2015 03:56   |
Eclipse User |
|
|
|
Hi
Le 25/03/2015 16:04, Minh Hiep Pham a écrit :
> Hi,
>
> thanks for you answer. When a new MessageEvent during simulation has
> been created, which will have source and target from MSDMessageEvent.
> Then i want to create a new Edge, which has been defined with
> Element-Based Edges. Because i can use Source Finder Expression to get
> source mapping, and Target Finder Expression to get target mapping,
> however i dont have Domain Class. Can i solve this problem with
> Relation-Based Edges?
In your situation, a Relation based edge mapping could be a solution.
Like the Element based edge mapping, you have to define the source and
target mapping and the target finder expression but no domain class,
semantic candidates expression or source finder expression.
The target finder expression of a Relation based edge mapping is
computed from the source element. If the evaluation of the expression
return some elements represented on the diagram by a node whose mapping
is in the target mappings of the edge mapping, the corresponding edges
are created.
In your case, you should use a service in the target finder expression
to retrieve some MessageEvent/MSDMessageEvent from the source and return
the target(s) of the edge(s) you want to create for the current source.
Do you have any example for this situation? The
> information in thread https://www.eclipse.org/forums/index.php/t/981267/
> is low. I can understand the solution, however i cant understand about
> the service class.
Regards,
--
Maxime - Obeo
Need professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
Re: Refresh diagram representation! [message #1690281 is a reply to message #1690260] |
Thu, 26 March 2015 06:03  |
Eclipse User |
|
|
|
Hi,
thanks you very much for you advice! But i see a problem there, because when i double click a MessageEvent in the List 1, i can get a source object 2 and a target 3.(Picture Simulation-example.png)
For example:
When i click MessageEvent(RequestEnter), i will get source object (rc:Railcab) and target object(CrossingControl). Now i want to represent the Edge MessageEvent from Railcab to CrossingControl in my DRepresentation and refresh(Simulation-example-first-step.png). Next i want to represent my next MessageEvent(close)(Simulation-example-second-step.png), then i want only to change the Source(old: Railcab with new:CrossingControl) and Target(old:CrossingControl with new:Barrier) of the Edge MessageEvent, and not to show a new Edge in the DRepresentation.
If i used Relation-based Edge, i will set only the target object for the Relation-based Edge. So i cant solve my problem, right? Do you have any advice for this?
|
|
|
Powered by
FUDForum. Page generated in 0.03564 seconds