SCXML

from Wikipedia, the free encyclopedia

S tate C hard XML (SCXML) is an XML standard of the W3C for a general description language for state transition diagrams . SCXML can describe complex state machines including sub-states, nested and parallel states.

The standard has been developed by the W3C since 2005 and received recommendation status on September 1, 2015. SCXML is based on CCXML and Harel Statecharts.

example

The following example illustrates the modeling of a stopwatch with SCXML.

Scxml-stopwatch.jpg

<?xml version="1.0" encoding="UTF-8"?>
<scxml xmlns="http://www.w3.org/2005/07/scxml" version="1.0" initial="ready">
    <state id="ready">
        <transition event="watch.start" target="running"/>
        <transition event="watch.reset" target="stopped"/>
    </state>
    <state id="running">
        <transition event="watch.split" target="paused"/>
        <transition event="watch.stop" target="stopped"/>
    </state>
    <state id="paused">
        <transition event="watch.unsplit" target="running"/>
        <transition event="watch.stop" target="stopped"/>
    </state>
    <state id="stopped">
    </state>
</scxml>

Individual evidence

  1. W3C Recommendation 1 September 2015 (English)
  2. Modeling Reactive Systems with Statecharts: The STATEMATE Approach (English)
  3. SCXML Recommendation (Overview)