Package com.tangosol.util.fsm
Class Instruction.TransitionTo<S extends Enum<S>>
- java.lang.Object
 - 
- com.tangosol.util.fsm.Instruction.TransitionTo<S>
 
 
- 
- All Implemented Interfaces:
 Event<S>,Instruction
- Enclosing interface:
 - Instruction
 
public static final class Instruction.TransitionTo<S extends Enum<S>> extends Object implements Instruction, Event<S>
AnInstructionfor aFiniteStateMachinetoInstruction.TransitionToanother state. (immediately on the thread that created theInstruction). 
- 
- 
Nested Class Summary
- 
Nested classes/interfaces inherited from interface com.tangosol.util.fsm.Instruction
Instruction.ProcessEvent<S extends Enum<S>>, Instruction.TransitionTo<S extends Enum<S>> 
 - 
 
- 
Field Summary
- 
Fields inherited from interface com.tangosol.util.fsm.Instruction
NOTHING, STOP 
 - 
 
- 
Constructor Summary
Constructors Constructor Description TransitionTo(S desiredState)Constructs aInstruction.TransitionTo. 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SgetDesiredState(S currentState, ExecutionContext context)Determines the desired state of theFiniteStateMachinefor theEventgiven the current state of theFiniteStateMachine.StringtoString() 
 - 
 
- 
- 
Constructor Detail
- 
TransitionTo
public TransitionTo(S desiredState)
Constructs aInstruction.TransitionTo.- Parameters:
 desiredState- the desired state to which to transition
 
 - 
 
- 
Method Detail
- 
getDesiredState
public S getDesiredState(S currentState, ExecutionContext context)
Determines the desired state of theFiniteStateMachinefor theEventgiven the current state of theFiniteStateMachine.- Specified by:
 getDesiredStatein interfaceEvent<S extends Enum<S>>- Parameters:
 currentState- the current state of theFiniteStateMachinecontext- theExecutionContextfor theEvent- Returns:
 - the desired state of the 
FiniteStateMachineornullif no transition is required 
 
 - 
 
 -