ErrorState (Apache Tomcat 9.0.106 API Documentation)
Description: declaration: package: org.apache.coyote, enum: ErrorState

# Enum ErrorState

java.lang.Object
java.lang.Enum<ErrorState>
org.apache.coyote.ErrorState

All Implemented Interfaces:
  `Serializable`, `Comparable<ErrorState>`, `java.lang.constant.Constable`

public enum ErrorState extends Enum<ErrorState>

- ## 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
  `CLOSE_CLEAN`
  The current request/response is in an error state and while it is safe to complete the current response it is not safe to continue to use the existing connection which must be closed once the response has been completed.
  `CLOSE_CONNECTION_NOW`
  An error has been detected that impacts the underlying network connection.
  `CLOSE_NOW`
  The current request/response is in an error state and it is not safe to continue to use them.
  `NONE`
  Not in an error state.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `ErrorState`
  `getMostSevere(ErrorState input)`
  Compare this ErrorState with the provided ErrorState and return the most severe.
  `boolean`
  `isConnectionIoAllowed()`
  `boolean`
  `isError()`
  `boolean`
  `isIoAllowed()`
  `static ErrorState`
  `valueOf(String name)`
  Returns the enum constant of this type with the specified name.
  `static ErrorState[]`
  `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, 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

  - ### NONE

    public static final ErrorState NONE
    Not in an error state.

  - ### CLOSE_CLEAN

    public static final ErrorState CLOSE_CLEAN
    The current request/response is in an error state and while it is safe to complete the current response it is not safe to continue to use the existing connection which must be closed once the response has been completed. For multiplexed protocols, the channel must be closed when the current request/response completes but the connection may continue.

  - ### CLOSE_NOW

    public static final ErrorState CLOSE_NOW
    The current request/response is in an error state and it is not safe to continue to use them. For multiplexed protocols (such as HTTP/2) the stream/channel must be closed immediately but the connection may continue. For non-multiplexed protocols (AJP, HTTP/1.x) the current connection must be closed.

  - ### CLOSE_CONNECTION_NOW

    public static final ErrorState CLOSE_CONNECTION_NOW
    An error has been detected that impacts the underlying network connection. It is not safe to continue using the network connection which must be closed immediately. For multiplexed protocols (such as HTTP/2) this impacts all multiplexed channels.

- ## Method Details

  - ### values

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

  - ### valueOf

    public static ErrorState valueOf(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:
      `IllegalArgumentException` - if this enum type has no constant with the specified name
      `NullPointerException` - if the argument is null

  - ### isError

    public boolean isError()

  - ### getMostSevere

    public ErrorState getMostSevere(ErrorState input)
    Compare this ErrorState with the provided ErrorState and return the most severe.
    Parameters:
      `input` - The error state to compare to this one
    Returns:
      The most severe error state from the provided error state and this one

  - ### isIoAllowed

    public boolean isIoAllowed()

  - ### isConnectionIoAllowed

    public boolean isConnectionIoAllowed()