• Sponsored Links :

Java Ajax Programming using Google Web Toolkit (GWT) - Book Review

Google Web Toolkit (GWT) Java AJAX Programming by Prabhakar Chaganti is an excellent book for GWT beginners. The language is straightforward and easy to follow.

The book starts with a short introduction to Ajax. It then talks about the steps to follow for getting started with GWT 1.3.3. The first chapter essentially familiarizes you with the GWT extract - the folders and their contents. It also talks about the sample applications that come with the download.

The second chapter moves on to building your first application and the simplicity of the task will surprise you. The book moves on to show you how to create your first Ajaxed application. The LiveSearch, Password Strength, Flickr Editable Label, the Monalisa Puzzle and lots of interesting examples make it really easy for you.

The book follows a standard pattern of a "Time For Action" section followed by "What just happened?" section for every task or example. The first section walks you through how to complete and run a task and the second section explains how it was done.

The book does have some errors/typos that need cleaning up but nothing that will distract or mislead the serious reader. The place where I believe the book could do with some changes is in the second chapter where the author takes the user through the task of running an application in the web mode. Typically, a technical book reading is different from novel reading where you read each fine line to follow the plot. Thus, if you skip reading all the lines, you might miss some important details. The heading of the section is "Running the Application in Web Mode" in bold letters followed by the "Time for Action" and then the "What just happened" sections. The "Time for Action" explains what is to be done to compile the application from Java to Javascript so you can run it in the web mode. However, the part which tells you that " the steps required to deploy the server code on a server are explained at the end of the book" is mentioned deep down in the passages that follow. So it's easy to miss that bit and then struggle to run the app in the web mode.

The book uses a lot of the GWT API classes to create a layout similar to the GWT Demo app. But it would have been good if there was a chapter with a diagram or two about all the layouts and other frequently required GWT API classes.

The chapters that follow take on more complex examples. One chapter focuses on JSNI and explains how to use the Rico, Moo.fx and Script.aculo.us libraries with your GWT application. The next chapter shows the by now comfortable-with-GWT reader how to create widgets. The author has demonstrated how to create a Calendar widget and the Weather widget which uses the Yahoo Weather Really Simple Syndication(RSS) service. This is all detailed out in chapter 7.

The next chapter is all about creating and running unit tests for testing GWT applications and RPC services.The GWT creators essentialy wanted to give the user the complete Java development cycle experience and have thus incorporated unit testing by providing the GWTTestCase class which extends from the TestCase in the JUnit testing library. Chapter 8 shows you how to leverage just that.

A chapter is also dedicated to taking the reader through internationalizing a GWT app. And finally the last chapter takes you through the deployment of your RPC service. The author has used the Tomcat server and Ant for automated deployment.

All in all, highly recommended if you want to know what the creature called GWT is. Very readable and full of apps that are easy to follow and try out. Again, the book is meant for those starting on GWT. So you are not going to find any of theory stuff (for eg how GWT uses deferred binding) that an intermediate level user might want.

Google Web Toolkit GWT Java AJAX Programming
Paperback 240 pages [191mm x 235mm]
Release date February 2007
ISBN 1847191002
ISBN 13 978-1-847191-00-7
Author - Prabhakar Chaganti
Cover price - $44.99

imran's picture