|
In chapter 1 we take a brief historical tour and explore the roots of Ajax itself, and then address why it’s important and how GWT can help. We also cover the basic tools and terminology involved in GWT.Chapter 2 starts with an exclusively client-side example that reinforces some of the basic GWT tenets and stresses a few new points, such as the fact that in GWT a lot more than the view exists on the client. This is where GWT differs from many other web toolkits—it allows a true Model View Controller (MVC) architectural approach to be used in a browser-based application. Those first three chapters form the foundation of the book. We then move into part 2. In chapter 4, we go a bit deeper into what a canonical GWT application involves, including data binding and using the Java Persistence API (JPA) with GWT to persist data in a database. Chapter 5 concentrates on talking to servers using mechanisms other than GWT RPC. Here we discuss JavaScript-to-Java details, the usage of JavaScript Object Notation (JSON), browser security, and the same-origin policy. This is also where we utilize Representational State Transfer (REST) and XML over HTTP. We conclude by running a Simple Object Access Protocol (SOAP) example from a GWT client (using Flash), and incorporating applets. Chapter 6 then goes on to take a close look at the GWT JavaScript Native Interface (JSNI) mechanism, and the GWT-API-Interop library. Both of these are used to integrate existing JavaScript libraries with GWT. In chapter 7 we focus on building, packaging, and deploying GWT applications with both client- and server-side components. We put the automated build technique to further use in chapter 8, where we cover continuous integration and testing. Testing has some unique aspects in GWT, and some complications involving performance, code coverage, and remote testing, all of which are addressed here. Then we move on to the third part of the ebook, “Dirty Hands.” As the title of this part implies, this is where we roll up our sleeves and crank out some non-trivial example applications. In chapter 9 we cover the use of Data Transfer Objects (DTOs) as part of the GWT application model. In chapter 10 we continue the sample application from chapter 9 and add the user-facing storefront. We further discuss security and the concept of roles, and then we add some eye candy by creating a drag-and-drop system for GWT. We also discuss JSNI special effects. In chapter 11 we get into another sample application, this time a screen-sharing example that utilizes the Comet push technique. In this example, we deal with application state using the GWT history mechanism, and we also cope with state on the server side. Finally, we conclude the book with two appendices that provide valuable reference information. Appendix A describes many impressive third-party GWT applications or libraries that you can use to enhance or extend your own applications. Appendix B is a general reference that includes GWT tools and options, definitions for GWT module descriptor and host page elements, a list of emulated JRE classes available with GWT, a description of GWT serializable types, and a list of common user interface widgets and the event handling they support. Download free ebooks on java: GWT in practice - manning
|
More computer ebooks
In chapter 1 we take a brief historical tour and explore the roots of Ajax itself, and then address why it’s important and how GWT can help. We also cover the basic tools and terminology involved in GWT.