Class LifecycleImpl

java.lang.Object
jakarta.faces.lifecycle.Lifecycle
com.sun.faces.lifecycle.LifecycleImpl

public class LifecycleImpl extends Lifecycle

LifecycleImpl is the stock implementation of the standard Lifecycle in the Jakarta Faces RI.

  • Constructor Details

    • LifecycleImpl

      public LifecycleImpl()
    • LifecycleImpl

      public LifecycleImpl(FacesContext context)
  • Method Details

    • attachWindow

      public void attachWindow(FacesContext context)
      Description copied from class: Lifecycle

      Create or restore the ClientWindow to be used to display the UIViewRoot for this run through the lifecycle. See the class documentation for ClientWindow for an overview of the feature. If ExternalContext.getClientWindow() returns null, create a new instance of ClientWindow using the ClientWindowFactory. If the result is non-null, call ClientWindow.decode(jakarta.faces.context.FacesContext) on it. Store the new ClientWindow by calling ExternalContext.setClientWindow(jakarta.faces.lifecycle.ClientWindow).

      Overrides:
      attachWindow in class Lifecycle
      Parameters:
      context - the FacesContext for this request.
    • execute

      public void execute(FacesContext context) throws FacesException
      Description copied from class: Lifecycle

      Execute all of the phases of the request processing lifecycle, up to but not including the Render Response phase, as described in section 2 "Request Processing Lifecycle" of the Jakarta Faces Specification Document, in the specified order. The processing flow can be affected (by the application, by components, or by event listeners) by calls to the renderResponse() or responseComplete() methods of the FacesContext instance associated with the current request.

      Specified by:
      execute in class Lifecycle
      Parameters:
      context - FacesContext for the request to be processed
      Throws:
      FacesException - if thrown during the execution of the request processing lifecycle
    • render

      public void render(FacesContext context) throws FacesException
      Description copied from class: Lifecycle

      Execute the Render Response phase of the request processing lifecycle, unless the responseComplete() method has been called on the FacesContext instance associated with the current request.

      Specified by:
      render in class Lifecycle
      Parameters:
      context - FacesContext for the request being processed
      Throws:
      FacesException - if an exception is thrown during the execution of the request processing lifecycle
    • addPhaseListener

      public void addPhaseListener(PhaseListener listener)
      Description copied from class: Lifecycle

      Register a new PhaseListener instance that is interested in being notified before and after the processing for standard phases of the request processing lifecycle.

      Specified by:
      addPhaseListener in class Lifecycle
      Parameters:
      listener - The PhaseListener to be registered
    • getPhaseListeners

      public PhaseListener[] getPhaseListeners()
      Description copied from class: Lifecycle

      Return the set of registered PhaseListeners for this Lifecycle instance. If there are no registered listeners, a zero-length array is returned.

      Specified by:
      getPhaseListeners in class Lifecycle
      Returns:
      the set of registered PhaseListeners
    • removePhaseListener

      public void removePhaseListener(PhaseListener listener)
      Description copied from class: Lifecycle

      Deregister an existing PhaseListener instance that is no longer interested in being notified before and after the processing for standard phases of the request processing lifecycle. If no such listener instance has been registered, no action is taken.

      Specified by:
      removePhaseListener in class Lifecycle
      Parameters:
      listener - The PhaseListener to be deregistered