To a certain extent. The execution of an SCXML state machine through an SCXMLExecutor instance may only be done,
as per the specification, sequentially.
Multiple threads may 'send' or 'register' new events on a state machine through its #addEvent methods, which
then will be processed sequentially by the SCXMLExecutor.
If such events are registered while the state machine is executing, these will processed automatically
before the state machine 'returns' in a stable state.
If such events are registered or added while the state machine is in a stable state, the SCXMLExecutor its
#triggerEvents method will have to be invoked for the state machine to proceed with processing these events.
The SCXMLExecutor methods themselves are not thread save, and thus it is the responsibility of the 'manager' of the
SCXMLExecutor, typically the thread creating and initializing the state machine to also execute the state machine
and check upon its state.
Other threads collaborating with the state machine however should refrain to only use the #addEvent methods, or
otherwise be (externally) coordinated such that only one thread at a time is triggering the execution of the state
machine.
[top]