Chapter 9. Java Enterprise Reinvented

 

This chapter covers

  • Working with annotation-based JPA models
  • Using DTOs for RPC transfer
  • Synchronizing between client models and JPA models
  • Binding states for complex widgets
  • Handling file uploads from the browser

The sciences do not try to explain, they hardly even try to interpret, they mainly make models. By a model is meant a mathematical construct which, with the addition of certain verbal interpretations, describes observed phenomena. The justification of such a mathematical construct is solely and precisely that it is expected to work.

John von Neumann

To this point you have encountered the details of working with the GWT tools and have seen various techniques for solving engineering problems in your applications. In this final part of the book, we want to do something different. We’re going to tour two larger GWT projects—a bookstore application and a screen-sharing application—and look at the techniques, tools, and decisions we made in building them so that you can see more clearly how GWT fits into a larger project scope. As we look at these projects using these applications we will to highlight the important aspects of working with GWT in a Java EE environment.

The first application we’re going to create is a basic CRUD application for a bookstore. A screenshot of this application is shown in figure 9.1.

9.1. Constructing two models

9.2. Mapping to DTOs

9.3. Wiring applications with Spring

9.4. Constructing the client application

9.5. Summary