Requirements

Maven, Ant and Java

Installation

Follow these instructions to check scxml-js out of SVN.

To use SCXMLcgf/js, you must first download the dependencies and preprocess the XSLT stylesheets. Run:

mvn generate-sources

Running the Compiler

./run.sh [options] file1 file2 ...

A summary of available options are as follows:

- backend	Statechart implementation technique. Currently one of {switch | table | state}
- noForEach	Assume that the target environment does not have an Array.forEach method
- noIndexOf	Assume that the target environment does not have an Array.indexOf method
- noMap		Assume that the target environment does not have an Array.map method
- ie		The equivalent of -noForEach -noIndexOf -noMap
- beautify	Will run generated code through a beautifier.
- log		Will enable logging in generated code.
- verbose	Will enable verbose logging in the compiler.

For example, you might run the following:

./run.sh --backend state --beautify --ie test/kitchen_sink/KitchenSink.xml > KitchenSinkIE.js

Using scxml-js

This paper provides an overview of the different ways in which scxml-js may be used.

The demos also provide full examples.