Enum UwsStage

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<UwsStage>

    public enum UwsStage
    extends java.lang.Enum<UwsStage>
    Enum for categorising the stage of UWS processing. This effectively subdivides the various phases defined by UWS.
    Since:
    17 Feb 2011
    Author:
    Mark Taylor
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      FINISHED
      Job has finished successfully or otherwise; will not progress further.
      ILLEGAL
      Not a defined phase string.
      RUNNING
      Job is progressing; should reach FINISHED stage eventually.
      UNKNOWN
      UNKNOWN phase; may change in future.
      UNSTARTED
      Job will not complete of its own accord; need to post RUN phase.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static UwsStage forPhase​(java.lang.String phase)
      Returns the stage corresponding to a given UWS phase.
      java.util.Collection<java.lang.String> getPhaseList()
      Returns the phases which correspond to this stage.
      static UwsStage valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static UwsStage[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • UNSTARTED

        public static final UwsStage UNSTARTED
        Job will not complete of its own accord; need to post RUN phase.
      • RUNNING

        public static final UwsStage RUNNING
        Job is progressing; should reach FINISHED stage eventually.
      • FINISHED

        public static final UwsStage FINISHED
        Job has finished successfully or otherwise; will not progress further.
      • UNKNOWN

        public static final UwsStage UNKNOWN
        UNKNOWN phase; may change in future.
      • ILLEGAL

        public static final UwsStage ILLEGAL
        Not a defined phase string.
    • Method Detail

      • values

        public static UwsStage[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (UwsStage c : UwsStage.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static UwsStage valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getPhaseList

        public java.util.Collection<java.lang.String> getPhaseList()
        Returns the phases which correspond to this stage.
        Returns:
        unmodifiable collection of defined phase strings
      • forPhase

        public static UwsStage forPhase​(java.lang.String phase)
        Returns the stage corresponding to a given UWS phase. If the given phase is not one defined by UWS, ILLEGAL is returned.
        Parameters:
        phase - UWS phase string
        Returns:
        corresponding stage