cpee 2.1.52 → 2.1.54

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.
Files changed (139) hide show
  1. checksums.yaml +4 -4
  2. data/cockpit/css/{resources.css → resources-label.css} +0 -7
  3. data/cockpit/css/resources-svg.css +20 -0
  4. data/cockpit/css/ui.css +0 -4
  5. data/cockpit/edit.html +5 -1
  6. data/cockpit/graph.html +4 -0
  7. data/cockpit/index.html +3 -2
  8. data/cockpit/js/details.js +4 -14
  9. data/cockpit/js/edit.js +3 -0
  10. data/cockpit/js/instance.js +129 -139
  11. data/cockpit/js/modifiers.js +4 -14
  12. data/cockpit/js/parameters.js +4 -10
  13. data/cockpit/js/wfadaptor.js +0 -27
  14. data/cockpit/model.html +2 -0
  15. data/cockpit/templates/Coopis 2010.xml +8 -1
  16. data/cockpit/templates/Worklist.xml +6 -7
  17. data/cockpit/themes/compact/rngs/call.rng +3 -3
  18. data/cockpit/themes/compact/rngs/callmanipulate.rng +3 -3
  19. data/cockpit/themes/compact/rngs/parallel.rng +2 -2
  20. data/cockpit/themes/compact/rngs/start.rng +3 -3
  21. data/cockpit/themes/compact/theme.js +38 -22
  22. data/cockpit/themes/control/rngs/call.rng +3 -3
  23. data/cockpit/themes/control/rngs/callmanipulate.rng +3 -3
  24. data/cockpit/themes/control/rngs/parallel.rng +2 -2
  25. data/cockpit/themes/control/rngs/start.rng +3 -3
  26. data/cockpit/themes/control/theme.js +76 -10
  27. data/cockpit/themes/dataflow/rngs/call.rng +3 -3
  28. data/cockpit/themes/dataflow/rngs/callmanipulate.rng +3 -3
  29. data/cockpit/themes/dataflow/rngs/parallel.rng +2 -2
  30. data/cockpit/themes/dataflow/rngs/start.rng +3 -3
  31. data/cockpit/themes/dataflow/theme.js +48 -32
  32. data/cockpit/themes/default/rngs/call.rng +3 -3
  33. data/cockpit/themes/default/rngs/callmanipulate.rng +3 -3
  34. data/cockpit/themes/default/rngs/parallel.rng +2 -2
  35. data/cockpit/themes/default/rngs/start.rng +3 -3
  36. data/cockpit/themes/default/theme.js +38 -22
  37. data/cockpit/themes/extended/rngs/call.rng +3 -3
  38. data/cockpit/themes/extended/rngs/callmanipulate.rng +3 -3
  39. data/cockpit/themes/extended/rngs/parallel.rng +2 -2
  40. data/cockpit/themes/extended/rngs/start.rng +3 -3
  41. data/cockpit/themes/extended/theme.js +38 -22
  42. data/cockpit/themes/felix/rngs/alternative.rng +25 -0
  43. data/cockpit/themes/felix/rngs/call.rng +229 -0
  44. data/cockpit/themes/felix/rngs/callmanipulate.rng +259 -0
  45. data/cockpit/themes/felix/rngs/choose.rng +14 -0
  46. data/cockpit/themes/felix/rngs/closed_loop.rng +62 -0
  47. data/cockpit/themes/felix/rngs/closed_loop_cancel.rng +5 -0
  48. data/cockpit/themes/felix/rngs/closed_loop_control.rng +31 -0
  49. data/cockpit/themes/felix/rngs/closed_loop_measuring.rng +12 -0
  50. data/cockpit/themes/felix/rngs/critical.rng +5 -0
  51. data/cockpit/themes/felix/rngs/escape.rng +1 -0
  52. data/cockpit/themes/felix/rngs/group.rng +3 -0
  53. data/cockpit/themes/felix/rngs/loop.rng +22 -0
  54. data/cockpit/themes/felix/rngs/manipulate.rng +20 -0
  55. data/cockpit/themes/felix/rngs/otherwise.rng +22 -0
  56. data/cockpit/themes/felix/rngs/parallel.rng +27 -0
  57. data/cockpit/themes/felix/rngs/parallel_branch.rng +2 -0
  58. data/cockpit/themes/felix/rngs/scripts.rng +23 -0
  59. data/cockpit/themes/felix/rngs/start.rng +121 -0
  60. data/cockpit/themes/felix/rngs/stop.rng +5 -0
  61. data/cockpit/themes/felix/rngs/terminate.rng +1 -0
  62. data/cockpit/themes/felix/symbols/alternative.svg +5 -0
  63. data/cockpit/themes/felix/symbols/arrow.svg +3 -0
  64. data/cockpit/themes/felix/symbols/call.svg +6 -0
  65. data/cockpit/themes/felix/symbols/call_sensor.svg +9 -0
  66. data/cockpit/themes/felix/symbols/callmanipulate.svg +8 -0
  67. data/cockpit/themes/felix/symbols/callmanipulate_sensor.svg +11 -0
  68. data/cockpit/themes/felix/symbols/choose.svg +5 -0
  69. data/cockpit/themes/felix/symbols/choose_exclusive.svg +5 -0
  70. data/cockpit/themes/felix/symbols/choose_inclusive.svg +4 -0
  71. data/cockpit/themes/felix/symbols/closed_loop.svg +5 -0
  72. data/cockpit/themes/felix/symbols/closed_loop_cancel.svg +5 -0
  73. data/cockpit/themes/felix/symbols/closed_loop_control.svg +5 -0
  74. data/cockpit/themes/felix/symbols/closed_loop_measuring.svg +6 -0
  75. data/cockpit/themes/felix/symbols/complex.svg +8 -0
  76. data/cockpit/themes/felix/symbols/critical.svg +4 -0
  77. data/cockpit/themes/felix/symbols/delete.svg +4 -0
  78. data/cockpit/themes/felix/symbols/end.svg +3 -0
  79. data/cockpit/themes/felix/symbols/escape.svg +5 -0
  80. data/cockpit/themes/felix/symbols/event_end.svg +3 -0
  81. data/cockpit/themes/felix/symbols/loop.svg +5 -0
  82. data/cockpit/themes/felix/symbols/manipulate.svg +4 -0
  83. data/cockpit/themes/felix/symbols/otherwise.svg +5 -0
  84. data/cockpit/themes/felix/symbols/parallel.svg +5 -0
  85. data/cockpit/themes/felix/symbols/parallel_branch.svg +5 -0
  86. data/cockpit/themes/felix/symbols/parallel_branch_compact.svg +4 -0
  87. data/cockpit/themes/felix/symbols/parallel_branch_event.svg +14 -0
  88. data/cockpit/themes/felix/symbols/parallel_branch_normal.svg +5 -0
  89. data/cockpit/themes/felix/symbols/parallel_eventbased_exclusive.svg +9 -0
  90. data/cockpit/themes/felix/symbols/parallel_eventbased_parallel.svg +8 -0
  91. data/cockpit/themes/felix/symbols/scripts.svg +4 -0
  92. data/cockpit/themes/felix/symbols/start.svg +3 -0
  93. data/cockpit/themes/felix/symbols/start_event.svg +5 -0
  94. data/cockpit/themes/felix/symbols/stop.svg +5 -0
  95. data/cockpit/themes/felix/symbols/terminate.svg +4 -0
  96. data/cockpit/themes/felix/theme.js +1531 -0
  97. data/cockpit/themes/model/rngs/call.rng +10 -10
  98. data/cockpit/themes/model/rngs/callmanipulate.rng +10 -10
  99. data/cockpit/themes/model/theme.js +14 -3
  100. data/cockpit/themes/packed/rngs/call.rng +3 -3
  101. data/cockpit/themes/packed/rngs/callmanipulate.rng +3 -3
  102. data/cockpit/themes/packed/rngs/parallel.rng +2 -2
  103. data/cockpit/themes/packed/rngs/start.rng +3 -3
  104. data/cockpit/themes/packed/theme.js +38 -22
  105. data/cockpit/themes/preset/rngs/call.rng +3 -3
  106. data/cockpit/themes/preset/rngs/callmanipulate.rng +3 -3
  107. data/cockpit/themes/preset/rngs/parallel.rng +2 -2
  108. data/cockpit/themes/preset/rngs/start.rng +3 -3
  109. data/cockpit/themes/preset/theme.js +38 -22
  110. data/cockpit/track.html +4 -0
  111. data/cpee.gemspec +1 -1
  112. data/lib/cpee/implementation.rb +1 -1
  113. data/lib/cpee/implementation_properties.rb +23 -13
  114. data/lib/properties/state.rng +0 -2
  115. data/lib/properties.xml +0 -1
  116. data/server/executionhandlers/ruby/connection.rb +25 -16
  117. data/server/executionhandlers/ruby/controller.rb +1 -1
  118. data/server/executionhandlers/ruby/dsl_to_dslx.xsl +71 -61
  119. data/server/resources/states.dot +0 -4
  120. data/server/resources/states.xml +0 -6
  121. data/server/routing/end.pid +1 -0
  122. data/server/routing/forward-events-00.pid +1 -0
  123. data/server/routing/forward-votes.pid +1 -0
  124. data/server/routing/persist.pid +1 -0
  125. metadata +63 -17
  126. data/cockpit/css/replay.css +0 -55
  127. data/cockpit/js/replay.js +0 -40
  128. data/cockpit/replay.html +0 -53
  129. data/cockpit/themes/compact/symbols/test.svg +0 -74
  130. data/cockpit/themes/control/symbols/test.svg +0 -74
  131. data/cockpit/themes/dataflow/symbols/test.svg +0 -74
  132. data/cockpit/themes/default/symbols/test.svg +0 -74
  133. data/cockpit/themes/extended/symbols/test.svg +0 -74
  134. data/cockpit/themes/model/symbols/test.svg +0 -74
  135. data/cockpit/themes/packed/symbols/test.svg +0 -74
  136. data/cockpit/themes/preset/symbols/test.svg +0 -74
  137. data/server/executionhandlers/ruby/desc.xml +0 -107
  138. data/server/resources/test.pdf +0 -0
  139. data/server/server.conf +0 -4
