Skip to main content



      Home
Home » Modeling » Epsilon » [Eugenia] Link label from attribute of contained class
[Eugenia] Link label from attribute of contained class [message #1429654] Tue, 23 September 2014 10:36 Go to next message
Eclipse UserFriend
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.
index.php/fa/19233/0/

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

Re: [Eugenia] Link label from attribute of contained class [message #1430753 is a reply to message #1429654] Wed, 24 September 2014 15:28 Go to previous messageGo to next message
Eclipse UserFriend
Hi Niko,

Could you please put together a minimal example [1] I can use to reproduce this?

Cheers,
Dimitris

[1] https://www.eclipse.org/epsilon/doc/articles/minimal-examples/
Re: [Eugenia] Link label from attribute of contained class [message #1430809 is a reply to message #1430753] Wed, 24 September 2014 17:23 Go to previous messageGo to next message
Eclipse UserFriend
Dear Dimitris,

I am attaching you a minimal example and the instructions file.
(I included a small plot for the expected - actual behaviour as well)

Thank you for the support.



Kind Regards, Nikos
Re: [Eugenia] Link label from attribute of contained class [message #1431016 is a reply to message #1430809] Thu, 25 September 2014 01:26 Go to previous messageGo to next message
Eclipse UserFriend
Hi Niko,

This is a refresh problem; if you close and open your editor again, Transition labels appear as expected. [1] should be a good starting point for further investigation.

Cheers,
Dimitris

[1] https://wiki.eclipse.org/GMF_Newsgroup_Q_and_A#How_can_I_synchronize_my_custom_figures_with_the_model.3F
Re: [Eugenia] Link label from attribute of contained class [message #1431433 is a reply to message #1431016] Thu, 25 September 2014 13:36 Go to previous message
Eclipse UserFriend
Hi Dimitri,

Thanks for replying.

I tried a few things without any success, I have currently created a thread under GMF's forum about this issue here

Kind Regards, Nikos
Previous Topic:[Eugenia] Multiline property of a node's attribute
Next Topic:Identify unset/undefined attributes in Entities
Goto Forum:
  


Current Time: Mon Jul 07 09:12:45 EDT 2025

Powered by FUDForum. Page generated in 0.04741 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top