Class FlowFacesContext
java.lang.Object
jakarta.faces.context.FacesContext
jakarta.faces.context.FacesContextWrapper
org.springframework.faces.webflow.FlowFacesContext
- All Implemented Interfaces:
jakarta.faces.FacesWrapper<jakarta.faces.context.FacesContext>
public class FlowFacesContext
extends jakarta.faces.context.FacesContextWrapper
Custom
FacesContext
implementation that delegates all standard FacesContext messaging functionality to a
Spring MessageSource
made accessible as part of the current Web Flow request. Additionally, it manages the
renderResponse
flag in flash scope so that the execution of the JSF Lifecycle
may span multiple
requests in the case of the POST+REDIRECT+GET pattern being enabled.- Author:
- Jeremy Grelle, Phillip Webb, Rossen Stoyanchev
- See Also:
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionFlowFacesContext
(RequestContext context, jakarta.faces.context.FacesContext wrapped) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addMessage
(String clientId, jakarta.faces.application.FacesMessage message) Translates a FacesMessage to a Spring Web Flow message and adds it to the current MessageContextReturns an Iterator for all component clientId's for which messages have been added.jakarta.el.ELContext
jakarta.faces.context.ExternalContext
jakarta.faces.application.FacesMessage.Severity
Return the maximum severity level recorded on any FacesMessages that has been queued, whether or not they are associated with any specific UIComponent.List<jakarta.faces.application.FacesMessage>
Returns a List for all Messages in the current MessageContext that does translation to FacesMessages.List<jakarta.faces.application.FacesMessage>
getMessageList
(String clientId) Returns a List for all Messages with the given clientId in the current MessageContext that does translation to FacesMessages.Iterator<jakarta.faces.application.FacesMessage>
Returns an Iterator for all Messages in the current MessageContext that does translation to FacesMessages.Iterator<jakarta.faces.application.FacesMessage>
getMessages
(String clientId) Returns an Iterator for all Messages with the given clientId in the current MessageContext that does translation to FacesMessages.jakarta.faces.context.PartialViewContext
boolean
boolean
jakarta.faces.context.FacesContext
boolean
boolean
static FlowFacesContext
newInstance
(RequestContext context, jakarta.faces.lifecycle.Lifecycle lifecycle) void
release()
void
void
Methods inherited from class jakarta.faces.context.FacesContextWrapper
getApplication, getAttributes, getCurrentPhaseId, getExceptionHandler, getLifecycle, getNamingContainerSeparatorChar, getRenderKit, getResourceLibraryContracts, getResponseStream, getResponseWriter, getViewRoot, isProcessingEvents, isProjectStage, isReleased, setCurrentPhaseId, setExceptionHandler, setProcessingEvents, setResourceLibraryContracts, setResponseStream, setResponseWriter, setViewRoot, validationFailed
Methods inherited from class jakarta.faces.context.FacesContext
getCurrentInstance, setCurrentInstance
-
Constructor Details
-
FlowFacesContext
-
-
Method Details
-
getWrapped
public jakarta.faces.context.FacesContext getWrapped()- Specified by:
getWrapped
in interfacejakarta.faces.FacesWrapper<jakarta.faces.context.FacesContext>
- Overrides:
getWrapped
in classjakarta.faces.context.FacesContextWrapper
-
release
public void release()- Overrides:
release
in classjakarta.faces.context.FacesContextWrapper
-
getExternalContext
public jakarta.faces.context.ExternalContext getExternalContext()- Overrides:
getExternalContext
in classjakarta.faces.context.FacesContextWrapper
-
getPartialViewContext
public jakarta.faces.context.PartialViewContext getPartialViewContext()- Overrides:
getPartialViewContext
in classjakarta.faces.context.FacesContextWrapper
-
getELContext
public jakarta.el.ELContext getELContext()- Overrides:
getELContext
in classjakarta.faces.context.FacesContextWrapper
-
getRenderResponse
public boolean getRenderResponse()- Overrides:
getRenderResponse
in classjakarta.faces.context.FacesContextWrapper
-
getResponseComplete
public boolean getResponseComplete()- Overrides:
getResponseComplete
in classjakarta.faces.context.FacesContextWrapper
-
renderResponse
public void renderResponse()- Overrides:
renderResponse
in classjakarta.faces.context.FacesContextWrapper
-
responseComplete
public void responseComplete()- Overrides:
responseComplete
in classjakarta.faces.context.FacesContextWrapper
-
isValidationFailed
public boolean isValidationFailed()- Overrides:
isValidationFailed
in classjakarta.faces.context.FacesContextWrapper
-
addMessage
Translates a FacesMessage to a Spring Web Flow message and adds it to the current MessageContext- Overrides:
addMessage
in classjakarta.faces.context.FacesContextWrapper
-
getClientIdsWithMessages
Returns an Iterator for all component clientId's for which messages have been added.- Overrides:
getClientIdsWithMessages
in classjakarta.faces.context.FacesContextWrapper
-
getMaximumSeverity
public jakarta.faces.application.FacesMessage.Severity getMaximumSeverity()Return the maximum severity level recorded on any FacesMessages that has been queued, whether or not they are associated with any specific UIComponent. If no such messages have been queued, return null.- Overrides:
getMaximumSeverity
in classjakarta.faces.context.FacesContextWrapper
-
getMessages
Returns an Iterator for all Messages in the current MessageContext that does translation to FacesMessages.- Overrides:
getMessages
in classjakarta.faces.context.FacesContextWrapper
-
getMessageList
Returns a List for all Messages in the current MessageContext that does translation to FacesMessages.- Overrides:
getMessageList
in classjakarta.faces.context.FacesContextWrapper
-
getMessages
Returns an Iterator for all Messages with the given clientId in the current MessageContext that does translation to FacesMessages.- Overrides:
getMessages
in classjakarta.faces.context.FacesContextWrapper
-
getMessageList
Returns a List for all Messages with the given clientId in the current MessageContext that does translation to FacesMessages.- Overrides:
getMessageList
in classjakarta.faces.context.FacesContextWrapper
-
isPostback
public boolean isPostback()- Overrides:
isPostback
in classjakarta.faces.context.FacesContextWrapper
-
newInstance
public static FlowFacesContext newInstance(RequestContext context, jakarta.faces.lifecycle.Lifecycle lifecycle)
-