Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Multiple Connection Labels
Multiple Connection Labels [message #1022071] Thu, 21 March 2013 08:33 Go to next message
Florian W. is currently offline Florian W.Friend
Messages: 15
Registered: January 2013
Junior Member
Hi,

Diagram nodes provide an easy way to display containment references via compartments. Is there a similar concept for connections? I managed to add a feature label to my connection but this label only displays attributes of the underlying model element. What could I do to display all the containment references of the class represented via the connection as a list of connection labels?

Regards,
Florian
Re: Multiple Connection Labels [message #1022132 is a reply to message #1022071] Thu, 21 March 2013 10:22 Go to previous messageGo to next message
Ralph Gerbig is currently offline Ralph GerbigFriend
Messages: 702
Registered: November 2009
Senior Member
Hi,

do you want to show a connection for containment instead of using compartments? If not you mabe could show a mockup of what you want to achieve. This would help.

Ralph
Re: Multiple Connection Labels [message #1022185 is a reply to message #1022132] Thu, 21 March 2013 12:42 Go to previous messageGo to next message
Florian W. is currently offline Florian W.Friend
Messages: 15
Registered: January 2013
Junior Member
Hi Ralph,

thanks for your answer. This is what I would like to achieve:

index.php/fa/13965/0/

The two nodes represent model elements of class A. The connection represents an instance of class B. B has containment refernces to class C. I would like to display the referenced elements as connection labels (ReferencedObject1, ReferencedObject2, ReferencedObject3, ...). However, GMF only supports feature labels for connections which are not appropriate for displaying references. Does this help you?

Regards,
Florian
  • Attachment: Mockup.jpg
    (Size: 8.71KB, Downloaded 491 times)

[Updated on: Thu, 21 March 2013 13:16]

Report message to a moderator

Re: Multiple Connection Labels [message #1024500 is a reply to message #1022185] Tue, 26 March 2013 08:18 Go to previous messageGo to next message
Ralph Gerbig is currently offline Ralph GerbigFriend
Messages: 702
Registered: November 2009
Senior Member
Hi,

GMF does not only allow feature labels. You can also have expression labels which calculate their value by using an OCL expression. All you need to do is to concatenate a string with the reference labels using OCL. You should take a look at using OCL's iterate statement for building up the string. If you install the OCL Example and Editors plugin you can easily test your OCL expressions with an existing model. Just open the console view. In this view open the OCL console. Select the model element you want to execute OCL on and try coding.

Cheers,

Ralph

[Updated on: Thu, 04 April 2013 14:25]

Report message to a moderator

Re: Multiple Connection Labels [message #1033688 is a reply to message #1024500] Thu, 04 April 2013 14:20 Go to previous message
Florian W. is currently offline Florian W.Friend
Messages: 15
Registered: January 2013
Junior Member
Hi Ralph,

I have not seen this feature before. Thanks!

Regards,

Florian
Previous Topic:Removing all edit policies at once ...
Next Topic:recursive relation in same class
Goto Forum:
  


Current Time: Thu Apr 18 01:17:43 GMT 2024

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

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

Back to the top