MINT-scxml 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,34 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AICommand < AIO
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AICommand do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- trans :defocused, :focus, :focused_H
18
- trans :defocused, :next, :focused_H, :focus_next
19
- trans :defocused, :prev, :focused_H, :focus_prev
20
- trans :defocused, :parent, :focused_H, :focus_parent
21
-
22
- superstate :focused do
23
- event :defocus, :defocused
24
-
25
- trans :deactivated, :activate, :activated
26
- trans :activated, :deactivate, :deactivated
27
- end
28
- end
29
- end
30
- end
31
- end
32
- end
33
- end
34
- end
@@ -1,7 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AIIN < AIO
6
- end
7
- end
@@ -1,41 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AIINContinous < AIIN
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AIINContinous do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- trans :defocused, :focus, :focused
18
- trans :defocused, :next, :focused, :focus_next
19
- trans :defocused, :prev, :focused, :focus_prev
20
- trans :defocused, :parent, :focused, :focus_parent
21
-
22
- superstate :focused do
23
- event :defocus, :defocused
24
-
25
- # TODO how to implement the sensitivity condition?
26
- trans :waiting, :decrease, :decreasing#, nil, (x1<x0-sensitivy)
27
- trans :waiting, :increase, :increasing#, nil, (x1>x0-sensitivy)
28
- trans :increasing, :decrease, :decreasing#, nil, (x1<x0-sensitivy)
29
- trans :decreasing, :increase, :increasing#, nil, (x1>x0-sensitivy)
30
-
31
- # TODO how to implement transitions without events
32
- #trans :decreasing, nil, :waiting, nil, (Dt>tmax)
33
- #trans :increasing, nil, :waiting, nil, (Dt>tmax)
34
- end
35
- end
36
- end
37
- end
38
- end
39
- end
40
- end
41
- end
@@ -1,46 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AIMultiChoice
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AIMultiChoice do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- parallel :p do
18
- statemachine :s1 do
19
- trans :listing, :drop, :dropped, :drop_all_dragging, In(:focused)
20
- trans :listing, :choose_all, :choosing
21
- trans :listing, :unchoose_all, :unchoosing
22
- # TODO how to implement transitions without events
23
- # trans :dropped, nil, :listing, :unfocus_self
24
- # trans :choosing, nil, :listing, :choose_all_childs
25
- # trans :unchoosing, nil, :listing, :unchoose_all_childs
26
- end
27
- statemachine :s2 do
28
- superstate :presentingAIC do
29
- event :suspend, :suspended
30
-
31
- trans :defocused, :focus, :focused
32
- trans :defocused, :next, :focused, :focus_next
33
- trans :defocused, :prev, :focused, :focus_prev
34
- trans :defocused, :parent, :focused, :focus_parent
35
- trans :defocused, :child, :focused, :focus_child
36
- trans :focused, :defocus, :defocused
37
- end
38
- end
39
- end
40
- end
41
- end
42
- end
43
- end
44
- end
45
- end
46
- end
@@ -1,46 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AIMultiChoiceElement
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AIMultiChoiceElement do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting_H
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- parallel :p do
18
- statemachine :s1 do
19
- superstate :selection do
20
- trans :unchosen, :choose, :chosen, nil, In(:focused)
21
- trans :chosen, :unchoose, :unchosen
22
- end
23
- end
24
- statemachine :s2 do
25
- superstate :presentingAIChoiceElement do
26
- event :suspend, :suspended
27
-
28
- trans :defocused, :focus, :focused
29
- trans :defocused, :next, :focused, :focus_next
30
- trans :defocused, :prev, :focused, :focus_prev
31
- trans :defocused, :parent, :focused, :focus_parent
32
- trans :focused, :defocus, :defocused
33
- #would the implementation of "if" be like this?
34
- trans :focused, :drag, :dragging, :self_choose, In(:unchosen)
35
- trans :focused, :drag, :dragging, nil, In(:chosen)
36
- trans :dragging, :drop, :defocused
37
- end
38
- end
39
- end
40
- end
41
- end
42
- end
43
- end
44
- end
45
- end
46
- end
@@ -1,41 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AIOUTContinous
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AIOUTContinous do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- trans :defocused, :focus, :focused
18
- trans :defocused, :next, :focused, :focus_next
19
- trans :defocused, :prev, :focused, :focus_prev
20
- trans :defocused, :parent, :focused, :focus_parent
21
-
22
- superstate :focused do
23
- event :defocus, :defocused
24
-
25
- trans :waiting, :progress, :progressing
26
- trans :waiting, :regress, :regressing
27
-
28
- superstate :moving do
29
- event :halt, :waiting
30
-
31
- trans :progressing, :regress, :regressing
32
- trans :regressing, :progress, :progressing
33
- end
34
- end
35
- end
36
- end
37
- end
38
- end
39
- end
40
- end
41
- end
@@ -1,42 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AISingleChoice
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AISingleChoice do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- parallel :p do
18
- statemachine :s1 do
19
- trans :listing, :drop, :dropped, :drop_all_dragging, In(:focused)
20
- # TODO how to implement transitions without events
21
- # trans :dropped, nil , :listing, :unfocus_self
22
- end
23
- statemachine :s2 do
24
- superstate :presentingAIC do
25
- event :suspend, :suspended
26
-
27
- trans :defocused, :focus, :focused
28
- trans :defocused, :next, :focused, :focus_next
29
- trans :defocused, :prev, :focused, :focus_prev
30
- trans :defocused, :parent, :focused, :focus_parent
31
- trans :defocused, :child, :focused, :focus_child
32
- trans :focused, :defocus, :defocused
33
- end
34
- end
35
- end
36
- end
37
- end
38
- end
39
- end
40
- end
41
- end
42
- end
@@ -1,45 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AISingleChoiceElement
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AISingleChoiceElement do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting_H
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- parallel :p do
18
- statemachine :s1 do
19
- superstate :selection do
20
- trans :unchosen, :choose, :chosen, :all_unchoose, In(:focused)
21
- trans :chosen, :unchoose, :unchosen
22
- end
23
- end
24
- statemachine :s2 do
25
- superstate :presentingAIChoiceElement do
26
- event :suspend, :suspended
27
-
28
- trans :defocused, :focus, :focused
29
- trans :defocused, :next, :focused, :focus_next
30
- trans :defocused, :prev, :focused, :focus_prev
31
- trans :defocused, :parent, :focused, :focus_parent
32
- trans :focused, :defocus, :defocused
33
- trans :focused, :drag, :dragging, :self_choose, In(:unchosen)
34
- trans :focused, :drag, :dragging, nil, In(:chosen)
35
- trans :dragging, :drop, :defocused
36
- end
37
- end
38
- end
39
- end
40
- end
41
- end
42
- end
43
- end
44
- end
45
- end
@@ -1,28 +0,0 @@
1
- require 'rubygems'
2
- require 'statemachine'
3
-
4
- module MINT
5
- class AIO
6
- def initialize_statemachine
7
- if @statemachine.blank?
8
- @statemachine = Statemachine.build do
9
- superstate :AIO do
10
- trans :initialized, :organize, :organized
11
- trans :organized, :present, :presenting
12
- trans :suspended, :organize, :organized
13
-
14
- superstate :presenting do
15
- event :suspend, :suspended
16
-
17
- trans :defocused, :focus, :focused
18
- trans :defocused, :next, :focused, :focus_next
19
- trans :defocused, :prev, :focused, :focus_prev
20
- trans :defocused, :parent, :focused, :focus_parent
21
- trans :focused, :defocus, :defocused
22
- end
23
- end
24
- end
25
- end
26
- end
27
- end
28
- end