Class PhaseId

  • All Implemented Interfaces:
    java.lang.Comparable

    public class PhaseId
    extends java.lang.Object
    implements java.lang.Comparable

    Typesafe enumeration of the legal values that may be returned by the getPhaseId() method of the FacesEvent interface.

    • Field Summary

      Fields 
      Modifier and Type Field Description
      static PhaseId ANY_PHASE
      Identifier that indicates an interest in events, no matter which request processing phase is being performed.
      static PhaseId APPLY_REQUEST_VALUES
      Identifier that indicates an interest in events queued for the Apply Request Values phase of the request processing lifecycle.
      static PhaseId INVOKE_APPLICATION
      Identifier that indicates an interest in events queued for the Invoke Application phase of the request processing lifecycle.
      static PhaseId PROCESS_VALIDATIONS
      Identifier that indicates an interest in events queued for the Process Validations phase of the request processing lifecycle.
      static PhaseId RENDER_RESPONSE
      Identifier for the Render Response phase of the request processing lifecycle.
      static PhaseId RESTORE_VIEW
      Identifier that indicates an interest in events queued for the Restore View phase of the request processing lifecycle.
      static PhaseId UPDATE_MODEL_VALUES
      Identifier that indicates an interest in events queued for the Update Model Values phase of the request processing lifecycle.
      static java.util.List<PhaseId> VALUES
      List of valid PhaseId instances, in ascending order of their ordinal value.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int compareTo​(java.lang.Object other)
      Compare this PhaseId instance to the specified one.
      java.lang.String getName()
      Return the name of this phase.
      int getOrdinal()
      Return the ordinal value of this PhaseId instance.
      static PhaseId phaseIdValueOf​(java.lang.String phase)
      Return a PhaseId representation of the arcument phase.
      java.lang.String toString()
      Return a String representation of this PhaseId instance.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • ANY_PHASE

        public static final PhaseId ANY_PHASE

        Identifier that indicates an interest in events, no matter which request processing phase is being performed.

      • RESTORE_VIEW

        public static final PhaseId RESTORE_VIEW

        Identifier that indicates an interest in events queued for the Restore View phase of the request processing lifecycle.

      • APPLY_REQUEST_VALUES

        public static final PhaseId APPLY_REQUEST_VALUES

        Identifier that indicates an interest in events queued for the Apply Request Values phase of the request processing lifecycle.

      • PROCESS_VALIDATIONS

        public static final PhaseId PROCESS_VALIDATIONS

        Identifier that indicates an interest in events queued for the Process Validations phase of the request processing lifecycle.

      • UPDATE_MODEL_VALUES

        public static final PhaseId UPDATE_MODEL_VALUES

        Identifier that indicates an interest in events queued for the Update Model Values phase of the request processing lifecycle.

      • INVOKE_APPLICATION

        public static final PhaseId INVOKE_APPLICATION

        Identifier that indicates an interest in events queued for the Invoke Application phase of the request processing lifecycle.

      • RENDER_RESPONSE

        public static final PhaseId RENDER_RESPONSE

        Identifier for the Render Response phase of the request processing lifecycle.

      • VALUES

        public static final java.util.List<PhaseId> VALUES

        List of valid PhaseId instances, in ascending order of their ordinal value.

    • Method Detail

      • compareTo

        public int compareTo​(java.lang.Object other)

        Compare this PhaseId instance to the specified one. Returns a negative integer, zero, or a positive integer if this object is less than, equal to, or greater than the specified object.

        Specified by:
        compareTo in interface java.lang.Comparable
        Parameters:
        other - The other object to be compared to
      • getOrdinal

        public int getOrdinal()

        Return the ordinal value of this PhaseId instance.

        Returns:
        the ordinal
      • toString

        public java.lang.String toString()

        Return a String representation of this PhaseId instance.

        Overrides:
        toString in class java.lang.Object
      • getName

        public java.lang.String getName()

        Return the name of this phase.

        Returns:
        the name
        Since:
        2.2
      • phaseIdValueOf

        public static PhaseId phaseIdValueOf​(java.lang.String phase)

        Return a PhaseId representation of the arcument phase.

        Parameters:
        phase - the String for which the corresponding PhaseId should be returned.
        Returns:
        the phase id corresponding to the argument phase
        Throws:
        java.lang.NullPointerException - if argument phase is null.
        FacesException - if the PhaseId corresponding to the argument phase cannot be found.
        Since:
        2.2