@@ -228,24 +228,6 @@ function WfIllustrator(wf_adaptor) { // View {{{
228
228
  return g;
229
229
  } // }}}
230
230
 
231
- var draw_label = this.draw.draw_label = function (tname, id, label, row, col, group) { // {{{
232
- var g = $X('<text class="label" transform="translate(' + String(col*self.width-self.width_shift) + ',' + String(row*self.height+20-(self.height-self.height_shift)) + ')" xmlns="http://www.w3.org/2000/svg"></text>');
233
- var spli = $(label.split(/\n/));
234
- spli.each(function(k,v) {
235
- var tspan = $X('<tspan x="0" dy="' + (spli.length > 1 ? '-7' : '0') + '" xmlns="http://www.w3.org/2000/svg"></tspan>');
236
- if (k == 0) {
237
- tspan.text(v);
238
- } else {
239
- tspan.text(v);
240
- tspan.attr('dy','15');
241
- tspan.attr('dx','15');
242
- }
243
- g.append(tspan);
244
- });
245
- if(group) { group.find('g.element[element-id=' + id + ']').append(g); }
246
- else {self.svg.container.append(g);}
247
- return g;
248
- } // }}}
249
231
  var draw_symbol = this.draw.draw_symbol = function (sname, id, title, row, col, group, addition) { // {{{
250
232
  if(self.elements[sname] == undefined || self.elements[sname].svg == undefined) sname = 'unknown';
251
233
  if (addition) {
@@ -380,15 +362,6 @@ function WfDescription(wf_adaptor, wf_illustrator) { // Model {{{
380
362
  } else {
381
363
  adaptor.draw_labels(graph.max,[],{ 'height': illustrator.height, 'height_shift': illustrator.height_shift },false);
382
364
  }
383
- if (illustrator.compact == false) {
384
- if (labels.length > 0) {
385
- _.each(labels,function(a,key) {
386
- if (a.label && a.label[0] && a.label[0].column == 'Label' && a.label[0].value) {
387
- illustrator.draw.draw_label(a.tname, a.element_id, a.label[0].value, a.row, graph.max.col + 1, graph.svg);
388
- }
389
- });
390
- }
391
- }
392
365
  } //}}}
393
366
 
394
367
  // Generic Functions {{{
data/cockpit/model.html CHANGED
@@ -58,6 +58,8 @@
58
58
  <script type="text/javascript" src="js/edit.js"></script>
59
59
  <link rel="stylesheet" href="css/ui.css" type="text/css"/>
60
60
  <link rel="stylesheet" href="css/model.css" type="text/css"/>
61
+ <link rel="stylesheet" href="css/resources-label.css" type="text/css"/>
62
+ <link rel="stylesheet" href="css/resources-svg.css" type="text/css" data-include-export="true"/>
61
63
  <link rel="stylesheet" href="/global_ui/uicpee.css" type="text/css"/>
62
64
  <style>
63
65
  /* has to be fucking inline, because firefox and chrome disagree how to handle filter urls */
@@ -12,10 +12,14 @@
12
12
  </dataelements>
13
13
  <endpoints>
14
14
  <bookAir>http://gruppe.wst.univie.ac.at/~mangler/services/airline.php</bookAir>
15
+ <user>https-post://cpee.org/services/timeout-user.php</user>
16
+ <auto>https-post://cpee.org/services/timeout-auto.php</auto>
15
17
  <timeout>https://cpee.org/services/timeout.php</timeout>
16
18
  <bookHotel>http://gruppe.wst.univie.ac.at/~mangler/services/hotel.php</bookHotel>
17
19
  <subprocess>https://cpee.org/flow/start/url/</subprocess>
18
20
  <approve>http://gruppe.wst.univie.ac.at/~mangler/services/approval.php</approve>
21
+ <send>https-post://cpee.org/ing/correlators/message/send/</send>
22
+ <receive>https-get://cpee.org/ing/correlators/message/receive/</receive>
19
23
  </endpoints>
20
24
  <attributes>
21
25
  <theme>extended</theme>
@@ -25,10 +29,13 @@
25
29
  <modeltype>CPEE</modeltype>
26
30
  <design_stage>development</design_stage>
27
31
  <guarded>none</guarded>
28
- <design_dir>Templates.dir</design_dir>
32
+ <design_dir>Experiments.dir/Twin Engine.dir</design_dir>
29
33
  <guarded_id/>
30
34
  <model_uuid>a1cbb855-90e3-4d8c-b44b-d3ba7bff9f4e</model_uuid>
31
35
  <model_version/>
36
+ <replay>https://cpee.org/replay/</replay>
37
+ <replay_target>https://cpee.org/replay-data/coopis/1274c1de-286e-4d73-9375-30b363d280fa.xes.yaml</replay_target>
38
+ <replay_instantiate>https://cpee.org/flow/start/url/</replay_instantiate>
32
39
  </attributes>
33
40
  <description>
34
41
  <description xmlns="http://cpee.org/ns/description/1.0">
@@ -3,13 +3,7 @@
3
3
  <executionhandler>ruby</executionhandler>
4
4
  <dataelements/>
5
5
  <endpoints>
6
- <timeout>http://gruppe.wst.univie.ac.at/~mangler/services/timeout.php</timeout>
7
- <subprocess>https-post://cpee.org/flow/start/url/</subprocess>
8
6
  <worklist>https-post://cpee.org/worklist/server/</worklist>
9
- <send>https-post://cpee.org/ing/correlators/message/send/</send>
10
- <receive>https-get://cpee.org/ing/correlators/message/receive/</receive>
11
- <user>https-post://cpee.org/services/timeout-user.php</user>
12
- <auto>https-post://cpee.org/services/timeout-auto.php</auto>
13
7
  </endpoints>
14
8
  <attributes>
15
9
  <info>Worklist</info>
@@ -28,9 +22,10 @@
28
22
  <label>OK OR NOT OK</label>
29
23
  <arguments>
30
24
  <orgmodel>https://cpee.org/~demo/orgviz/organisation_informatik.xml</orgmodel>
31
- <domain>VirtualBusiness1</domain>
32
25
  <form>https://cpee.org/~demo/form/form-f.html</form>
33
26
  <role>Assistant</role>
27
+ <priority>42</priority>
28
+ <restrictions/>
34
29
  <data>
35
30
  <schaden>10000</schaden>
36
31
  <text>destroyed</text>
@@ -44,11 +39,15 @@
44
39
  <rescue output="result"/>
45
40
  </code>
46
41
  <annotations>
42
+ <_generic/>
47
43
  <_timing>
48
44
  <_timing_weight/>
49
45
  <_timing_avg/>
50
46
  <explanations/>
51
47
  </_timing>
48
+ <_shifting>
49
+ <_shifting_type>Duration</_shifting_type>
50
+ </_shifting>
52
51
  <_context_data_analysis>
53
52
  <probes/>
54
53
  <ips/>
@@ -98,9 +98,9 @@
98
98
  </element>
99
99
  <element name="extractor_type" rngui:label="Extractor Type">
100
100
  <choice>
101
- <value id='intrinsic'>Intrinsic</value>
102
- <value id='extrinsic'>Extrinsic</value>
103
- <value id='separate'>Separate</value>
101
+ <value rngui:label='Intrinsic'>intrinsic</value>
102
+ <value rngui:label='Extrinsic'>extrinsic</value>
103
+ <value rngui:label='Separate'>separate</value>
104
104
  </choice>
105
105
  </element>
106
106
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -122,9 +122,9 @@
122
122
  </element>
123
123
  <element name="extractor_type" rngui:label="Extractor Type">
124
124
  <choice>
125
- <value id='intrinsic'>Intrinsic</value>
126
- <value id='extrinsic'>Extrinsic</value>
127
- <value id='separate'>Separate</value>
125
+ <value rngui:label='Intrinsic'>intrinsic</value>
126
+ <value rngui:label='Extrinsic'>extrinsic</value>
127
+ <value rngui:label='Separate'>separate</value>
128
128
  </choice>
129
129
  </element>
130
130
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -4,8 +4,8 @@
4
4
  </attribute>
5
5
  <attribute name="cancel" rngui:label="Cancel" rngui:default="last" rngui:hint="Set 'Wait' to 1 for standard Event-based Gateway.">
6
6
  <choice>
7
- <value id='last'>After Last Task in Branch</value>
8
- <value id='first'>After First Task in Branch (Event-Based Gateway)</value>
7
+ <value rngui:label='After Last Task in Branch'>last</value>
8
+ <value rngui:label='After First Task in Branch (Event-Based Gateway)'>first</value>
9
9
  </choice>
10
10
  </attribute>
11
11
  <element rngui:ignore="true" name="parallel_branch">
@@ -29,9 +29,9 @@
29
29
  </element>
30
30
  <element name="extractor_type" rngui:label="Extractor Type">
31
31
  <choice>
32
- <value id='intrinsic'>Intrinsic</value>
33
- <value id='extrinsic'>Extrinsic</value>
34
- <value id='separate'>Separate</value>
32
+ <value rngui:label='Intrinsic'>intrinsic</value>
33
+ <value rngui:label='Extrinsic'>extrinsic</value>
34
+ <value rngui:label='Separate'>separate</value>
35
35
  </choice>
36
36
  </element>
37
37
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -64,7 +64,6 @@ function WFAdaptorManifestation(adaptor) {
64
64
  this.update_details = function(svgid){
65
65
  var tab = $('#dat_details');
66
66
  var node = self.adaptor.description.get_node_by_svg_id(svgid).get(0);
67
- tab.empty();
68
67
  if (self.adaptor.description.elements[$(node).attr('svg-subtype')]) {
69
68
  save['details_target'] = { 'svgid': svgid, 'model': self.adaptor.description };
70
69
  var rng = self.adaptor.description.elements[$(node).attr('svg-subtype')].clone();
@@ -75,13 +74,16 @@ function WFAdaptorManifestation(adaptor) {
75
74
  if (save['endpoints_list'][$(node).attr('endpoint')] && (!save['endpoints_list'][$(node).attr('endpoint')].startsWith('http') || save['endpoints_list'][$(node).attr('endpoint')].match(/^https?-/))) {
76
75
  $(rng).find(' > element[name="parameters"] > element[name="method"]').remove();
77
76
  }
78
- save['details'] = new RelaxNGui(rng,tab,self.adaptor.description.context_eval,true);
79
77
  var nn = $X($(node).serializeXML());
80
78
  nn.removeAttr('svg-id');
81
79
  nn.removeAttr('svg-type');
82
80
  nn.removeAttr('svg-subtype');
83
81
  nn.removeAttr('svg-label');
82
+
83
+ tab.empty();
84
+ save['details'] = new RelaxNGui(rng,tab,self.adaptor.description.context_eval,true);
84
85
  save['details'].content(nn);
86
+
85
87
  format_visual_forms();
86
88
  }
87
89
  }; //}}}
@@ -201,8 +203,17 @@ function WFAdaptorManifestation(adaptor) {
201
203
  $(nodes).each(function(key,str) {
202
204
  nodes[key] = $X(str);
203
205
  });
206
+ let svgids = [];
204
207
  $(nodes).each(function(key,node){
205
- var target = self.adaptor.description.get_node_by_svg_id($(node).attr('svg-id'));
208
+ svgids.push($(node).attr('svg-id'));
209
+ });
210
+ svgids.sort((a,b) => {
211
+ if (a > b) { return -1; }
212
+ else if (a < b) { return 1; }
213
+ else { return 0; }
214
+ });
215
+ svgids.forEach(svgid => {
216
+ var target = self.adaptor.description.get_node_by_svg_id(svgid);
206
217
  del_ui_pos(target)
207
218
  self.adaptor.description.remove(null,target);
208
219
  localStorage.removeItem('marked');
@@ -1223,28 +1234,33 @@ function WFAdaptorManifestation(adaptor) {
1223
1234
  return 'vertical';
1224
1235
  },
1225
1236
  'resolve_symbol': function(node) {
1237
+ let alist = []
1226
1238
  let plist = []
1227
- let dirty = false
1228
- $('*:not(:has(*))',node).each(function(i,n) {
1229
- let lines = n.textContent.split(/(\r\n)|\n|;/)
1230
- for (const l of lines) {
1231
- if (l != null) {
1232
- let m0 = l.match(/^[^=]*data\.([a-z0-9A-Z_]+)[^=]*=/)
1233
- if (m0 != null) {
1234
- plist.push(m0[1])
1235
- }
1236
- let m1 = l.match(/=[^=].*data\.([a-z0-9A-Z_]+)/)
1237
- let m2 = l.match(/^[^=]*data\.([a-z0-9A-Z_]+)[^=]*$/)
1238
- if (m1 != null && !plist.includes(m1[1])) {
1239
- dirty = true
1240
- }
1241
- if (m2 != null && !plist.includes(m2[1])) {
1242
- dirty = true
1243
- }
1244
- }
1239
+
1240
+ var regassi = /data\.([a-zA-Z_]+)\s*(=[^=]|\+\=|\-\=|\*\=|\/\=|<<|>>)/g; // we do not have to check for &gt;/&lt; version of stuff as only conditions are in attributes, and conditions can not contain assignments
1241
+ var reg_not_assi = /data\.([a-zA-Z_]+)\s*/g;
1242
+ $ ('call > parameters > arguments > *, call > code > *, loop[condition], alternative[condition]',node).each(function(i,n) {
1243
+ let item;
1244
+ if (n.hasAttribute('condition')) {
1245
+ item = n.getAttribute('condition');
1246
+ } else {
1247
+ item = n.textContent;
1248
+ }
1249
+ if (n.parentNode.nodeName == 'arguments' && item.charAt(0) != '!' ) { return }
1250
+
1251
+ let indices = [];
1252
+
1253
+ for (const match of item.matchAll(regassi)) {
1254
+ indices.push(match.index);
1255
+ alist.push(match[1]);
1256
+ }
1257
+ for (const match of item.matchAll(reg_not_assi)) {
1258
+ const arg1 = match[1];
1259
+ if (indices.includes(match.index)) { continue; }
1260
+ if (!alist.includes(arg1)) { plist.push(arg1); }
1245
1261
  }
1246
1262
  })
1247
- if (dirty) { return 'start_event'; }
1263
+ if (plist.length > 0) { return 'start_event'; }
1248
1264
  },
1249
1265
  'closing_symbol': 'end',
1250
1266
  'col_shift': function(node) {
@@ -98,9 +98,9 @@
98
98
  </element>
99
99
  <element name="extractor_type" rngui:label="Extractor Type">
100
100
  <choice>
101
- <value id='intrinsic'>Intrinsic</value>
102
- <value id='extrinsic'>Extrinsic</value>
103
- <value id='separate'>Separate</value>
101
+ <value rngui:label='Intrinsic'>intrinsic</value>
102
+ <value rngui:label='Extrinsic'>extrinsic</value>
103
+ <value rngui:label='Separate'>separate</value>
104
104
  </choice>
105
105
  </element>
106
106
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -122,9 +122,9 @@
122
122
  </element>
123
123
  <element name="extractor_type" rngui:label="Extractor Type">
124
124
  <choice>
125
- <value id='intrinsic'>Intrinsic</value>
126
- <value id='extrinsic'>Extrinsic</value>
127
- <value id='separate'>Separate</value>
125
+ <value rngui:label='Intrinsic'>intrinsic</value>
126
+ <value rngui:label='Extrinsic'>extrinsic</value>
127
+ <value rngui:label='Separate'>separate</value>
128
128
  </choice>
129
129
  </element>
130
130
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -4,8 +4,8 @@
4
4
  </attribute>
5
5
  <attribute name="cancel" rngui:label="Cancel" rngui:default="last" rngui:hint="Set 'Wait' to 1 for standard Event-based Gateway.">
6
6
  <choice>
7
- <value id='last'>After Last Task in Branch</value>
8
- <value id='first'>After First Task in Branch (Event-Based Gateway)</value>
7
+ <value rngui:label='After Last Task in Branch'>last</value>
8
+ <value rngui:label='After First Task in Branch (Event-Based Gateway)'>first</value>
9
9
  </choice>
10
10
  </attribute>
11
11
  <element rngui:ignore="true" name="parallel_branch">
@@ -29,9 +29,9 @@
29
29
  </element>
30
30
  <element name="extractor_type" rngui:label="Extractor Type">
31
31
  <choice>
32
- <value id='intrinsic'>Intrinsic</value>
33
- <value id='extrinsic'>Extrinsic</value>
34
- <value id='separate'>Separate</value>
32
+ <value rngui:label='Intrinsic'>intrinsic</value>
33
+ <value rngui:label='Extrinsic'>extrinsic</value>
34
+ <value rngui:label='Separate'>separate</value>
35
35
  </choice>
36
36
  </element>
37
37
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -64,7 +64,6 @@ function WFAdaptorManifestation(adaptor) {
64
64
  this.update_details = function(svgid){
65
65
  var tab = $('#dat_details');
66
66
  var node = self.adaptor.description.get_node_by_svg_id(svgid).get(0);
67
- tab.empty();
68
67
  if (self.adaptor.description.elements[$(node).attr('svg-subtype')]) {
69
68
  save['details_target'] = { 'svgid': svgid, 'model': self.adaptor.description };
70
69
  var rng = self.adaptor.description.elements[$(node).attr('svg-subtype')].clone();
@@ -75,13 +74,16 @@ function WFAdaptorManifestation(adaptor) {
75
74
  if (save['endpoints_list'][$(node).attr('endpoint')] && (!save['endpoints_list'][$(node).attr('endpoint')].startsWith('http') || save['endpoints_list'][$(node).attr('endpoint')].match(/^https?-/))) {
76
75
  $(rng).find(' > element[name="parameters"] > element[name="method"]').remove();
77
76
  }
78
- save['details'] = new RelaxNGui(rng,tab,self.adaptor.description.context_eval,true);
79
77
  var nn = $X($(node).serializeXML());
80
78
  nn.removeAttr('svg-id');
81
79
  nn.removeAttr('svg-type');
82
80
  nn.removeAttr('svg-subtype');
83
81
  nn.removeAttr('svg-label');
82
+
83
+ tab.empty();
84
+ save['details'] = new RelaxNGui(rng,tab,self.adaptor.description.context_eval,true);
84
85
  save['details'].content(nn);
86
+
85
87
  format_visual_forms();
86
88
  }
87
89
  }; //}}}
@@ -201,8 +203,17 @@ function WFAdaptorManifestation(adaptor) {
201
203
  $(nodes).each(function(key,str) {
202
204
  nodes[key] = $X(str);
203
205
  });
206
+ let svgids = [];
204
207
  $(nodes).each(function(key,node){
205
- var target = self.adaptor.description.get_node_by_svg_id($(node).attr('svg-id'));
208
+ svgids.push($(node).attr('svg-id'));
209
+ });
210
+ svgids.sort((a,b) => {
211
+ if (a > b) { return -1; }
212
+ else if (a < b) { return 1; }
213
+ else { return 0; }
214
+ });
215
+ svgids.forEach(svgid => {
216
+ var target = self.adaptor.description.get_node_by_svg_id(svgid);
206
217
  del_ui_pos(target)
207
218
  self.adaptor.description.remove(null,target);
208
219
  localStorage.removeItem('marked');
@@ -375,10 +386,18 @@ function WFAdaptorManifestation(adaptor) {
375
386
  },
376
387
  'info': function(node){ return { 'element-endpoint': $(node).attr('endpoint') }; },
377
388
  'resolve_symbol': function(node) {
378
- if($('> code', node).length > 0) {
379
- return 'callmanipulate';
389
+ if ($('> annotations > _context_data_analysis > probes > probe', node).length > 0) {
390
+ if ($('> code', node).length > 0) {
391
+ return 'callmanipulate_sensor';
392
+ } else {
393
+ return 'call_sensor';
394
+ }
380
395
  } else {
381
- return 'call';
396
+ if ($('> code', node).length > 0) {
397
+ return 'callmanipulate';
398
+ } else {
399
+ return 'call';
400
+ }
382
401
  }
383
402
  },
384
403
  'svg': self.adaptor.theme_dir + 'symbols/call.svg'
@@ -972,7 +991,7 @@ function WFAdaptorManifestation(adaptor) {
972
991
  ret.push({ column: 'Average', value: avg + '%' });
973
992
  }
974
993
  return ret;
975
- },
994
+ ,
976
995
  'svg': self.adaptor.theme_dir + 'symbols/closed_loop.svg'
977
996
  },//}}}
978
997
  'description': self.adaptor.theme_dir + 'rngs/closed_loop.rng',
@@ -1576,13 +1595,42 @@ function WFAdaptorManifestation(adaptor) {
1576
1595
  'expansion': function(node) {
1577
1596
  return 'vertical';
1578
1597
  },
1598
+ 'resolve_symbol': function(node) {
1599
+ let alist = []
1600
+ let plist = []
1601
+
1602
+ var regassi = /data\.([a-zA-Z_]+)\s*(=[^=]|\+\=|\-\=|\*\=|\/\=|<<|>>)/g; // we do not have to check for &gt;/&lt; version of stuff as only conditions are in attributes, and conditions can not contain assignments
1603
+ var reg_not_assi = /data\.([a-zA-Z_]+)\s*/g;
1604
+ $ ('call > parameters > arguments > *, call > code > *, loop[condition], alternative[condition]',node).each(function(i,n) {
1605
+ let item;
1606
+ if (n.hasAttribute('condition')) {
1607
+ item = n.getAttribute('condition');
1608
+ } else {
1609
+ item = n.textContent;
1610
+ }
1611
+ if (n.parentNode.nodeName == 'arguments' && item.charAt(0) != '!' ) { return }
1612
+
1613
+ let indices = [];
1614
+
1615
+ for (const match of item.matchAll(regassi)) {
1616
+ indices.push(match.index);
1617
+ alist.push(match[1]);
1618
+ }
1619
+ for (const match of item.matchAll(reg_not_assi)) {
1620
+ const arg1 = match[1];
1621
+ if (indices.includes(match.index)) { continue; }
1622
+ if (!alist.includes(arg1)) { plist.push(arg1); }
1623
+ }
1624
+ })
1625
+ if (plist.length > 0) { return 'start_event'; }
1626
+ },
1579
1627
  'closing_symbol': 'end',
1580
1628
  'col_shift': function(node) {
1581
1629
  return true;
1582
1630
  },
1583
1631
  'svg': self.adaptor.theme_dir + 'symbols/start.svg'
1584
1632
  },//}}}
1585
- 'description': null,
1633
+ 'description': self.adaptor.theme_dir + 'rngs/start.rng',
1586
1634
  'permissible_children': function(node,mode) { //{{{
1587
1635
  var func = null;
1588
1636
  if (mode == 'into') { func = self.adaptor.description.insert_first_into }
@@ -1654,13 +1702,31 @@ function WFAdaptorManifestation(adaptor) {
1654
1702
  // Abstract Elements
1655
1703
  // * they may only have an illustrator (or other parts)
1656
1704
  // * they HAVE TO have a parent
1705
+ this.elements.start_event = { /*{{{*/
1706
+ 'parent': 'start',
1707
+ 'illustrator': {//{{{
1708
+ 'svg': self.adaptor.theme_dir + 'symbols/start_event.svg'
1709
+ }//}}}
1710
+ }; /*}}}*/
1711
+ this.elements.call_sensor = { /*{{{*/
1712
+ 'parent': 'call',
1713
+ 'illustrator': {//{{{
1714
+ 'svg': self.adaptor.theme_dir + 'symbols/call_sensor.svg'
1715
+ }//}}}
1716
+ }; /*}}}*/
1657
1717
  this.elements.callmanipulate = { /*{{{*/
1658
1718
  'parent': 'call',
1659
1719
  'description': self.adaptor.theme_dir + 'rngs/callmanipulate.rng',
1660
1720
  'illustrator': {//{{{
1661
- 'info': function(node){ return { 'element-endpoint': $(node).attr('endpoint') }; },
1662
1721
  'svg': self.adaptor.theme_dir + 'symbols/callmanipulate.svg'
1663
- },//}}}
1722
+ }//}}}
1723
+ }; /*}}}*/
1724
+ this.elements.callmanipulate_sensor = { /*{{{*/
1725
+ 'parent': 'call',
1726
+ 'description': self.adaptor.theme_dir + 'rngs/callmanipulate.rng',
1727
+ 'illustrator': {//{{{
1728
+ 'svg': self.adaptor.theme_dir + 'symbols/callmanipulate_sensor.svg'
1729
+ }//}}}
1664
1730
  }; /*}}}*/
1665
1731
  this.elements.loop_head = { /*{{{*/
1666
1732
  'parent': 'loop',
@@ -98,9 +98,9 @@
98
98
  </element>
99
99
  <element name="extractor_type" rngui:label="Extractor Type">
100
100
  <choice>
101
- <value id='intrinsic'>Intrinsic</value>
102
- <value id='extrinsic'>Extrinsic</value>
103
- <value id='separate'>Separate</value>
101
+ <value rngui:label='Intrinsic'>intrinsic</value>
102
+ <value rngui:label='Extrinsic'>extrinsic</value>
103
+ <value rngui:label='Separate'>separate</value>
104
104
  </choice>
105
105
  </element>
106
106
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -122,9 +122,9 @@
122
122
  </element>
123
123
  <element name="extractor_type" rngui:label="Extractor Type">
124
124
  <choice>
125
- <value id='intrinsic'>Intrinsic</value>
126
- <value id='extrinsic'>Extrinsic</value>
127
- <value id='separate'>Separate</value>
125
+ <value rngui:label='Intrinsic'>intrinsic</value>
126
+ <value rngui:label='Extrinsic'>extrinsic</value>
127
+ <value rngui:label='Separate'>separate</value>
128
128
  </choice>
129
129
  </element>
130
130
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>
@@ -4,8 +4,8 @@
4
4
  </attribute>
5
5
  <attribute name="cancel" rngui:label="Cancel" rngui:default="last" rngui:hint="Set 'Wait' to 1 for standard Event-based Gateway.">
6
6
  <choice>
7
- <value id='last'>After Last Task in Branch</value>
8
- <value id='first'>After First Task in Branch (Event-Based Gateway)</value>
7
+ <value rngui:label='After Last Task in Branch'>last</value>
8
+ <value rngui:label='After First Task in Branch (Event-Based Gateway)'>first</value>
9
9
  </choice>
10
10
  </attribute>
11
11
  <element rngui:ignore="true" name="parallel_branch">
@@ -29,9 +29,9 @@
29
29
  </element>
30
30
  <element name="extractor_type" rngui:label="Extractor Type">
31
31
  <choice>
32
- <value id='intrinsic'>Intrinsic</value>
33
- <value id='extrinsic'>Extrinsic</value>
34
- <value id='separate'>Separate</value>
32
+ <value rngui:label='Intrinsic'>intrinsic</value>
33
+ <value rngui:label='Extrinsic'>extrinsic</value>
34
+ <value rngui:label='Separate'>separate</value>
35
35
  </choice>
36
36
  </element>
37
37
  <element name="extractor_code" rngui:label="Extractor Code" rngui:hint='For intrinsic &amp; extrinsic data'>