public class StateMachineInitializer<S extends BalancerOperationState> extends Object
BalancerOperationState
for a #StateMachine
.
For example, some states may be dependent on previous ones in which case a #StateMachine
cannot be initialized with the dependent state but should rather start from the previous one.Modifier and Type | Class and Description |
---|---|
static class |
StateMachineInitializer.Builder<S extends BalancerOperationState>
A Builder for constructing a #
StateMachineInitializer with a set of #StateMachineInitializer.InitializationRule s added through the #Builder#with(InitializationRule) method. |
static class |
StateMachineInitializer.InitializationMode
A setting to configure what state to return when no state initialization is registered for a given state
|
static class |
StateMachineInitializer.InitializationRule<S extends BalancerOperationState>
A rule denoting what state a given state should be initialized to.
|
Modifier and Type | Method and Description |
---|---|
S |
defaultStartState()
Return the state at which the #
StateMachine should start at |
S |
init(S givenState)
Return the state at which the given #
givenState should be initialized to. |
public S defaultStartState()
StateMachine
should start at