[Eugenia] Link label from attribute of contained class [message #1429654] |
Tue, 23 September 2014 10:36  |
Eclipse User |
|
|
|
Hello, I am trying to set a link's label value to be auto assigned based on an attribute of a contained class (after following this example right here).
My emfatic code :
@gmf.link(source="from", target="to", style="solid", target.decoration="closedarrow", width="1", label="transitionName")
class Transition {
ref Function function;
ref State#outgoingTransitions from;
ref State#incomingTransitions to;
derived transient volatile attr String transitionName;
}
@gmf.node(label="name", size="190,20",margin="3")
class Function {
id attr String name;
....
....
....
}
After generating the editor I edited the TransitionImp as follows
/*
* generated NOT
*/
public String getTransitionName() {
return function.getName();
}
My problem is that in the editor the transitionName is set as it should in the properties view (it is always the same as the function's name), however no label is shown in the canvas for the transition(at all).
Apart from that, in the gmfgraph it seems like the Label TransitionLabelLabel is not under the TransitionFigure --> Polyline Connection but it is under another figure called TransitionLabelFigure.

Could somebody give me a clue on how to fix this?
Attachment: figure.png
(Size: 17.12KB, Downloaded 635 times)
[Updated on: Tue, 23 September 2014 11:21] by Moderator
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04741 seconds