Package fr.gouv.vitam.common.model

# Enum Class StatusCode

java.lang.Object
java.lang.Enum<StatusCode>
fr.gouv.vitam.common.model.StatusCode

All Implemented Interfaces:
  `Serializable`, `Comparable<StatusCode>`, `Constable`

public enum StatusCode extends Enum<StatusCode>
Enum StatusCode different constants status code for workflow , action handler and process

- ## Nested Class Summary

  ## Nested classes/interfaces inherited from class java.lang.Enum

  `Enum.EnumDesc<E extends Enum<E>>`

- ## Enum Constant Summary

  Enum Constants
  Enum Constant
  Description
  `ALREADY_EXECUTED`
  ALREADY_EXECUTED : indicates that a particular step / action has already been processed
  `FATAL`
  FATAL : indicates a critical error such as technical Exception ( runtime exception, illegal argument exception, null pointer exception ...)
  `KO`
  KO : indicates the failed execution of the action
  `OK`
  OK : indicates the successful without warning
  `STARTED`
  STARTED : indicates that the workflow or the action handler or the process has been started
  `UNKNOWN`
  UNKNOWN : indicates that the workflow or the action handler or the process is in unknown status!
  `WARNING`
  WARNING : indicates successful with a general warning.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `jakarta.ws.rs.core.Response.Status`
  `getEquivalentHttpStatus()`
  `int`
  `getStatusLevel()`
  `boolean`
  `isGreaterOrEqualToFatal()`
  `boolean`
  `isGreaterOrEqualToKo()`
  `boolean`
  `isGreaterOrEqualToStarted()`
  `boolean`
  `isGreaterOrEqualToWarn()`
  `static StatusCode`
  `valueOf(String name)`
  Returns the enum constant of this class with the specified name.
  `static StatusCode[]`
  `values()`
  Returns an array containing the constants of this enum class, in the order they are declared.

  ### Methods inherited from class java.lang.Enum

  `clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

  ### Methods inherited from class java.lang.Object

  `getClass, notify, notifyAll, wait, wait, wait`

- ## Enum Constant Details

  - ### UNKNOWN

    public static final StatusCode UNKNOWN
    UNKNOWN : indicates that the workflow or the action handler or the process is in unknown status!

  - ### STARTED

    public static final StatusCode STARTED
    STARTED : indicates that the workflow or the action handler or the process has been started

  - ### ALREADY_EXECUTED

    public static final StatusCode ALREADY_EXECUTED
    ALREADY_EXECUTED : indicates that a particular step / action has already been processed

  - ### OK

    public static final StatusCode OK
    OK : indicates the successful without warning

  - ### WARNING

    public static final StatusCode WARNING
    WARNING : indicates successful with a general warning. Warning are often useful in preventing future Action problems

  - ### KO

    public static final StatusCode KO
    KO : indicates the failed execution of the action

  - ### FATAL

    public static final StatusCode FATAL
    FATAL : indicates a critical error such as technical Exception ( runtime exception, illegal argument exception, null pointer exception ...)

- ## Method Details

  - ### values

    public static StatusCode[] 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 StatusCode 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

  - ### getStatusLevel

    public int getStatusLevel()
    Returns:
      Status Level

  - ### isGreaterOrEqualToWarn

    public boolean isGreaterOrEqualToWarn()
    Returns:
      True if the status is greater or equal to WARN

  - ### isGreaterOrEqualToKo

    public boolean isGreaterOrEqualToKo()
    Returns:
      True if the status is greater or equal to KO

  - ### isGreaterOrEqualToFatal

    public boolean isGreaterOrEqualToFatal()
    Returns:
      True if the status is greater or equal to FATAL

  - ### isGreaterOrEqualToStarted

    public boolean isGreaterOrEqualToStarted()

  - ### getEquivalentHttpStatus

    public jakarta.ws.rs.core.Response.Status getEquivalentHttpStatus()
    Returns:
      the HTTP Status equivalent to this StatusCode for OK, KO and WARNING status