Package com.tailf.ha

Enum Class HaStateType

Object
Enum<HaStateType>
com.tailf.ha.HaStateType
All Implemented Interfaces:
Serializable, Comparable<HaStateType>, Constable

public enum HaStateType extends Enum<HaStateType>
This enum describes the different states a HA node can be in.
  • 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
    NONE implies that the node is not participating in a HA cluster.
    PRIMARY implies that the node is primary in a HA cluster.
    SECONDARY implies that the node is secondary in a HA cluster.
    SECONDARY_RELAY implies that the node is secondary in a HA cluster, that may also have "sub-secondaries" (after a beRelay() call).
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Get the integer value represented by this enum value.
    valueOf(int i)
    Instantiates an HaStateType from an integer value.
    Returns the enum constant of this class with the specified name.
    static HaStateType[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Enum

    compareTo, describeConstable, equals, 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 HaStateType NONE
      NONE implies that the node is not participating in a HA cluster.
    • SECONDARY

      public static final HaStateType SECONDARY
      SECONDARY implies that the node is secondary in a HA cluster.
    • PRIMARY

      public static final HaStateType PRIMARY
      PRIMARY implies that the node is primary in a HA cluster.
    • SECONDARY_RELAY

      public static final HaStateType SECONDARY_RELAY
      SECONDARY_RELAY implies that the node is secondary in a HA cluster, that may also have "sub-secondaries" (after a beRelay() call).
  • Method Details

    • values

      public static HaStateType[] 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 HaStateType 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
    • getValue

      public int getValue()
      Get the integer value represented by this enum value.
      Returns:
      integer value for enum
    • valueOf

      public static HaStateType valueOf(int i)
      Instantiates an HaStateType from an integer value.
      Parameters:
      i - - integer value representing the HaStateType
      Returns:
      an HaStateType object