public enum State extends Enum<State>
| Enum Constant and Description |
|---|
INIT |
INSTALL_FAILED |
INSTALLED |
INSTALLING |
STARTED |
STARTING |
STOPPED |
STOPPING |
TERMINATING |
UPGRADED |
UPGRADING |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canIssueCommands()
Indicates whether or not it is a valid state to produce a command.
|
boolean |
couldHaveIssued(Command command) |
State |
getNextState(Command command)
Returns next state based on the command.
|
State |
getNextState(CommandResult result)
Returns next state based on the command result.
|
Command |
getSupportedCommand()
Returns valid command in this state.
|
Command |
getSupportedCommand(boolean isInUpgradeMode) |
Command |
getSupportedCommand(boolean isInUpgradeMode,
boolean stopInitiated) |
static State |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static State[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final State INIT
public static final State INSTALLING
public static final State INSTALLED
public static final State STARTING
public static final State STARTED
public static final State INSTALL_FAILED
public static final State UPGRADING
public static final State UPGRADED
public static final State STOPPING
public static final State STOPPED
public static final State TERMINATING
public static State[] values()
for (State c : State.values()) System.out.println(c);
public static State valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic boolean canIssueCommands()
public Command getSupportedCommand()
public Command getSupportedCommand(boolean isInUpgradeMode)
public Command getSupportedCommand(boolean isInUpgradeMode, boolean stopInitiated)
public State getNextState(CommandResult result) throws IllegalArgumentException
IllegalArgumentExceptionpublic State getNextState(Command command) throws IllegalArgumentException
IllegalArgumentExceptionpublic boolean couldHaveIssued(Command command)
Copyright © 2014–2015 The Apache Software Foundation. All rights reserved.