|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SMStateIF
Defines contract for manipulating state behavior definitions and performing state transitions
Method Summary | |
---|---|
void |
_entryTransition()
Performs the state entry transisions, it should not be used or overloaded by user SM. |
void |
_exitTransition()
Performs the state exit transisions, it should not be used or overloaded by user SM. |
void |
addEntryTransition(EntryStateTransition trans)
Adds entry transition to be perfomed every time the state becomes current |
void |
addExitTransition(ExitStateTransition trans)
Adds exit transition to be perfomed every time other state replaces the state as current |
void |
addTransition(java.lang.Class triggerEventCls,
StateTransition transition)
Adds transition to the state. |
void |
addTransition(java.lang.Class triggerEventCls,
StateTransition transition,
java.lang.Enum newState)
Adds transition to the state. |
void |
copy(SMStateIF state)
Copies state data such as transitions from the parameter state to the state |
void |
entryTransition()
Deprecated. replaced by addEntryTransition |
void |
exitTransition()
Deprecated. replaced by addExitTransition |
java.util.HashSet<EntryStateTransition> |
getEntryTransitions()
Returns the collection of the defined entry transitions |
java.util.HashMap<java.lang.Class,SMState.TransitionSegment> |
getEventTransitions()
Returns collection of the transistions defined in the state |
java.util.HashSet<ExitStateTransition> |
getExitTransitions()
Returns the collection of the defined exit transitions |
StateTransition |
getLastPerformedTrans()
Returns the last transition performed by the state |
java.lang.Enum |
getStateID()
Returns the Enum indetifying the state |
java.lang.String |
getStateName()
Returns state name |
void |
removeEntryTransition(EntryStateTransition trans)
Removed entry transition |
java.lang.Enum |
stateHandleEvent(SMEvent event)
Performs transition identified by the event class. |
Method Detail |
---|
java.lang.String getStateName()
void addTransition(java.lang.Class triggerEventCls, StateTransition transition)
triggerEventCls
- the class of the event that will trigger the transitionstransition
- the transition object to be addedvoid addTransition(java.lang.Class triggerEventCls, StateTransition transition, java.lang.Enum newState)
triggerEventCls
- the class of the event that will trigger the transitionstransition
- the transition object to be addednewState
- Enum identifying the new state after performing the transitionjava.lang.Enum stateHandleEvent(SMEvent event) throws SMStateCanNotHandleEvent
event
- the event to be handled
SMStateCanNotHandleEvent
- thrown if the state does not have
a transition for the event classvoid _exitTransition()
void _entryTransition()
void entryTransition()
addEntryTransition
void exitTransition()
addExitTransition
java.lang.Enum getStateID()
void addEntryTransition(EntryStateTransition trans)
trans
- the transition to addvoid removeEntryTransition(EntryStateTransition trans)
trans
- the transition to removevoid addExitTransition(ExitStateTransition trans)
trans
- the transition to addvoid copy(SMStateIF state) throws SMStateCanNotCopy
state
- the state to copy data from
SMStateCanNotCopy
StateTransition getLastPerformedTrans()
java.util.HashMap<java.lang.Class,SMState.TransitionSegment> getEventTransitions()
java.util.HashSet<EntryStateTransition> getEntryTransitions()
java.util.HashSet<ExitStateTransition> getExitTransitions()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |