Enum Class ThreadStatus

java.lang.Object
java.lang.Enum<ThreadStatus>
com.jprofiler.api.platform.parameters.ThreadStatus
All Implemented Interfaces:
Serializable, Comparable<ThreadStatus>, Constable

public enum ThreadStatus extends Enum<ThreadStatus>
Represents all supported thread statuses.

These constants are used as parameters in various Connection methods.

  • Enum Constant Details

    • ALL

      public static final ThreadStatus ALL
      All thread statuses.
    • RUNNING

      public static final ThreadStatus RUNNING
      Only when the thread is running. More precisely if the thread is eligible to run, including the times when the scheduler of the operating system does not allocate CPU time to the thread.
    • SLEEPING

      public static final ThreadStatus SLEEPING
      Only when the thread is sleeping. This happens when a thread calls Object.wait() or uses corresponding facilities of java.util.concurrent.
    • BLOCKING

      public static final ThreadStatus BLOCKING
      Only when the thread is blocking. This happens when a thread tries to enter a contended synchronized method or block or uses corresponding facilities of java.util.concurrent.
    • NET_IO

      public static final ThreadStatus NET_IO
      Only when the thread is waiting for the network to accept or deliver data.
  • Method Details

    • values

      public static ThreadStatus[] 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 ThreadStatus 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
    • getName

      public String getName()
      Returns a verbose description of the thread status.
      Returns:
      the verbose description
    • toString

      public String toString()
      Overrides:
      toString in class Enum<ThreadStatus>