java.lang.Object
org.apache.taglibs.rdc.scxml.SCXMLSemantics
- public class SCXMLSemantics
- extends java.lang.Object
This class encapsulates a particular SCXML semantics, that is a particular
semantic interpretation of Harel Statecharts. The possible semantic
interpretations are for example:
- STATEMATE
- RHAPSODY
- ROOMCharts
- UML 1.5
- UML 2.0
The purpose of this class is to separate the interpretation algorithm from
the SCXMLExecutor and make it therefore pluggable. Semantics agnostic utility
functions and common operators as defined in UML can be found in the
SCXMLHelper or attached directly to the SCXML model elements.
Specific semantics can be created by subclassing SCXMLSemantics, the current
implementation aligns mostly with W3C SCXML July 5 public draft (that is,
UML 1.5) however, certain aspects are taken from STATEMATE.
|
Method Summary |
void |
buildOnExitOnEntryLists(Step step,
ErrorReporter errRep)
|
void |
determineInitialStates(org.apache.taglibs.rdc.scxml.model.SCXML input,
java.util.Set states,
java.util.List entryList,
ErrorReporter errRep)
|
void |
determineTargetStates(java.util.Set states,
ErrorReporter errRep)
|
void |
enumerateReachableTransitions(org.apache.taglibs.rdc.scxml.model.SCXML stateMachine,
Step step,
ErrorReporter errRep)
|
boolean |
eventMatch(java.lang.String transEvent,
java.util.Set eventOccurrences)
Implements prefix match, that is, if, for example,
"mouse.click" is a member of eventOccurrences and a
transition is triggered by "mouse", the method returns true. |
void |
executeActionList(java.util.List actions,
java.util.Collection derivedEvents,
SCXMLExecutor exec,
ErrorReporter errRep)
|
void |
executeActions(Step step,
SCXMLExecutor exec,
ErrorReporter errRep)
Exectutes all OnExit/Transition/OnEntry transitional actions. |
void |
filterTransitionsSet(Step step,
Evaluator evaluator,
ErrorReporter errRep)
|
(package private) java.util.Comparator |
getTTComparator()
TransitionTargetComparator factory method |
org.apache.taglibs.rdc.scxml.model.SCXML |
normalizeStateMachine(org.apache.taglibs.rdc.scxml.model.SCXML input,
ErrorReporter errRep)
|
void |
seedTargetSet(Step step,
ErrorReporter errRep)
|
void |
updateHistoryStates(Step step,
ErrorReporter errRep)
Go over the exit list and update history information for relevant states. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
appLog
protected static org.apache.commons.logging.Log appLog
ttc
protected TransitionTargetComparator ttc
SCXMLSemantics
public SCXMLSemantics()
normalizeStateMachine
public org.apache.taglibs.rdc.scxml.model.SCXML normalizeStateMachine(org.apache.taglibs.rdc.scxml.model.SCXML input,
ErrorReporter errRep)
determineInitialStates
public void determineInitialStates(org.apache.taglibs.rdc.scxml.model.SCXML input,
java.util.Set states,
java.util.List entryList,
ErrorReporter errRep)
throws org.apache.taglibs.rdc.scxml.model.ModelException
executeActionList
public void executeActionList(java.util.List actions,
java.util.Collection derivedEvents,
SCXMLExecutor exec,
ErrorReporter errRep)
throws org.apache.taglibs.rdc.scxml.model.ModelException,
SCXMLExpressionException
executeActions
public void executeActions(Step step,
SCXMLExecutor exec,
ErrorReporter errRep)
throws org.apache.taglibs.rdc.scxml.model.ModelException
- Exectutes all OnExit/Transition/OnEntry transitional actions.
enumerateReachableTransitions
public void enumerateReachableTransitions(org.apache.taglibs.rdc.scxml.model.SCXML stateMachine,
Step step,
ErrorReporter errRep)
filterTransitionsSet
public void filterTransitionsSet(Step step,
Evaluator evaluator,
ErrorReporter errRep)
seedTargetSet
public void seedTargetSet(Step step,
ErrorReporter errRep)
determineTargetStates
public void determineTargetStates(java.util.Set states,
ErrorReporter errRep)
throws org.apache.taglibs.rdc.scxml.model.ModelException
buildOnExitOnEntryLists
public void buildOnExitOnEntryLists(Step step,
ErrorReporter errRep)
updateHistoryStates
public void updateHistoryStates(Step step,
ErrorReporter errRep)
- Go over the exit list and update history information for relevant states.
eventMatch
public boolean eventMatch(java.lang.String transEvent,
java.util.Set eventOccurrences)
- Implements prefix match, that is, if, for example,
"mouse.click" is a member of eventOccurrences and a
transition is triggered by "mouse", the method returns true.
getTTComparator
final java.util.Comparator getTTComparator()
- TransitionTargetComparator factory method