| Modifier and Type | Field and Description |
|---|---|
protected State |
FSMContext._previousState
Stores which state a transition left.
|
protected State |
FSMContext._state
The current state.
|
| Modifier and Type | Field and Description |
|---|---|
protected Stack<State> |
FSMContext._stateStack
This stack is used to store the current state when a push
transition is taken.
|
| Modifier and Type | Method and Description |
|---|---|
State |
FSMContext.getPreviousState()
If this FSM is in transition, then returns the previous
state which the last transition left.
|
| Modifier and Type | Method and Description |
|---|---|
void |
FSMContext.pushState(State state)
Pushes the current state on top of the state stack and
sets the current state to
state. |
void |
FSMContext.setState(State state)
Sets the current state to the given value.
|
| Constructor and Description |
|---|
FSMContext(State initState)
Creates a finite state machine context for the given
initial state.
|
Copyright © 2020. All rights reserved.