JSR-127, JavaServer Faces Specification Version: 1.1より抜粋
Each message queued within a FacesContext is an instance of the
javax.faces.application.FacesMessage class. It offers the following
2.1.3 Faces Request Generates Non-Faces Response
Normally, a JSF-based application will utilize the Render Response phase of the
request processing lifecycle to actually create the response that is sent back to the
client. In some circumstances, however, this behavior might not be desirable. For
- A Faces Request needs to be redirected to a different web application resource
(via a call to HttpServletResponse.sendRedirect).
Conversions and validations that failed will have caused messages to be enqueued
via calls to the addMessage() method of the FacesContext instance for the
current request, and the valid property on the corresponding component(s) will be
set to false.
instance is created by the JSF implementation, prior to beginning the request
processing lifecycle, by a call to the getFacesContext method of
FacesContextFactory, as described in Section 6.5 “FacesContextFactory”.