java.lang.Object
java.lang.Enum<NeedsCleaning>
org.sentrysoftware.metricshub.engine.common.helpers.state.NeedsCleaning
All Implemented Interfaces:
Serializable, Comparable<NeedsCleaning>, Constable, IState

public enum NeedsCleaning extends Enum<NeedsCleaning> implements IState
The NeedsCleaning enum represents different states related to the need for cleaning. It implements the IState interface and includes methods for interpreting state values.
  • Enum Constant Details

    • OK

      public static final NeedsCleaning OK
      OK state indicating no immediate need for cleaning.
    • NEEDED

      public static final NeedsCleaning NEEDED
      NEEDED state indicating that cleaning is needed.
    • NEEDED_IMMEDIATELY

      public static final NeedsCleaning NEEDED_IMMEDIATELY
      NEEDED_IMMEDIATELY state indicating an immediate need for cleaning.
  • Method Details

    • values

      public static NeedsCleaning[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static NeedsCleaning valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • interpret

      public static Optional<NeedsCleaning> interpret(String state)
      Interpret the specified state value:
      • { 0 } as OK
      • { 1 } as NEEDED
      • { 2 } as NEEDED_IMMEDIATELY
      Parameters:
      state - String to be interpreted
      Returns:
      Optional of NeedsCleaning