Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » OCL isUnique always return true!!!!
OCL isUnique always return true!!!! [message #636867] Wed, 03 November 2010 08:09 Go to next message
Mostafa ElShafei is currently offline Mostafa ElShafeiFriend
Messages: 39
Registered: October 2010
Member
Dear all,

I want to check if the outgoing connections name are different so I use the following OCL expression in the interactive OCL console:

self->isUnique(self.outgoingConnections.connectionName)

However, It always return true!!

Any Help or Suggestions?

Thanks in advance. Smile
Re: OCL isUnique always return true!!!! [message #637075 is a reply to message #636867] Thu, 04 November 2010 04:54 Go to previous messageGo to next message
Mostafa ElShafei is currently offline Mostafa ElShafeiFriend
Messages: 39
Registered: October 2010
Member
Hello,

Is there any suggestions / help?

Thanks.
Re: OCL isUnique always return true!!!! [message #637079 is a reply to message #636867] Thu, 04 November 2010 05:55 Go to previous messageGo to next message
Asiri Rathnayake is currently offline Asiri RathnayakeFriend
Messages: 80
Registered: September 2010
Location: Colombo, Sri Lanka.
Member
Hi,

May be try something like:

self.outgoingConnections->isUnique(c:Connection|c.connectionName)

Not very familiar with OCL myself, but I think the problem is your OCL constraint is not constructed properly.

Hope this helps.

- Asiri

[Updated on: Thu, 04 November 2010 05:55]

Report message to a moderator

Re: OCL isUnique always return true!!!! [message #637086 is a reply to message #636867] Thu, 04 November 2010 07:00 Go to previous message
Mostafa ElShafei is currently offline Mostafa ElShafeiFriend
Messages: 39
Registered: October 2010
Member
Hello Asiri,

I would like to thank you again for your useful help.

You were right, It worked :):)Very Happy

I am new to OCL and you really helped me.

Thanks.
Previous Topic:Delegate connection request to child edit part
Next Topic:How to loop on all diagram elements to check if they are all connected together?
Goto Forum:
  


Current Time: Fri Apr 19 03:40:10 GMT 2024

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

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

Back to the top