T - type of State MachineS - type of StateE - type of EventC - type of Contextpublic interface ImmutableState<T extends StateMachine<T,S,E,C>,S,E,C> extends Visitable, SquirrelComponent
State The basic unit that composes a state machine. A state machine can be in one state at any particular time.
Entry Action An activity executed when entering the state
Entry Action An activity executed when entering the state
Final State A state which represents the completion of the state machine.
| Modifier and Type | Method and Description |
|---|---|
ImmutableState<T,S,E,C> |
enterByHistory(StateContext<T,S,E,C> stateContext)
Enters this state by its history depending on its
HistoryType. |
ImmutableState<T,S,E,C> |
enterDeep(StateContext<T,S,E,C> stateContext)
Enters this state is deep mode: mode if there is one.
|
ImmutableState<T,S,E,C> |
enterShallow(StateContext<T,S,E,C> stateContext)
Enters this state is shallow mode: The entry action is executed and the
initial state is entered in shallow mode if there is one.
|
void |
entry(StateContext<T,S,E,C> stateContext)
Entry state with state context
|
void |
exit(StateContext<T,S,E,C> stateContext)
Exit state with state context
|
Set<E> |
getAcceptableEvents() |
List<ImmutableTransition<T,S,E,C>> |
getAllTransitions() |
List<ImmutableState<T,S,E,C>> |
getChildStates() |
StateCompositeType |
getCompositeType() |
List<Action<T,S,E,C>> |
getEntryActions() |
List<Action<T,S,E,C>> |
getExitActions() |
HistoryType |
getHistoryType() |
ImmutableState<T,S,E,C> |
getInitialState() |
int |
getLevel() |
ImmutableState<T,S,E,C> |
getParentState() |
String |
getPath() |
S |
getStateId() |
ImmutableState<T,S,E,C> |
getThis() |
List<ImmutableTransition<T,S,E,C>> |
getTransitions(E event) |
boolean |
hasChildStates() |
void |
internalFire(StateContext<T,S,E,C> stateContext)
Notify transitions when receiving event.
|
boolean |
isChildStateOf(ImmutableState<T,S,E,C> input) |
boolean |
isFinalState() |
boolean |
isParallelState() |
boolean |
isRegion() |
boolean |
isRootState() |
void |
verify()
Verify state correctness
|
S getStateId()
boolean isRootState()
List<Action<T,S,E,C>> getEntryActions()
List<Action<T,S,E,C>> getExitActions()
List<ImmutableTransition<T,S,E,C>> getAllTransitions()
List<ImmutableTransition<T,S,E,C>> getTransitions(E event)
event - void entry(StateContext<T,S,E,C> stateContext)
stateContext - ImmutableState<T,S,E,C> enterByHistory(StateContext<T,S,E,C> stateContext)
HistoryType. The Entry method has to be called
already.stateContext - the state context.HistoryType)ImmutableState<T,S,E,C> enterDeep(StateContext<T,S,E,C> stateContext)
stateContext - the event context.ImmutableState<T,S,E,C> enterShallow(StateContext<T,S,E,C> stateContext)
stateContext - void exit(StateContext<T,S,E,C> stateContext)
stateContext - ImmutableState<T,S,E,C> getParentState()
boolean hasChildStates()
ImmutableState<T,S,E,C> getInitialState()
void internalFire(StateContext<T,S,E,C> stateContext)
stateContext - boolean isFinalState()
int getLevel()
HistoryType getHistoryType()
StateCompositeType getCompositeType()
boolean isParallelState()
boolean isRegion()
void verify()
ImmutableState<T,S,E,C> getThis()
String getPath()
boolean isChildStateOf(ImmutableState<T,S,E,C> input)
Copyright © 2013–2016. All rights reserved.