- 7.1. Seam events
- 7.2. Page actions
- 7.3. Page parameters
- 7.4. Propagating request parameters
- 7.5. URL rewriting with page parameters
- 7.6. Conversion and Validation
- 7.7. Navigation
- 7.8. Fine-grained files for defining navigation, page actions and parameters
- 7.9. Component-driven events
- 7.10. Contextual events
- 7.11. Seam interceptors
- 7.12. Managing exceptions
To complement the contextual component model, there are two further basic concepts that facilitate the extremely loose coupling distinctive of Seam applications. The first is a strong event model, where events are mapped to event listeners with method-binding expressions like those in JavaServer Faces (JSF). The second is the pervasive use of annotations and interceptors to apply cross-cutting concerns to components that implement business logic.
The Seam component model was developed for use with event-driven applications, specifically to enable the development of fine-grained, loosely-coupled components in a fine-grained eventing model. There are several event types in Seam:
- JSF events
- jBPM transition events
- Seam page actions
- Seam component-driven events
- Seam contextual events
Each of these events is mapped to Seam components with JSF EL method-binding expressions. For a JSF event, this is defined in the JSF template:
<h:commandButton value="Click me!" action="#{helloWorld.sayHello}"/>
For a jBPM transition event, it is specified in the jBPM process definition or pageflow definition:
<start-page name="hello" view-id="/hello.jsp"> <transition to="hello"> <action expression="#{helloWorld.sayHello}"/> </transition> </start-page>
More information about JSF events and jBPM events is available elsewhere. For now, we will concentrate upon the two additional event types defined by Seam.