HaxeUmlGen generates class diagrams dynamically for a haXe project. HaxeUmlGen can run in two modes. It can draw diagram images, or it can generate XMI projects which can be imported into UML tools. To generate images, graphviz must be installed and the binary must be added to the path. Graphviz is a free program that can be found at http://www.graphviz.org.
HaxeUmlGen uses the xml file created when the -xml flag is passed in to the haxe compiler. It can be run directly from haxelib.
haxelib run HaxeUmlGen MODE XMLFILE
where MODE is "dot" to generate images or "xmi" to generate an xmi project XMLFILE is the file that the haxe compiler created
For example, to generate diagram images of myproject, compile with
haxe -neko myproject.n -xml myproject.xml MyProject.hx
then generate diagrams with
haxelib run haxeumlgen dot myproject.xml
That will create a files called [packagename].png for each package in the same directory as myproject.xml
An XMI project can be generated with
haxelib run haxeumlgen xmi myproject.xml
That will create a file called myproject-xmi.xml in the same directory as myproject.xml
The output directory can be changed with the --outdir command line parameter. Foreground and background colors for the images can be changed with -f COLOR and -b COLOR, respectively. COLOR should be a six character hex code, like color specifications for html. Don't quote colors or prefix with a sharp (#). All command line options can be listed with
neko haxeumlgen --help
ChxDoc is a source documentation tool written by Russell Weir. HaxeUmlGen can be integrated with chxdoc by following the instructions found in the chxdoc directory.