My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
LibraryOverview  
A high-level tour of the major components of GWTP.
Type-Documentation
Updated May 6, 2011 by philippe.beaudoin

Introduction

This document will give you a high-level tour of the major components. To jump right in, read the Getting Started page or the javadoc. For more details on the jars related to these different components see DescriptionOfIndividualJars.

Components

GWTP offers the following components:

  • mvp contains the base classes of a Model-View-Presenter framework ;
  • dispatch simplifies the process of writing RPC by using the command pattern ;
  • crawler is a simple server-side component that makes your web app crawlable by search engines.
  • crawler-service is the implementation of a simple service that uses HTML unit to render AJAX pages, and is the complement to crawler.
  • localizer is a collection of scripts and classes to help localization
  • annotation is a collection of annotation processing tools that can generate boilerplate for events, actions and DTOs.
  • tester is a set of utility classes that make testing your MVP app simpler, especially when using dependency injection with GIN and Guice.

MVP

The MVP component is the core of GWTP. It contains a collection of client-side Java classes that lets you organize your application into a loosely connected collection of Presenter-View pairs, following Google's recommended approach. For more information on this, follow the Getting Started tutorial.

Dispatch

The dispatch component allows your application to communicate with the server via the well-known Command design pattern. This let's you easily address cross-cutting concerns like action validation or undo stacks. For the moment, this module's documentation is minimal. However, since it is a fork from the excellent GWT Dispatch, you will find a lot of information over there. Don't hesitate to ask in our Google Group if you have questions related to GWTP's new features.

Crawler

The goal of the crawler module is to make your AJAX application crawlable from any search engines supporting Google's proposed approach. It uses a simple filter to access the crawler service described below. The crawler filter can be used on AppEngine or with any other servlet container.

Crawler Service

The crawler service is a simple implementation of a service that can render AJAX pages. It is designed to run on AppEngine but can be called by your application even if this one runs on another servlet container. It is meant to be called by the crawler filter described above.

Annotation

The annotation module combines a number of annotation processors that lets you easily generate tedious boilerplate code for events, dispatcher actions and their responses, and DTOs.

Localizer

For the moment, this component only offers the MergeLocale script to help organize the property files generated by GWT localization tools. It's particularly useful when internationalizing UIBinder files, as mentioned in the GWT documentation.

Tester

This component offers a number of classes to facilitate testing of an application built with GWTP. This includes utilities to facilitate mocking the Provider and AsyncProvider, to stub the dispatcher, etc.

Most of these components can be used with any testing framework, but some are targeted more specifically towards the use of JUnit and mockito. They simplify the setup process when using dependency injection. The mockito-dependent code is entirely contained in gwtp-mockito.jar.

(Note: As of version 0.4, this module is currently in development and shouldn't be used.)


Sign in to add a comment
Powered by Google Project Hosting