1 // This file is under GNU General Public License 3.0
7 template "protocol/fsm" document "{@name}.dot", "text"
9 digraph finite_state_machine {
11 node [shape = doublecircle];
12 `apply "state[@end='1']" mode=end`;
13 node [shape = circle];
15 `` apply "state" mode=do
19 template "state", mode=end > «@name»
20 template "state", mode=do apply "event", 0 with "state", "@name";
25 when "count(transition) > 0"
26 apply "transition|condition/transition", 0
27 with "state", "$state", with "event", "@name";
30 | «$state» -> «$state» [ label="«@name»" ];
34 template "transition" {
38 | «$state» -> «@target» [ label ="«$event»" ];