| Modifier and Type | Method and Description |
|---|---|
S |
getState()
The state in which this FSM currently is.
|
boolean |
isStarted() |
boolean |
isTerminated()
The FSM is in its terminated state if it has reached the final
state.
|
static <S extends Enum<S>> |
of(Class<S> type) |
void |
onEvent(Object event)
Deliver an event to this
FSM. |
void |
reStartAndEnter(S state)
Re-start the FSM and enter the specified state.
|
void |
start()
|
void start()
start() on the FSM before it can be used.
This will cause the FSM to "transition" from a null state to its initial state.
Any enter actions associated with the initial state will naturally now be called.
Note: calling this method when the FSM is already started will silently
be ignored.boolean isStarted()
boolean isTerminated()
void reStartAndEnter(S state) throws IllegalArgumentException
state - IllegalArgumentException - in case the state is nullS getState()
static <S extends Enum<S>> ContextTypeBuildStep<S> of(Class<S> type)
Copyright © 2019. All rights reserved.