com.ace.moab.api.node
Enum NodeState

java.lang.Object
  extended by java.lang.Enum<NodeState>
      extended by com.ace.moab.api.node.NodeState
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<NodeState>

public enum NodeState
extends java.lang.Enum<NodeState>

This enum tracks the state of a node.


Enum Constant Summary
BUSY
          The node is running workload and cannot accept more.
DOWN
          The node is not available for workload.
DRAINED
          The node has been sent the drain request and has no workload on it.
DRAINING
          The node has been sent the drain request, but still has workload on it.
FLUSH
          The node is being reprovisioned.
IDLE
          The node is available for workload but is not running anything.
NONE
          The node is set to none by the resource manager.
RESERVED
          The node is being reserved.
RUNNING
          The node is running workload and can accept more.
UNKNOWN
          The state of the node is unknown.
UP
          The node is up, but the usage is being determined.
 
Method Summary
static java.util.List<java.lang.String> getStateStrings()
          Gets a list of options in a string format.
static NodeState parseNodeStateString(java.lang.String string)
          Parses a string and translates it into a respective NodeState enum value.
 java.lang.String toString()
           
static NodeState valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static NodeState[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

NONE

public static final NodeState NONE
The node is set to none by the resource manager.


DOWN

public static final NodeState DOWN
The node is not available for workload.


IDLE

public static final NodeState IDLE
The node is available for workload but is not running anything.


BUSY

public static final NodeState BUSY
The node is running workload and cannot accept more.


RUNNING

public static final NodeState RUNNING
The node is running workload and can accept more.


DRAINED

public static final NodeState DRAINED
The node has been sent the drain request and has no workload on it.


DRAINING

public static final NodeState DRAINING
The node has been sent the drain request, but still has workload on it.


FLUSH

public static final NodeState FLUSH
The node is being reprovisioned.


RESERVED

public static final NodeState RESERVED
The node is being reserved. This is an internal Moab state.


UNKNOWN

public static final NodeState UNKNOWN
The state of the node is unknown.


UP

public static final NodeState UP
The node is up, but the usage is being determined.

Method Detail

values

public static final NodeState[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(NodeState c : NodeState.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static NodeState valueOf(java.lang.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:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name

parseNodeStateString

public static NodeState parseNodeStateString(java.lang.String string)
                                      throws java.text.ParseException
Parses a string and translates it into a respective NodeState enum value.

Parameters:
string - the string to parse.
Returns:
the corresponding NodeState object.
Throws:
java.text.ParseException - if the string cannot be parsed into a valid NodeState enum value.

getStateStrings

public static java.util.List<java.lang.String> getStateStrings()
Gets a list of options in a string format.

Returns:
a list of state options in string format.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Enum<NodeState>


Copyright © 2001-2009 Cluster Resources, Inc. All Rights Reserved.