|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ow2.clif.supervisor.api.BladeState
public class BladeState
Representation of a blade state and utility methods to determine a global state resulting from individual blades states.
Field Summary | |
---|---|
static BladeState |
ABORTED
|
protected int |
code
integer value uniquely representing a blade state |
static BladeState |
COMPLETED
|
static BladeState |
DEPLOYED
|
static BladeState |
DEPLOYING
|
static BladeState |
INCOHERENT
|
static BladeState |
INITIALIZED
|
static BladeState |
INITIALIZING
|
protected java.lang.String |
label
an explicit state name (running, stopping, stopped...) |
static BladeState |
NONE
|
static BladeState |
RESUMING
|
static BladeState |
RUNNING
|
static BladeState |
STARTING
|
static BladeState |
STOPPED
|
static BladeState |
STOPPING
|
static BladeState |
SUSPENDED
|
static BladeState |
SUSPENDING
|
static BladeState |
UNDEPLOYED
|
Constructor Summary | |
---|---|
protected |
BladeState(java.lang.String label)
Creates a BladeState instance with the provided state label (unique name), and associates a unique code to this object. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
equality is based on the state code value |
static BladeState |
get(int code)
Gets the blade state instance associated to a state code |
int |
getCode()
Gets the unique code representing this blade state. |
static BladeState |
getGlobalState(java.util.Collection<BladeState> states)
Return the global state resulting from some individual states. |
static boolean |
isRunning(java.util.Collection<BladeState> states)
Determines if the global state resulting from some individual states is "running", i.e. if at least one state is "running" and the others are either running or terminated (stopped, completed or aborted). |
static boolean |
isStationaryState(java.util.Collection<BladeState> states)
Determines if the global state resulting from some individual states is a stationary state or a transitional state. |
java.lang.String |
toString()
Gets the explicit name of this state (e.g. running, stopped, etc.) |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final BladeState UNDEPLOYED
public static final BladeState DEPLOYING
public static final BladeState DEPLOYED
public static final BladeState INITIALIZING
public static final BladeState INITIALIZED
public static final BladeState STARTING
public static final BladeState RUNNING
public static final BladeState SUSPENDING
public static final BladeState SUSPENDED
public static final BladeState RESUMING
public static final BladeState COMPLETED
public static final BladeState STOPPING
public static final BladeState STOPPED
public static final BladeState ABORTED
public static final BladeState INCOHERENT
public static final BladeState NONE
protected int code
protected transient java.lang.String label
Constructor Detail |
---|
protected BladeState(java.lang.String label)
get(int)
instead.
label
- an explicit, and preferably unique and short, name describing
this state.Method Detail |
---|
public static BladeState get(int code)
code
- the code representing a blade state
public static BladeState getGlobalState(java.util.Collection<BladeState> states)
states
- individual states.
public static boolean isStationaryState(java.util.Collection<BladeState> states)
states
- individual states
public static boolean isRunning(java.util.Collection<BladeState> states)
states
- individual states
public java.lang.String toString()
toString
in class java.lang.Object
public int getCode()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |