cpee 1.3.181 → 1.3.183
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/cockpit/css/ui.css +19 -60
- data/cockpit/css/wfadaptor.css +11 -0
- data/cockpit/index.html +45 -71
- data/cockpit/js/details.js +50 -139
- data/cockpit/js/instance.js +133 -185
- data/cockpit/js/parameters.js +57 -55
- data/cockpit/js/ui.js +4 -29
- data/cockpit/js/wfadaptor.js +190 -108
- data/cockpit/rngs/attributes.rng +8 -0
- data/cockpit/rngs/dataelements.rng +8 -0
- data/cockpit/rngs/endpoints.rng +8 -0
- data/cockpit/testsets/Concurrent.xml +6 -6
- data/cockpit/testsets/Coopis Testset.xml +12 -12
- data/cockpit/testsets/ICSOC Testset.xml +27 -27
- data/cockpit/testsets/Infinity.xml +4 -4
- data/cockpit/testsets/Linear.xml +10 -10
- data/cockpit/testsets/Mangler 1.xml +20 -20
- data/cockpit/testsets/Mangler 2.xml +18 -18
- data/cockpit/testsets/Promise.xml +258 -0
- data/cockpit/testsets/SOPROMO Test Sonification.xml +11 -11
- data/cockpit/testsets/Syncing P34 1.xml +12 -12
- data/cockpit/testsets/Syncing P34 2.xml +12 -12
- data/cockpit/testsets/Syncing P34 3.xml +12 -12
- data/cockpit/testsets/Syncing P34.xml +12 -12
- data/cockpit/testsets/TEST - Bad Loop.xml +39 -39
- data/cockpit/testsets/Update.xml +1 -1
- data/cockpit/testsets/Worklist Parallel.xml +8 -8
- data/cockpit/testsets/Worklist Test CPEE.xml +2 -2
- data/cockpit/testsets/Worklist Test.xml +2 -2
- data/cockpit/testsets/testsets.xml +2 -0
- data/cockpit/themes/adventure/rngs/alternative.rng +5 -0
- data/cockpit/themes/adventure/rngs/call.rng +29 -0
- data/cockpit/{rngtest2.rng → themes/adventure/rngs/callmanipulate.rng} +9 -9
- data/cockpit/themes/adventure/rngs/choose.rng +8 -0
- data/cockpit/themes/adventure/rngs/critical.rng +5 -0
- data/cockpit/themes/adventure/rngs/escape.rng +1 -0
- data/cockpit/themes/adventure/rngs/finalize.rng +6 -0
- data/cockpit/themes/adventure/rngs/group.rng +3 -0
- data/cockpit/themes/adventure/rngs/loop.rng +11 -0
- data/cockpit/themes/adventure/rngs/manipulate.rng +6 -0
- data/cockpit/themes/adventure/rngs/otherwise.rng +1 -0
- data/cockpit/themes/adventure/rngs/parallel.rng +5 -0
- data/cockpit/themes/adventure/rngs/parallel_branch.rng +8 -0
- data/cockpit/themes/adventure/rngs/update.rng +6 -0
- data/cockpit/themes/adventure/symbols/alternative.svg +4 -0
- data/cockpit/themes/adventure/symbols/call.svg +4 -0
- data/cockpit/themes/adventure/symbols/callmanipulate.svg +6 -0
- data/cockpit/themes/adventure/symbols/choose.svg +5 -0
- data/cockpit/themes/adventure/symbols/choose_exclusive.svg +5 -0
- data/cockpit/themes/adventure/symbols/choose_inclusive.svg +4 -0
- data/cockpit/themes/adventure/symbols/critical.svg +4 -0
- data/cockpit/themes/adventure/symbols/escape.svg +5 -0
- data/cockpit/themes/adventure/symbols/loop.svg +5 -0
- data/cockpit/themes/adventure/symbols/manipulate.svg +4 -0
- data/cockpit/themes/adventure/symbols/otherwise.svg +4 -0
- data/cockpit/themes/adventure/symbols/parallel.svg +5 -0
- data/cockpit/themes/adventure/symbols/parallel_branch.svg +4 -0
- data/cockpit/themes/adventure/symbols/scripts.svg +4 -0
- data/cockpit/themes/adventure/symbols/start.svg +3 -0
- data/cockpit/themes/adventure/theme.js +729 -0
- data/cockpit/themes/default/rngs/alternative.rng +5 -0
- data/cockpit/themes/default/rngs/call.rng +29 -0
- data/cockpit/themes/default/rngs/callmanipulate.rng +41 -0
- data/cockpit/themes/default/rngs/choose.rng +8 -0
- data/cockpit/themes/default/rngs/critical.rng +5 -0
- data/cockpit/themes/default/rngs/escape.rng +1 -0
- data/cockpit/themes/default/rngs/finalize.rng +6 -0
- data/cockpit/themes/default/rngs/group.rng +3 -0
- data/cockpit/themes/default/rngs/loop.rng +11 -0
- data/cockpit/themes/default/rngs/manipulate.rng +6 -0
- data/cockpit/themes/default/rngs/otherwise.rng +1 -0
- data/cockpit/themes/default/rngs/parallel.rng +5 -0
- data/cockpit/themes/default/rngs/parallel_branch.rng +8 -0
- data/cockpit/themes/default/rngs/update.rng +6 -0
- data/cockpit/themes/default/symbols/alternative.svg +4 -0
- data/cockpit/themes/default/symbols/call.svg +4 -0
- data/cockpit/themes/default/symbols/callmanipulate.svg +6 -0
- data/cockpit/themes/default/symbols/choose.svg +5 -0
- data/cockpit/themes/default/symbols/choose_exclusive.svg +5 -0
- data/cockpit/themes/default/symbols/choose_inclusive.svg +4 -0
- data/cockpit/themes/default/symbols/critical.svg +4 -0
- data/cockpit/themes/default/symbols/escape.svg +5 -0
- data/cockpit/themes/default/symbols/loop.svg +5 -0
- data/cockpit/themes/default/symbols/manipulate.svg +4 -0
- data/cockpit/themes/default/symbols/otherwise.svg +4 -0
- data/cockpit/themes/default/symbols/parallel.svg +5 -0
- data/cockpit/themes/default/symbols/parallel_branch.svg +4 -0
- data/cockpit/themes/default/symbols/scripts.svg +4 -0
- data/cockpit/themes/default/symbols/start.svg +3 -0
- data/cockpit/themes/default/theme.js +729 -0
- data/cockpit/themes/lego/rngs/alternative.rng +5 -0
- data/cockpit/themes/lego/rngs/call.rng +41 -0
- data/cockpit/themes/lego/rngs/choose.rng +8 -0
- data/cockpit/themes/lego/rngs/critical.rng +5 -0
- data/cockpit/themes/lego/rngs/loop.rng +11 -0
- data/cockpit/themes/lego/rngs/manipulate.rng +6 -0
- data/cockpit/themes/lego/rngs/parallel.rng +5 -0
- data/cockpit/themes/lego/rngs/parallel_branch.rng +8 -0
- data/cockpit/themes/lego/symbols/alternative.svg +4 -0
- data/cockpit/themes/lego/symbols/call.svg +4 -0
- data/cockpit/themes/lego/symbols/callmanipulate.svg +6 -0
- data/cockpit/themes/lego/symbols/callori.svg +4 -0
- data/cockpit/themes/lego/symbols/choose.svg +4 -0
- data/cockpit/themes/lego/symbols/choose_exclusive.svg +5 -0
- data/cockpit/themes/lego/symbols/choose_inclusive.svg +4 -0
- data/cockpit/themes/lego/symbols/critical.svg +4 -0
- data/cockpit/themes/lego/symbols/escape.svg +5 -0
- data/cockpit/themes/lego/symbols/lego.svg +72 -0
- data/cockpit/themes/lego/symbols/loop.svg +5 -0
- data/cockpit/themes/lego/symbols/manipulate.svg +4 -0
- data/cockpit/themes/lego/symbols/otherwise.svg +4 -0
- data/cockpit/themes/lego/symbols/parallel.svg +6 -0
- data/cockpit/themes/lego/symbols/parallel_branch.svg +4 -0
- data/cockpit/themes/lego/symbols/scripts.svg +4 -0
- data/cockpit/themes/lego/symbols/start.svg +3 -0
- data/cockpit/themes/lego/theme.js +742 -0
- data/cockpit/themes/promise/rngs/alternative.rng +5 -0
- data/cockpit/themes/promise/rngs/call.rng +41 -0
- data/cockpit/themes/promise/rngs/choose.rng +8 -0
- data/cockpit/themes/promise/rngs/critical.rng +5 -0
- data/cockpit/themes/promise/rngs/loop.rng +11 -0
- data/cockpit/themes/promise/rngs/manipulate.rng +6 -0
- data/cockpit/themes/promise/rngs/parallel.rng +5 -0
- data/cockpit/themes/promise/rngs/parallel_branch.rng +8 -0
- data/cockpit/themes/promise/symbols/alternative.svg +4 -0
- data/cockpit/themes/promise/symbols/call.svg +4 -0
- data/cockpit/themes/promise/symbols/callmanipulate.svg +6 -0
- data/cockpit/themes/promise/symbols/choose.svg +4 -0
- data/cockpit/themes/promise/symbols/choose_exclusive.svg +5 -0
- data/cockpit/themes/promise/symbols/choose_inclusive.svg +4 -0
- data/cockpit/themes/promise/symbols/critical.svg +4 -0
- data/cockpit/themes/promise/symbols/escape.svg +5 -0
- data/cockpit/themes/promise/symbols/loop.svg +5 -0
- data/cockpit/themes/promise/symbols/manipulate.svg +4 -0
- data/cockpit/themes/promise/symbols/otherwise.svg +4 -0
- data/cockpit/themes/promise/symbols/parallel.svg +6 -0
- data/cockpit/themes/promise/symbols/parallel_branch.svg +4 -0
- data/cockpit/themes/promise/symbols/preminder.svg +6 -0
- data/cockpit/themes/promise/symbols/scripts.svg +4 -0
- data/cockpit/themes/promise/symbols/start.svg +3 -0
- data/cockpit/themes/promise/theme.js +742 -0
- data/cpee.gemspec +2 -2
- data/lib/cpee/implementation.rb +15 -15
- data/server/handlerwrappers/default.rb +19 -19
- data/server/handlerwrappers/log.rb +264 -0
- data/server/instances/10/properties.xml +148 -0
- data/server/instances/11/properties.xml +149 -0
- data/server/instances/12/properties.xml +149 -0
- data/server/instances/13/properties.xml +149 -0
- data/server/instances/14/properties.xml +111 -0
- data/server/instances/15/properties.xml +113 -0
- data/server/instances/16/properties.xml +113 -0
- data/server/instances/17/properties.xml +149 -0
- data/server/instances/18/properties.xml +149 -0
- data/server/instances/19/properties.xml +114 -0
- data/server/instances/2/properties.xml +1 -1
- data/server/instances/20/properties.xml +113 -0
- data/server/instances/21/notifications/0851248d60c898cadd743d0dd5b6d273/consumer-secret +1 -0
- data/server/instances/21/notifications/0851248d60c898cadd743d0dd5b6d273/producer-secret +1 -0
- data/server/instances/21/notifications/0851248d60c898cadd743d0dd5b6d273/subscription.xml +6 -0
- data/server/instances/21/notifications/b7bac3f3010d433ce5d8f29338a06f9a/consumer-secret +1 -0
- data/server/instances/21/notifications/b7bac3f3010d433ce5d8f29338a06f9a/producer-secret +1 -0
- data/server/instances/21/notifications/b7bac3f3010d433ce5d8f29338a06f9a/subscription.xml +23 -0
- data/server/instances/21/properties.xml +149 -0
- data/server/instances/22/properties.xml +113 -0
- data/server/instances/23/properties.xml +88 -0
- data/server/instances/24/properties.xml +168 -0
- data/server/instances/25/properties.xml +149 -0
- data/server/instances/26/properties.xml +113 -0
- data/server/instances/27/properties.xml +141 -0
- data/server/instances/3/properties.xml +46 -0
- data/server/instances/4/properties.xml +148 -0
- data/server/instances/5/properties.xml +148 -0
- data/server/instances/6/properties.xml +148 -0
- data/server/instances/7/properties.xml +148 -0
- data/server/instances/8/properties.xml +148 -0
- data/server/instances/9/properties.xml +46 -0
- data/server/resources/properties.init +2 -1
- data/server/resources/transformation_dslx.xsl +12 -12
- data/server/server.pid +1 -0
- data/server/server.rb +2 -0
- metadata +152 -12
- data/cockpit/js/wfadaptor.cpee.js +0 -936
- data/cockpit/rngtest1.html +0 -53
- data/cockpit/rngtest1.rng +0 -38
- data/cockpit/rngtest1.xml +0 -16
- data/cockpit/rngtest2.html +0 -53
- data/cockpit/rngtest2.xml +0 -11
- data/cockpit/test.html +0 -46
@@ -0,0 +1,113 @@
|
|
1
|
+
<properties xmlns="http://riddl.org/ns/common-patterns/properties/1.0">
|
2
|
+
<attributes>
|
3
|
+
<info>Enter info here</info>
|
4
|
+
<modeltype>CPEE</modeltype>
|
5
|
+
<theme>default</theme>
|
6
|
+
</attributes>
|
7
|
+
<state>ready</state>
|
8
|
+
<handlerwrapper>DefaultHandlerWrapper</handlerwrapper>
|
9
|
+
<positions>
|
10
|
+
<a1>after</a1>
|
11
|
+
</positions>
|
12
|
+
<dataelements>
|
13
|
+
<x/>
|
14
|
+
</dataelements>
|
15
|
+
<endpoints>
|
16
|
+
<timeout>http://gruppe.wst.univie.ac.at/~mangler/services/timeout.php</timeout>
|
17
|
+
</endpoints>
|
18
|
+
<dsl>call :a1, :timeout, parameters: { :method => :post, :arguments => {:timeout => 2} }, finalize: <<-END
|
19
|
+
data.x += "a1,"
|
20
|
+
END
|
21
|
+
call :a2, :timeout, parameters: { :method => :post, :arguments => {:timeout => 4} }, finalize: <<-END
|
22
|
+
data.x += "a2,"
|
23
|
+
END
|
24
|
+
call :a3, :timeout, parameters: { :method => :post, :arguments => {:timeout => 4} }, finalize: <<-END
|
25
|
+
data.x += "a3,"
|
26
|
+
END
|
27
|
+
</dsl>
|
28
|
+
<dslx>
|
29
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
30
|
+
<!--{{{-->
|
31
|
+
<call id="a1" endpoint="timeout">
|
32
|
+
<parameters>
|
33
|
+
<!--{{{-->
|
34
|
+
<method>:post</method>
|
35
|
+
<arguments>
|
36
|
+
<timeout>2</timeout>
|
37
|
+
</arguments>
|
38
|
+
</parameters>
|
39
|
+
<!--}}}-->
|
40
|
+
<finalize output="result"> data.x += "a1,"</finalize>
|
41
|
+
</call>
|
42
|
+
<call id="a2" endpoint="timeout">
|
43
|
+
<parameters>
|
44
|
+
<!--{{{-->
|
45
|
+
<method>:post</method>
|
46
|
+
<arguments>
|
47
|
+
<timeout>4</timeout>
|
48
|
+
</arguments>
|
49
|
+
</parameters>
|
50
|
+
<!--}}}-->
|
51
|
+
<finalize output="result"> data.x += "a2,"</finalize>
|
52
|
+
</call>
|
53
|
+
<call id="a3" endpoint="timeout">
|
54
|
+
<parameters>
|
55
|
+
<!--{{{-->
|
56
|
+
<method>:post</method>
|
57
|
+
<arguments>
|
58
|
+
<timeout>4</timeout>
|
59
|
+
</arguments>
|
60
|
+
</parameters>
|
61
|
+
<!--}}}-->
|
62
|
+
<finalize output="result"> data.x += "a3,"</finalize>
|
63
|
+
</call>
|
64
|
+
</description>
|
65
|
+
</dslx>
|
66
|
+
<status>
|
67
|
+
<id>0</id>
|
68
|
+
<message>undefined</message>
|
69
|
+
</status>
|
70
|
+
<description>
|
71
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
72
|
+
<!--{{{-->
|
73
|
+
<call id="a1" endpoint="timeout">
|
74
|
+
<parameters>
|
75
|
+
<!--{{{-->
|
76
|
+
<method>:post</method>
|
77
|
+
<arguments>
|
78
|
+
<timeout>2</timeout>
|
79
|
+
</arguments>
|
80
|
+
</parameters>
|
81
|
+
<!--}}}-->
|
82
|
+
<finalize output="result"> data.x += "a1,"</finalize>
|
83
|
+
</call>
|
84
|
+
<call id="a2" endpoint="timeout">
|
85
|
+
<parameters>
|
86
|
+
<!--{{{-->
|
87
|
+
<method>:post</method>
|
88
|
+
<arguments>
|
89
|
+
<timeout>4</timeout>
|
90
|
+
</arguments>
|
91
|
+
</parameters>
|
92
|
+
<!--}}}-->
|
93
|
+
<finalize output="result"> data.x += "a2,"</finalize>
|
94
|
+
</call>
|
95
|
+
<call id="a3" endpoint="timeout">
|
96
|
+
<parameters>
|
97
|
+
<!--{{{-->
|
98
|
+
<method>:post</method>
|
99
|
+
<arguments>
|
100
|
+
<timeout>4</timeout>
|
101
|
+
</arguments>
|
102
|
+
</parameters>
|
103
|
+
<!--}}}-->
|
104
|
+
<finalize output="result"> data.x += "a3,"</finalize>
|
105
|
+
</call>
|
106
|
+
</description>
|
107
|
+
</description>
|
108
|
+
<transformation>
|
109
|
+
<description type="copy"/>
|
110
|
+
<dataelements type="rest"/>
|
111
|
+
<endpoints type="rest"/>
|
112
|
+
</transformation>
|
113
|
+
</properties>
|
@@ -0,0 +1,88 @@
|
|
1
|
+
<properties xmlns="http://riddl.org/ns/common-patterns/properties/1.0">
|
2
|
+
<attributes>
|
3
|
+
<info>Enter info here</info>
|
4
|
+
<modeltype>CPEE</modeltype>
|
5
|
+
<theme>default</theme>
|
6
|
+
</attributes>
|
7
|
+
<state>ready</state>
|
8
|
+
<handlerwrapper>DefaultHandlerWrapper</handlerwrapper>
|
9
|
+
<positions>
|
10
|
+
<a1>after</a1>
|
11
|
+
</positions>
|
12
|
+
<dataelements>
|
13
|
+
<x/>
|
14
|
+
</dataelements>
|
15
|
+
<endpoints>
|
16
|
+
<timeout>http://gruppe.wst.univie.ac.at/~mangler/services/timeout.php</timeout>
|
17
|
+
</endpoints>
|
18
|
+
<dsl>call :a2, :timeout, parameters: { :method => :post, :arguments => {:timeout => 4} }, finalize: <<-END
|
19
|
+
data.x += "a2,"
|
20
|
+
END
|
21
|
+
call :a3, :timeout, parameters: { :method => :post, :arguments => {:timeout => 4} }, finalize: <<-END
|
22
|
+
data.x += "a3,"
|
23
|
+
END
|
24
|
+
</dsl>
|
25
|
+
<dslx>
|
26
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
27
|
+
<!--{{{-->
|
28
|
+
<call id="a2" endpoint="timeout">
|
29
|
+
<parameters>
|
30
|
+
<!--{{{-->
|
31
|
+
<method>:post</method>
|
32
|
+
<arguments>
|
33
|
+
<timeout>4</timeout>
|
34
|
+
</arguments>
|
35
|
+
</parameters>
|
36
|
+
<!--}}}-->
|
37
|
+
<finalize output="result"> data.x += "a2,"</finalize>
|
38
|
+
</call>
|
39
|
+
<call id="a3" endpoint="timeout">
|
40
|
+
<parameters>
|
41
|
+
<!--{{{-->
|
42
|
+
<method>:post</method>
|
43
|
+
<arguments>
|
44
|
+
<timeout>4</timeout>
|
45
|
+
</arguments>
|
46
|
+
</parameters>
|
47
|
+
<!--}}}-->
|
48
|
+
<finalize output="result"> data.x += "a3,"</finalize>
|
49
|
+
</call>
|
50
|
+
</description>
|
51
|
+
</dslx>
|
52
|
+
<status>
|
53
|
+
<id>0</id>
|
54
|
+
<message>undefined</message>
|
55
|
+
</status>
|
56
|
+
<description>
|
57
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
58
|
+
<!--{{{-->
|
59
|
+
<call id="a2" endpoint="timeout">
|
60
|
+
<parameters>
|
61
|
+
<!--{{{-->
|
62
|
+
<method>:post</method>
|
63
|
+
<arguments>
|
64
|
+
<timeout>4</timeout>
|
65
|
+
</arguments>
|
66
|
+
</parameters>
|
67
|
+
<!--}}}-->
|
68
|
+
<finalize output="result"> data.x += "a2,"</finalize>
|
69
|
+
</call>
|
70
|
+
<call id="a3" endpoint="timeout">
|
71
|
+
<parameters>
|
72
|
+
<!--{{{-->
|
73
|
+
<method>:post</method>
|
74
|
+
<arguments>
|
75
|
+
<timeout>4</timeout>
|
76
|
+
</arguments>
|
77
|
+
</parameters>
|
78
|
+
<!--}}}-->
|
79
|
+
<finalize output="result"> data.x += "a3,"</finalize>
|
80
|
+
</call>
|
81
|
+
</description>
|
82
|
+
</description>
|
83
|
+
<transformation>
|
84
|
+
<description type="copy"/>
|
85
|
+
<dataelements type="rest"/>
|
86
|
+
<endpoints type="rest"/>
|
87
|
+
</transformation>
|
88
|
+
</properties>
|
@@ -0,0 +1,168 @@
|
|
1
|
+
<properties xmlns="http://riddl.org/ns/common-patterns/properties/1.0">
|
2
|
+
<attributes>
|
3
|
+
<info>Enter info here</info>
|
4
|
+
<modeltype>CPEE</modeltype>
|
5
|
+
<theme>default</theme>
|
6
|
+
</attributes>
|
7
|
+
<state>ready</state>
|
8
|
+
<handlerwrapper>DefaultHandlerWrapper</handlerwrapper>
|
9
|
+
<positions/>
|
10
|
+
<dataelements>
|
11
|
+
<persons>3</persons>
|
12
|
+
<card>Visa_12345</card>
|
13
|
+
<airline>null</airline>
|
14
|
+
<hotels>[]</hotels>
|
15
|
+
<from>Vienna</from>
|
16
|
+
<to>Prague</to>
|
17
|
+
<costs>0</costs>
|
18
|
+
</dataelements>
|
19
|
+
<endpoints>
|
20
|
+
<bookAir>http://gruppe.wst.univie.ac.at/~mangler/services/airline.php</bookAir>
|
21
|
+
<bookHotel>http://gruppe.wst.univie.ac.at/~mangler/services/hotel.php</bookHotel>
|
22
|
+
<approve>http://gruppe.wst.univie.ac.at/~mangler/services/approval.php</approve>
|
23
|
+
</endpoints>
|
24
|
+
<dsl>call :a1, :bookAir, parameters: { :method => :post, :arguments => {:from => data.from, :to => data.to, :persons => data.persons} }
|
25
|
+
loop pre_test{} do
|
26
|
+
call :a5, nil, parameters: { }
|
27
|
+
end
|
28
|
+
parallel :wait => 1 do
|
29
|
+
loop post_test{data.persons > 0} do
|
30
|
+
parallel_branch data.persons do |p|
|
31
|
+
call :a2, :bookHotel, parameters: { :method => :post, :arguments => {:to => data.to} }, finalize: <<-END
|
32
|
+
data.hotels << result.value('id')
|
33
|
+
data.costs += result.value('costs').to_f
|
34
|
+
END
|
35
|
+
end
|
36
|
+
manipulate :a3, <<-END
|
37
|
+
data.persons -= 1
|
38
|
+
END
|
39
|
+
end
|
40
|
+
end
|
41
|
+
choose :exclusive do
|
42
|
+
alternative "data.costs > 700" do
|
43
|
+
call :a4, :approve, parameters: { :method => :post, :arguments => {:costs => data.costs} }
|
44
|
+
end
|
45
|
+
end
|
46
|
+
</dsl>
|
47
|
+
<dslx>
|
48
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
49
|
+
<call id="a1" endpoint="bookAir">
|
50
|
+
<parameters>
|
51
|
+
<method>:post</method>
|
52
|
+
<arguments>
|
53
|
+
<from>data.from</from>
|
54
|
+
<to>data.to</to>
|
55
|
+
<persons>data.persons</persons>
|
56
|
+
</arguments>
|
57
|
+
</parameters>
|
58
|
+
<update xmlns="" output="result"/>
|
59
|
+
</call>
|
60
|
+
<loop xmlns="" mode="pre_test" condition="">
|
61
|
+
<call id="a5" endpoint="">
|
62
|
+
<parameters>
|
63
|
+
<label/>
|
64
|
+
<method>:post</method>
|
65
|
+
<arguments/>
|
66
|
+
</parameters>
|
67
|
+
<finalize output="result"/>
|
68
|
+
<update output="result"/>
|
69
|
+
</call>
|
70
|
+
</loop>
|
71
|
+
<parallel wait="1">
|
72
|
+
<loop mode="post_test" condition="data.persons > 0">
|
73
|
+
<parallel_branch pass="data.persons" local="p">
|
74
|
+
<call id="a2" endpoint="bookHotel">
|
75
|
+
<parameters>
|
76
|
+
<method>:post</method>
|
77
|
+
<arguments>
|
78
|
+
<to>data.to</to>
|
79
|
+
</arguments>
|
80
|
+
</parameters>
|
81
|
+
<finalize output="result"> data.hotels << result.value('id')
|
82
|
+
data.costs += result.value('costs').to_f</finalize>
|
83
|
+
</call>
|
84
|
+
</parallel_branch>
|
85
|
+
<manipulate id="a3"> data.persons -= 1</manipulate>
|
86
|
+
</loop>
|
87
|
+
</parallel>
|
88
|
+
<choose mode="exclusive">
|
89
|
+
<otherwise xmlns=""/>
|
90
|
+
<alternative condition="data.costs > 700">
|
91
|
+
<call id="a4" endpoint="approve">
|
92
|
+
<parameters>
|
93
|
+
<method>:post</method>
|
94
|
+
<arguments>
|
95
|
+
<costs>data.costs</costs>
|
96
|
+
</arguments>
|
97
|
+
</parameters>
|
98
|
+
</call>
|
99
|
+
</alternative>
|
100
|
+
</choose>
|
101
|
+
</description>
|
102
|
+
</dslx>
|
103
|
+
<status>
|
104
|
+
<id>0</id>
|
105
|
+
<message>undefined</message>
|
106
|
+
</status>
|
107
|
+
<description>
|
108
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
109
|
+
<call id="a1" endpoint="bookAir">
|
110
|
+
<parameters>
|
111
|
+
<method>:post</method>
|
112
|
+
<arguments>
|
113
|
+
<from>data.from</from>
|
114
|
+
<to>data.to</to>
|
115
|
+
<persons>data.persons</persons>
|
116
|
+
</arguments>
|
117
|
+
</parameters>
|
118
|
+
<update xmlns="" output="result"/>
|
119
|
+
</call>
|
120
|
+
<loop xmlns="" mode="pre_test" condition="">
|
121
|
+
<call id="a5" endpoint="">
|
122
|
+
<parameters>
|
123
|
+
<label/>
|
124
|
+
<method>:post</method>
|
125
|
+
<arguments/>
|
126
|
+
</parameters>
|
127
|
+
<finalize output="result"/>
|
128
|
+
<update output="result"/>
|
129
|
+
</call>
|
130
|
+
</loop>
|
131
|
+
<parallel wait="1">
|
132
|
+
<loop mode="post_test" condition="data.persons > 0">
|
133
|
+
<parallel_branch pass="data.persons" local="p">
|
134
|
+
<call id="a2" endpoint="bookHotel">
|
135
|
+
<parameters>
|
136
|
+
<method>:post</method>
|
137
|
+
<arguments>
|
138
|
+
<to>data.to</to>
|
139
|
+
</arguments>
|
140
|
+
</parameters>
|
141
|
+
<finalize output="result"> data.hotels << result.value('id')
|
142
|
+
data.costs += result.value('costs').to_f</finalize>
|
143
|
+
</call>
|
144
|
+
</parallel_branch>
|
145
|
+
<manipulate id="a3"> data.persons -= 1</manipulate>
|
146
|
+
</loop>
|
147
|
+
</parallel>
|
148
|
+
<choose mode="exclusive">
|
149
|
+
<otherwise xmlns=""/>
|
150
|
+
<alternative condition="data.costs > 700">
|
151
|
+
<call id="a4" endpoint="approve">
|
152
|
+
<parameters>
|
153
|
+
<method>:post</method>
|
154
|
+
<arguments>
|
155
|
+
<costs>data.costs</costs>
|
156
|
+
</arguments>
|
157
|
+
</parameters>
|
158
|
+
</call>
|
159
|
+
</alternative>
|
160
|
+
</choose>
|
161
|
+
</description>
|
162
|
+
</description>
|
163
|
+
<transformation>
|
164
|
+
<description type="copy"/>
|
165
|
+
<dataelements type="rest"/>
|
166
|
+
<endpoints type="rest"/>
|
167
|
+
</transformation>
|
168
|
+
</properties>
|
@@ -0,0 +1,149 @@
|
|
1
|
+
<properties xmlns="http://riddl.org/ns/common-patterns/properties/1.0">
|
2
|
+
<attributes>
|
3
|
+
<info>Enter info here</info>
|
4
|
+
<modeltype>CPEE</modeltype>
|
5
|
+
<theme>default</theme>
|
6
|
+
</attributes>
|
7
|
+
<state>finished</state>
|
8
|
+
<handlerwrapper>DefaultHandlerWrapper</handlerwrapper>
|
9
|
+
<positions/>
|
10
|
+
<dataelements>
|
11
|
+
<persons>0</persons>
|
12
|
+
<card>Visa_12345</card>
|
13
|
+
<airline>Aeroflot</airline>
|
14
|
+
<hotels>["Ibis","Mariott","Mariott"]</hotels>
|
15
|
+
<from>Vienna</from>
|
16
|
+
<to>Prague</to>
|
17
|
+
<costs>983.0</costs>
|
18
|
+
</dataelements>
|
19
|
+
<endpoints>
|
20
|
+
<bookAir>http://gruppe.wst.univie.ac.at/~mangler/services/airline.php</bookAir>
|
21
|
+
<bookHotel>http://gruppe.wst.univie.ac.at/~mangler/services/hotel.php</bookHotel>
|
22
|
+
<approve>http://gruppe.wst.univie.ac.at/~mangler/services/approval.php</approve>
|
23
|
+
</endpoints>
|
24
|
+
<dsl>call :a1, :bookAir, parameters: { :method => :post, :arguments => {:from => data.from, :to => data.to, :persons => data.persons} }, finalize: <<-END
|
25
|
+
data.airline = result.value('id')
|
26
|
+
data.costs += result.value('costs').to_f
|
27
|
+
status.update 1, 'Hotel'
|
28
|
+
END
|
29
|
+
parallel do
|
30
|
+
loop pre_test{data.persons > 0} do
|
31
|
+
parallel_branch data.persons do |p|
|
32
|
+
call :a2, :bookHotel, parameters: { :method => :post, :arguments => {:to => data.to} }, finalize: <<-END
|
33
|
+
data.hotels << result.value('id')
|
34
|
+
data.costs += result.value('costs').to_f
|
35
|
+
END
|
36
|
+
end
|
37
|
+
manipulate :a3, <<-END
|
38
|
+
data.persons -= 1
|
39
|
+
END
|
40
|
+
end
|
41
|
+
end
|
42
|
+
choose :inclusive do
|
43
|
+
alternative "data.costs > 700" do
|
44
|
+
call :a4, :approve, parameters: { :method => :post, :arguments => {:costs => data.costs} }
|
45
|
+
end
|
46
|
+
end
|
47
|
+
</dsl>
|
48
|
+
<dslx>
|
49
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
50
|
+
<call id="a1" endpoint="bookAir">
|
51
|
+
<parameters>
|
52
|
+
<method>:post</method>
|
53
|
+
<arguments>
|
54
|
+
<from>data.from</from>
|
55
|
+
<to>data.to</to>
|
56
|
+
<persons>data.persons</persons>
|
57
|
+
</arguments>
|
58
|
+
</parameters>
|
59
|
+
<finalize output="result"> data.airline = result.value('id')
|
60
|
+
data.costs += result.value('costs').to_f
|
61
|
+
status.update 1, 'Hotel'</finalize>
|
62
|
+
</call>
|
63
|
+
<parallel>
|
64
|
+
<loop mode="pre_test" condition="data.persons > 0">
|
65
|
+
<parallel_branch pass="data.persons" local="p">
|
66
|
+
<call id="a2" endpoint="bookHotel">
|
67
|
+
<parameters>
|
68
|
+
<method>:post</method>
|
69
|
+
<arguments>
|
70
|
+
<to>data.to</to>
|
71
|
+
</arguments>
|
72
|
+
</parameters>
|
73
|
+
<finalize output="result"> data.hotels << result.value('id')
|
74
|
+
data.costs += result.value('costs').to_f</finalize>
|
75
|
+
</call>
|
76
|
+
</parallel_branch>
|
77
|
+
<manipulate id="a3"> data.persons -= 1</manipulate>
|
78
|
+
</loop>
|
79
|
+
</parallel>
|
80
|
+
<choose>
|
81
|
+
<alternative condition="data.costs > 700">
|
82
|
+
<call id="a4" endpoint="approve">
|
83
|
+
<parameters>
|
84
|
+
<method>:post</method>
|
85
|
+
<arguments>
|
86
|
+
<costs>data.costs</costs>
|
87
|
+
</arguments>
|
88
|
+
</parameters>
|
89
|
+
</call>
|
90
|
+
</alternative>
|
91
|
+
</choose>
|
92
|
+
</description>
|
93
|
+
</dslx>
|
94
|
+
<status>
|
95
|
+
<id>0</id>
|
96
|
+
<message>undefined</message>
|
97
|
+
</status>
|
98
|
+
<description>
|
99
|
+
<description xmlns="http://cpee.org/ns/description/1.0">
|
100
|
+
<call id="a1" endpoint="bookAir">
|
101
|
+
<parameters>
|
102
|
+
<method>:post</method>
|
103
|
+
<arguments>
|
104
|
+
<from>data.from</from>
|
105
|
+
<to>data.to</to>
|
106
|
+
<persons>data.persons</persons>
|
107
|
+
</arguments>
|
108
|
+
</parameters>
|
109
|
+
<finalize output="result"> data.airline = result.value('id')
|
110
|
+
data.costs += result.value('costs').to_f
|
111
|
+
status.update 1, 'Hotel'</finalize>
|
112
|
+
</call>
|
113
|
+
<parallel>
|
114
|
+
<loop mode="pre_test" condition="data.persons > 0">
|
115
|
+
<parallel_branch pass="data.persons" local="p">
|
116
|
+
<call id="a2" endpoint="bookHotel">
|
117
|
+
<parameters>
|
118
|
+
<method>:post</method>
|
119
|
+
<arguments>
|
120
|
+
<to>data.to</to>
|
121
|
+
</arguments>
|
122
|
+
</parameters>
|
123
|
+
<finalize output="result"> data.hotels << result.value('id')
|
124
|
+
data.costs += result.value('costs').to_f</finalize>
|
125
|
+
</call>
|
126
|
+
</parallel_branch>
|
127
|
+
<manipulate id="a3"> data.persons -= 1</manipulate>
|
128
|
+
</loop>
|
129
|
+
</parallel>
|
130
|
+
<choose>
|
131
|
+
<alternative condition="data.costs > 700">
|
132
|
+
<call id="a4" endpoint="approve">
|
133
|
+
<parameters>
|
134
|
+
<method>:post</method>
|
135
|
+
<arguments>
|
136
|
+
<costs>data.costs</costs>
|
137
|
+
</arguments>
|
138
|
+
</parameters>
|
139
|
+
</call>
|
140
|
+
</alternative>
|
141
|
+
</choose>
|
142
|
+
</description>
|
143
|
+
</description>
|
144
|
+
<transformation>
|
145
|
+
<description type="copy"/>
|
146
|
+
<dataelements type="rest"/>
|
147
|
+
<endpoints type="rest"/>
|
148
|
+
</transformation>
|
149
|
+
</properties>
|