HI

I have a questions about communication in GWT and java in general.

In an effort to better modularize my application I have made a number
of different composites.  I then have a main application that links
together all the composites.

The problem comes when I need to communicate between composites, for
example change an image in a composite based on an event in another
composite.

They way I have don this now is by passing "this" to every composite
constructor and saving it as parent.  I also have methods that allow
me to get the children of a composite.  Then in each composite I have
a getCompositeParent() method that will allow me to go further down
the composite tree.

For example:

parent.getCompositeParent().getCompositeParent().getNamesComposite
().getName().setText("hello");

This seems a bit unwieldy.  Is this the normal way of doing things in
JAVA?

--

You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.


Reply via email to