Sunday, June 3, 2007

Tiles 2

Apache Tiles is a templating framework built to simplify the development of web application user interfaces. Tiles allows authors to define page fragments which can be assembled into a complete page at runtime. These fragments, or tiles, can be used as simple includes in order to reduce the duplication of common page elements or embedded within other tiles to develop a series of reusable templates. These templates streamline the development of a consistent look and feel across an entire application. Tiles grew in popularity as a component of the popular Struts framework. It has since been extracted from Struts and is now integrated with various frameworks, such as Struts 2 and Shale.

Some of FAQ to clearly the deference between "Struts Tiles" and "Tiles2":
Is Tiles2 compatible with the version of tiles I've been using with Struts?
No. Struts-Tiles is an ancestor of Tiles 2 which grew out of the Struts project. This version is a total redesign which makes the framework easier to embed within frameworks such as Struts and Shale.
If you're a casual user, you'll probably only notice the differences in the tag libraries and in Tiles definition files. Many of them have been renamed for clarity sake and you can upgrade to Tiles2 by simple doing a global find and replace.
If you're integrating Tiles into a framework or using it for more advanced features, then you'll probably notice a world of difference. Tiles now runs as a container which encapsulates it's feature set and there is a much cleaner API. If you find that this api doesn't suffice for you, please hop on the developer list and help us flush out the next generation of Tiles!
Why should I move from Struts-Tiles to Tiles 2?
Tiles 2 can be used outside of Struts: it has been integrated into Struts 1, Struts 2 and Shale.
Why did you change everything in Tiles 2?
To improve learning of Tiles. After the refactoring, the APIs, the TLD and the DTD are clearer than before.

For more info:
Struts Tiles: http://struts.apache.org/1.x/struts-tiles/
Tiles2: http://tiles.apache.org/

No comments: