[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools.gef] Re: Please Help!!!

Jose wrote:
Hi CL!

First of all, thank you for your help.
Now, I don't know how to implement the method "hasConnection" that you use in the sanityCheck method. The fields "source" and "target" are both of kind "EditPart", and in this class there isn't a method called "hasConnection". What can I do?
Thank you very much.



--Jose



You get the model from the edit part, and you ask your model if it has connections. So you have to cast your model to its concrete type, and have a method on your model that returns whether or not it has any connections. Since you are already creating connections, your model must be aware of them, so it should be easy to add this extra method.


CL