]> rtime.felk.cvut.cz Git - boost-statechart-viewer.git/blob - www/index.mdwn
e1a07b17e6b8ca4f65d206785b5157f00d4746b6
[boost-statechart-viewer.git] / www / index.mdwn
1 [[!meta title="Boost Statechart Viewer"]]
2
3 Overview
4 ---------
5
6 Boost-statechart-viewer is a program for visualization of state
7 machines written in C++ with [boost][boost]/[statechart][statechart]
8 library. The program itself is written in C++ and uses [clang][clang]
9 from [LLVM][llvm] project for analyzing the source code. This program
10 is released under the GNU GPL license.
11
12 [boost]: http://www.boost.org/
13 [statechart]: http://www.boost.org/doc/libs/1_46_1/libs/statechart/doc/index.html
14 [clang]: http://clang.llvm.org/
15 [llvm]: http://llvm.org/
16
17 NEWS
18 -----
19 - 2013-04-05 The program is working with LLVM and Clang version 3.0 or higher
20 - 2012-07-11 We have got a new [mailing list][list].
21
22 Authors
23 --------
24
25 [list]: https://rtime.felk.cvut.cz/mailman/listinfo/boost-statechart-viewer
26
27 Petr Silhavik, Michal Sojka. You can contact us using a
28 [mailing list][list] at <boost-statechart-viewer@rtime.felk.cvut.cz>.
29
30 Status
31 -------
32
33 - The program can found states and transitions in the source code.
34 - The program understands all options and flags as the compilers (gcc, clang, ...). The syntax analysis is done by compiler clang.
35 - State machines can be defined in more than one file.
36 - Program provides diagnostics of state machines eg. event usage, missing typedefs for reactions.
37
38 For compiling and correctly working program it is necessary to have
39 LLVM and clang version 3.0 or higher.
40
41
42 Usage
43 ------
44
45 The program is plugin for compiler clang. The produced output file has the same name as the input file with source code.
46 It is also possible to use script that also produces the state diagram in format pdf. It can be also found in repository.
47
48 ####Example of command line invocation: 
49
50     clang++ -Xclang -load -Xclang visualizer.so -Xclang -plugin -Xclang visualize-statechart -c file.cpp
51
52 The output file can be transformed into the picture using classical
53 [dot][graphviz] commands (e.g. `dot -Tpng graph.dot -o graph.png`) . The initial
54 state is double outlined. Each transition has a label with the name of
55 the triggering event.
56
57 [graphviz]: http://www.graphviz.org/
58
59 Download:
60 ---------
61
62 Boost statechart viewer can be downloaded from GIT repository.
63
64     git clone git://rtime.felk.cvut.cz/boost-statechart-viewer.git
65
66 You can also browse the [repository online][1].
67
68
69 Gallery
70 -------
71
72 ### Small
73 [[small.png]]  
74 [[Source code|test.cpp]]
75
76 ### StopWatch
77 [[stopWatch.png]]  
78 [[Source code|StopWatch.cpp]]
79
80 ### Camera
81  - Camera example from boost statechart library
82  - State Storing is red because it has no typedef for reactions and it can be error produced by programmer
83 [[camera.png]]  
84 [[Source code|camera.tar.gz]]
85
86 ### Big
87 [[big.png]]  
88 [[Source code|big_sm.tar.gz]]
89
90   [1]: http://rtime.felk.cvut.cz/gitweb/boost-statechart-viewer.git