|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.evelopers.unimod.runtime.AbstractEventProcessor com.evelopers.unimod.runtime.interpretation.InterpretationEventProcessor
Abstract low-level event processor implementation. Concrete implementation responsible for realization of state machine runtime sematic such as selection of transition for event, processing input and output actions and so on. Pattern used: Template Method
Constructor Summary | |
InterpretationEventProcessor(Model model)
Creates processor |
Method Summary | |
ModelStructure |
getModelStructure()
Returns the structure of the model. |
protected StateMachineConfig |
process(Event event,
StateMachineContext context,
StateMachinePath path,
StateMachineConfig config)
Processes given event using state machine instance defined by the given config. |
protected StateMachineConfig |
transiteToStableState(StateMachineContext context,
StateMachinePath path,
StateMachineConfig config)
Transites from initial state config to stable
state. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public InterpretationEventProcessor(Model model)
model
- automata modelMethod Detail |
public ModelStructure getModelStructure()
AbstractEventProcessor
getModelStructure
in interface EventProcessor
getModelStructure
in class AbstractEventProcessor
protected StateMachineConfig transiteToStableState(StateMachineContext context, StateMachinePath path, StateMachineConfig config) throws com.evelopers.common.exception.SystemException
AbstractEventProcessor
config
to stable
state. This method should:
AbstractEventProcessor.fireCompositeTargetState(com.evelopers.unimod.runtime.context.StateMachineContext, com.evelopers.unimod.runtime.StateMachinePath, java.lang.String)
AbstractEventProcessor.fireComeToState(com.evelopers.unimod.runtime.context.StateMachineContext, com.evelopers.unimod.runtime.StateMachinePath, java.lang.String)
for new initial stateAbstractEventProcessor.transiteToStableState(com.evelopers.unimod.runtime.context.StateMachineContext, com.evelopers.unimod.runtime.StateMachinePath, com.evelopers.unimod.runtime.StateMachineConfig)
with new initial state
transiteToStableState
in class AbstractEventProcessor
context
- state machine context of the eventpath
- path that defines the state machine instanceconfig
- initial state to transite from
com.evelopers.common.exception.SystemException
protected StateMachineConfig process(Event event, StateMachineContext context, StateMachinePath path, StateMachineConfig config) throws com.evelopers.common.exception.SystemException
AbstractEventProcessor
switch
-operator.
Implementations of this method should fire event processing events
during execution.
process
in class AbstractEventProcessor
event
- triggered event to processcontext
- state machine context of the eventpath
- path to state machine instanceconfig
- state machine config that defines the
state machine instance
com.evelopers.common.exception.SystemException
- if some input or output action throws
an exception. This exception will be handled by added ExceptionHandlersAbstractEventProcessor.addExceptionHandler(ExceptionHandler)
,
AbstractEventProcessor.removeExceptionHandler(ExceptionHandler)
,
AbstractEventProcessor.addEventProcessorListener(EventProcessorListener)
,
AbstractEventProcessor.removeEventProcessorListener(EventProcessorListener)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |