org.squirrelframework.foundation.fsm.StateContext Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of squirrel-foundation Show documentation
Show all versions of squirrel-foundation Show documentation
foundation module of squirrel framework which provided event driven infrastructure and a finite state machine implementation.
package org.squirrelframework.foundation.fsm;
/**
* Then context of state machine when processing any events
*
* @author Henry.He
*
* @param state machine type
* @param state type
* @param event type
* @param context type
*/
public interface StateContext, S, E, C> {
/**
* @return current state machine object
*/
StateMachine getStateMachine();
/**
* @return state machine data
*/
StateMachineData getStateMachineData();
/**
* @return source state of state machine
*/
ImmutableState getSourceState();
/**
* @return external context object
*/
C getContext();
/**
* @return event
*/
E getEvent();
/**
* @return transition result
*/
TransitionResult getResult();
/**
* @return action executor
*/
ActionExecutor getExecutor();
}