views:

117

answers:

1

I'm making a GWT application which will have many screens. There will be a menu on the left and clicking a menu option will open the relevant module in the right side content area. Clicking on items in the content area will link to other modules that open in the same content area.

  1. How do I implement this architecture?
  2. How do I pass objects between the different content modules?
  3. How do I isolate each module into its own package?
  4. Can all of these be within the same Eclipse project?
  5. Anything else that should be considered?
+1  A: 

Hi there,

I too have been working extensively on a GWT application (my first) and also started with these questions.

From what I discovered - one of the best ways to achieve this is by using the MVP (Model-View-Presenter) architecture. Google themselves endorse this for large scale GWT applications and have pushed their point; A breakdown of the architecture described on their website: http://code.google.com/webtoolkit/articles/mvp-architecture.html, a presentation done by them: http://www.youtube.com/watch?v=PDuhR18-EdM and for me the most useful an example Contacts application using these very methods: http://code.google.com/webtoolkit/doc/latest/tutorial/projects/Contacts2.zip.

For me that was a great way to start. It can all be done within the same project. Hope that answers most (if not all) of your questions! :)

Xandel

Xandel
You might also want to look into the support for MVP (like Places) that is planned for GWT 2.1. See: http://code.google.com/events/io/2010/sessions/architecting-production-gwt.html
Igor Klimer