Package org.jboss.msc.service
Enum ServiceController.State
- java.lang.Object
-
- java.lang.Enum<ServiceController.State>
-
- org.jboss.msc.service.ServiceController.State
-
- All Implemented Interfaces:
Serializable
,Comparable<ServiceController.State>
- Enclosing interface:
- ServiceController<S>
public static enum ServiceController.State extends Enum<ServiceController.State>
A possible state for a service controller.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
in(ServiceController.State... states)
Determine if this state is one of the given states.static ServiceController.State
valueOf(String name)
Returns the enum constant of this type with the specified name.static ServiceController.State[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
DOWN
public static final ServiceController.State DOWN
Down. All dependents are down.
-
STARTING
public static final ServiceController.State STARTING
Service is starting. Dependencies may not enter theDOWN
state. This state may not be left until thestart
method has finished or failed.
-
START_FAILED
public static final ServiceController.State START_FAILED
Start failed, or was cancelled. From this state, the start may be retried or the service may enter theDOWN
state.
-
UP
public static final ServiceController.State UP
Up.
-
STOPPING
public static final ServiceController.State STOPPING
Service is stopping. Dependents may not enter theSTARTING
state. This state may not be left until all dependents areDOWN
and thestop
method has finished.
-
REMOVED
public static final ServiceController.State REMOVED
Service was removed from the container.
-
-
Method Detail
-
values
public static ServiceController.State[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ServiceController.State c : ServiceController.State.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ServiceController.State 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 nameNullPointerException
- if the argument is null
-
in
public boolean in(ServiceController.State... states)
Determine if this state is one of the given states.- Parameters:
states
- the states to check- Returns:
true
if this state is in the set;false
otherwise
-
-