Package com.tangosol.util.fsm
Interface TransitionAction<S extends Enum<S>>
-
public interface TransitionAction<S extends Enum<S>>
ATransitionAction
encapsulates the actions to be performed as part of theTransition
from one state to another.- Since:
- Coherence 12.2.1
- Author:
- Brian Oliver
- See Also:
Transition
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
onTransition(String sName, S stateFrom, S stateTo, Event<S> event, ExecutionContext context)
Performs the necessary actions as part of aTransition
from one state to another, triggered by a specifiedEvent
.
-
-
-
Method Detail
-
onTransition
void onTransition(String sName, S stateFrom, S stateTo, Event<S> event, ExecutionContext context) throws RollbackTransitionException
Performs the necessary actions as part of aTransition
from one state to another, triggered by a specifiedEvent
.Note: After executing this method the
FiniteStateMachine
will automatically move to the state specified by theTransition
.- Parameters:
sName
- the name of the transitionstateFrom
- the state from which the transition is occurringstateTo
- the state to which the transition is occurringevent
- theEvent
that triggered theTransition
context
- theExecutionContext
for the action- Throws:
RollbackTransitionException
- if theTransition
should be aborted and theFiniteStateMachine
should be left in it's current state
-
-