Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » question on connection restrictions
question on connection restrictions [message #207940] Tue, 24 January 2006 14:27 Go to next message
Eclipse UserFriend
Originally posted by: dstanciu.gmail.com

Hi,

I have some nodes in an application and some connections between them. Each node and each connection has a model. When I create a connection, I want to be able to block the attachment of the connection to a specific source node, based on the properties of the node model and the new connection model. However, I could not find any method that will allow me to do this.
Please help.

Thanks.
Re: question on connection restrictions [message #207949 is a reply to message #207940] Tue, 24 January 2006 16:06 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: vinusemail.gmail.com

Hi Daniel,
How about overriding the canExecute() method of your Connection
creation command?

- Regards
Vinu Varghese

Daniel Stanciu wrote:
> Hi,
>
> I have some nodes in an application and some connections between them. Each node and each connection has a model. When I create a connection, I want to be able to block the attachment of the connection to a specific source node, based on the properties of the node model and the new connection model. However, I could not find any method that will allow me to do this.
> Please help.
>
> Thanks.
Re: question on connection restrictions [message #207957 is a reply to message #207949] Tue, 24 January 2006 16:28 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: dstanciu.gmail.com

Hi,

I tried that and it is working but not as I would like it to. If I do that, it connects it to the source node but I cannot connect it to any destination node. What I want is not to be able to connect it even to the source node.

Thanks,
Daniel
Re: question on connection restrictions [message #207998 is a reply to message #207957] Wed, 25 January 2006 07:26 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: ingo.koch[nospam].sap.com

simply return null in the ConnectionCreateCommand() method of your
NodeEditPolicy.

Regards, Ingo

"Daniel Stanciu" <dstanciu@gmail.com> wrote in message
news:6980374.1138120119415.JavaMail.root@cp1.javalobby.org...
> Hi,
>
> I tried that and it is working but not as I would like it to. If I do
that, it connects it to the source node but I cannot connect it to any
destination node. What I want is not to be able to connect it even to the
source node.
>
> Thanks,
> Daniel
Re: question on connection restrictions [message #208006 is a reply to message #207998] Wed, 25 January 2006 09:42 Go to previous message
Eclipse UserFriend
Originally posted by: dstanciu.gmail.com

It worked like a charm. Thanks.

> simply return null in the ConnectionCreateCommand()
> method of your
> NodeEditPolicy.
>
> Regards, Ingo
>
Previous Topic:Unable to understand how GEF works to map models onto editparts?!!!!!!!!!
Next Topic:ManhattanConnectionRouter final - why?
Goto Forum:
  


Current Time: Fri Apr 19 22:29:09 GMT 2024

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

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

Back to the top