Page And Component ClassesPage added by Howard M. Lewis ShipWhat's the difference between a page and a component?There's very little difference between the two. Pages clases must be in the root-package.pages package; components must be in the Other than that, they are more equal than they are different. They may have templates or may render themselves in code (pages usually have a template, components are more likely to render only in code). The major difference is that Tapestry page templates may be stored in the web context directory, as if they were static files (they can't be accessed from the client however; a specific rule prevents access to files with the .tml extension).
How do I store my page classes in a different package?Tapestry is very rigid here; you can't. Page classes must go in root-package.pages, component classes in root-package.components, etc. Why do my instance variables have to be private?Tapestry does a large amount of transformation to your simple POJO classes as it loads them into memory. In many cases, it must locate every read or write of an instance variable and change its behavior; for example, reading a field that is a component parameter will Limiting fields to private means that Tapestry can do the necessary processing one class at a time, as needed, at runtime. More complex
Change Notification Preferences
View Online
|
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
- [CONF] Apache Tapestry > Page And Component Classes confluence
