June 2014
Intermediate to advanced
578 pages
12h 2m
English
JSF 2.0 allows us to use system events. These are events that can be fired by arbitrary objects at arbitrary points during the request processing lifecycle. Since the number of these events is quite big, you will not see them entirely covered here, but the next five examples should clarify the basic aspects of system events. You can find all of them in the javax.faces.event package.
The easiest way to use system event listeners consists in passing the name of the managed bean method in the listener attribute of the <f:event> tag. For example, PostValidateEvent is a system event that gets fired after all components are validated. This can be useful to validate multiple components. Suppose, that a ...