Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Many of the basic concepts in Tapestry 4 are still present in Tapestry 5, but refactored, improved, streamlined, and simplified. The basic concept of pages, templates and components are largely the same. Other aspects, such as server-side event handling, is markedly different.

Why are there both Request and HttpServletRequest?

Tapestry's Request interface is very close to the standard HttpServletRequest interface. It differs in a few ways, omitting
some unneeded methods, and adding a couple of new methods (such as isXHR()), as well as changing how some existing methods
operate. For example, getParameterNames() returns a sorted List of Strings; HttpServletRequest returns an Enumeration,
which is a very dated approach.

However, the stronger reason for Request (and the related interfaces Response and Session) is to enable
the support for Portlets at some point in the future. By writing code in terms of Tapestry's Request,
and not HttpServletRequest, you can be assured that the same code will operate in both Servlet Tapestry
and Portlet Tapestry.

...

Footnotes Display