1- #Automata - A finite state machine framework.
1+ # Automata - A finite state machine framework.
22
33Current state of automata is version 2.x.x, which is not backward compatible with 1.x.x.
44
5- ##Description
5+ ## Description
66
77Automata is a formal finite state machine (FDA) framework.
88It aims at offering a totally decoupled management of logic and data storage.
@@ -17,7 +17,7 @@ finite state machine framework like
1717* FDA Session as message chroreographer
1818* Asynchronous execution
1919
20- ##How to
20+ ## How to
2121
2222Automata works on browsers or Node and has no dependencies.
2323
@@ -53,7 +53,7 @@ declare module Automata {
5353}
5454```
5555
56- ##How it works
56+ ## How it works
5757
5858In Automata, FDA (finite deterministic automaton) are declaratively defined. It is contstrained to ` FSMDefinition `
5959object.
@@ -323,7 +323,7 @@ function( session, state, transition, msg );
323323
324324In any case, those functions will be automatically called if they exist in the logic object.
325325
326- ##Guards
326+ ## Guards
327327
328328Guards prevent a transition from being fired. In Automata there are two available guard points out of the box.
329329One on preTransitionFire and the other on postTransitionFire.
@@ -397,7 +397,7 @@ endif
397397 * AB_postGuard
398398
399399
400- ##Timed transitions
400+ ## Timed transitions
401401
402402Automata offers out of the box timed transitions by defining an ** onTimer** block in a FDA definition. For example:
403403
@@ -427,7 +427,7 @@ FDA session. The timer is handled automatically, and set/canceled on state enter
427427The timers are checked every 200 milliseconds by the unique instance of FSMContext object. Thus, if you need to have
428428less than 200ms timers, you may want to change TIMER_CHECK_RESOLUTION in the automata.js file.
429429
430- ##SubStates
430+ ## SubStates
431431
432432Automata allows to nest as much as needed substates. In fact, by defining a single FDA, the engine stacks two levels,
433433one for the FDA, and the other, initially for the FDA's initial state. To define different levels, you must
@@ -463,7 +463,7 @@ Then, the transition section will identify this FDA as a substate by its name, S
463463 stacked level, a FDA.Context object is created. A context object is just a holder for the current state for each
464464 nesting level.
465465
466- ##Transition from Substates
466+ ## Transition from Substates
467467
468468The way in which Automata manages state changes is made hierarchycally. That means, the engine will try to find a
469469suitable transition for a given incoming message regardless of its nesting level.
@@ -503,7 +503,7 @@ Additionally, this session will be finished since S3 is a final State (this nest
503503and so it is ROOT, which causes the session to be emptied.
504504
505505
506- ##FDA listeners
506+ ## FDA listeners
507507
508508Any FDA session activity can be monitored by adding a listener.
509509For example:
@@ -547,7 +547,7 @@ The obj parameter for each listener object function contains the following param
547547* ** postGuard** : FSM.TransitionGuardEvent
548548* ** customEvent** : FSM.CustomEvent
549549
550- ##Custom events
550+ ## Custom events
551551
552552The preferred way for sending custom events will be by calling:
553553``` javascript
@@ -561,9 +561,9 @@ This method will be notified on the method
561561customEvent : function ( ev : FSM .CustomEvent ) {
562562` ` `
563563
564- #Samples
564+ # Samples
565565
566- ##Sample 1 - Simple FDA
566+ ## Sample 1 - Simple FDA
567567
568568This sample shows how to define common FDA session callback points. Either on logic object, or by defining a callback.
569569In either case, **this** is defined to be the session's logic object.
@@ -658,7 +658,7 @@ session.start( function onStartProcessEnds(session) {
658658
659659` ` `
660660
661- ##Sample 2 - FDA with timed events
661+ ## Sample 2 - FDA with timed events
662662
663663This sample show how to define a timed transition. Note this example has no FDA Controller.
664664
0 commit comments