Chapter 15. Building MVP-based applications

 

This chapter covers

  • What the MVP approach is and why it’s useful
  • How to hand-code the MVP approach in GWT
  • How to use GWT’s Activity and Place objects

One of GWT’s main selling points is that it allows you to use an industry-grade language, with an industry-grade set of tools, to build, well, industry-grade web applications. But, as with any large-scale development project, you can easily paint yourself into a corner. Far too many times when building GWT-based applications, you may find yourself slinging code wherever necessary to make the application work and (sometimes more important) look good.

This makes your code development and, perhaps worse, your code maintenance a nightmare. No longer are you able to push the boundaries of web applications because you’re spending all of your time and budget fixing bugs and scratching your head wondering why now that it’s fixed here, it’s suddenly all going wrong over there. And why, when you’re trying to add new functionality, it never comes in anywhere near the on-budget number.

Fortunately, these problems have well-known engineering and architectural solutions. One of these is to build your applications around the model-view-presenter (MVP) paradigm (or pattern, if you want to call it that).

15.1. What is MVP?

 
 
 
 

15.2. Looking at the PhotoApp’s MVP foundations

 

15.3. Building MVP yourself

 
 
 

15.4. Altering an MVP application

 
 
 

15.5. Activity and Place (GWT’s reference MVP approach)

 
 
 

15.6. Fitting editors/data-presentation widgets into MVP

 
 

15.7. Summary

 
 
 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage
test yourself with a liveTest