Package com.sun.faces.lifecycle
Class Phase
- java.lang.Object
-
- com.sun.faces.lifecycle.Phase
-
- Direct Known Subclasses:
ApplyRequestValuesPhase
,InvokeApplicationPhase
,ProcessValidationsPhase
,RenderResponsePhase
,RestoreViewPhase
,UpdateModelValuesPhase
public abstract class Phase extends Object
A Phase is a single step in the processing of a Jakarta Faces request throughout its entire
Lifecycle
. EachPhase
performs the required transitions on the state information in theFacesContext
associated with this request.
-
-
Constructor Summary
Constructors Constructor Description Phase()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
doPhase(FacesContext context, Lifecycle lifecycle, ListIterator<PhaseListener> listeners)
Performs PhaseListener processing and invokes the execute method of the Phase.abstract void
execute(FacesContext context)
Perform all state transitions required by the current phase of the request processingLifecycle
for a particular request.abstract PhaseId
getId()
protected void
handleAfterPhase(FacesContext context, ListIterator<PhaseListener> listenersIterator, PhaseEvent event)
HandleafterPhase
PhaseListener
events.protected void
handleBeforePhase(FacesContext context, ListIterator<PhaseListener> listenersIterator, PhaseEvent event)
HandlebeforePhase
PhaseListener
events.protected void
queueException(FacesContext ctx, Throwable t)
protected void
queueException(FacesContext ctx, Throwable t, String booleanKey)
-
-
-
Method Detail
-
doPhase
public void doPhase(FacesContext context, Lifecycle lifecycle, ListIterator<PhaseListener> listeners)
Performs PhaseListener processing and invokes the execute method of the Phase.- Parameters:
context
- the FacesContext for the current requestlifecycle
- the lifecycle for this request
-
execute
public abstract void execute(FacesContext context) throws FacesException
Perform all state transitions required by the current phase of the request processing
Lifecycle
for a particular request.- Parameters:
context
- FacesContext for the current request being processed- Throws:
FacesException
- if a processing error occurred while executing this phase
-
queueException
protected void queueException(FacesContext ctx, Throwable t)
-
queueException
protected void queueException(FacesContext ctx, Throwable t, String booleanKey)
-
handleAfterPhase
protected void handleAfterPhase(FacesContext context, ListIterator<PhaseListener> listenersIterator, PhaseEvent event)
HandleafterPhase
PhaseListener
events.- Parameters:
context
- the FacesContext for the current requestlistenersIterator
- a ListIterator for the PhaseListeners that need to be invokedevent
- the event to pass to each of the invoked listeners
-
handleBeforePhase
protected void handleBeforePhase(FacesContext context, ListIterator<PhaseListener> listenersIterator, PhaseEvent event)
HandlebeforePhase
PhaseListener
events.- Parameters:
context
- the FacesContext for the current requestlistenersIterator
- a ListIterator for the PhaseListeners that need to be invokedevent
- the event to pass to each of the invoked listeners
-
-