cpee 1.3.177 → 1.3.178

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 (118) hide show
  1. checksums.yaml +4 -4
  2. data/cockpit/css/ui.css +20 -3
  3. data/cockpit/{lib → css}/wfadaptor.css +0 -0
  4. data/cockpit/index.html +47 -22
  5. data/cockpit/js/details.js +18 -18
  6. data/cockpit/js/instance.js +50 -9
  7. data/cockpit/js/parameters.js +16 -15
  8. data/cockpit/js/ui.js +1 -4
  9. data/cockpit/js/wfadaptor.cpee.js +3 -20
  10. data/cockpit/{lib → js}/wfadaptor.js +39 -15
  11. data/cockpit/rngtest.html +14 -35
  12. data/cockpit/rngtest.rng +17 -39
  13. data/cockpit/rngtest.xml +7 -6
  14. data/cockpit/test.html +46 -0
  15. data/cockpit/testsets/Infinity.xml +28 -0
  16. data/cockpit/testsets/testsets.xml +1 -0
  17. data/cpee.gemspec +1 -1
  18. data/lib/cpee/controller.rb +8 -8
  19. data/lib/cpee/handler_properties.rb +1 -0
  20. data/lib/cpee/implementation.rb +9 -0
  21. data/lib/engine.xml +3 -3
  22. data/server/resources/topics.xml +3 -0
  23. data/test/{cb.rb → callback.rb} +0 -0
  24. metadata +8 -103
  25. data/cockpit/lib/custommenu.css +0 -84
  26. data/cockpit/lib/custommenu.js +0 -101
  27. data/cockpit/lib/jquery.browser.js +0 -40
  28. data/cockpit/lib/jquery.caret.min.js +0 -10
  29. data/cockpit/lib/jquery.cookie.js +0 -117
  30. data/cockpit/lib/jquery.min.js +0 -4
  31. data/cockpit/lib/jquery.svg.min.js +0 -6
  32. data/cockpit/lib/jquery.svgdom.min.js +0 -6
  33. data/cockpit/lib/parsequery.js +0 -19
  34. data/cockpit/lib/printf.js +0 -368
  35. data/cockpit/lib/relaxngui.js +0 -4
  36. data/cockpit/lib/strftime.min.js +0 -1
  37. data/cockpit/lib/ui.css +0 -261
  38. data/cockpit/lib/ui.js +0 -114
  39. data/cockpit/lib/underscore.min.js +0 -27
  40. data/cockpit/lib/util.js +0 -58
  41. data/cockpit/lib/wfadaptor-doc/demo1.html +0 -517
  42. data/cockpit/lib/wfadaptor-doc/demo2.html +0 -84
  43. data/cockpit/lib/wfadaptor-doc/index.html +0 -54
  44. data/server/instances/1/properties.xml +0 -113
  45. data/server/instances/10/properties.xml +0 -145
  46. data/server/instances/11/properties.xml +0 -169
  47. data/server/instances/12/properties.xml +0 -44
  48. data/server/instances/13/properties.xml +0 -146
  49. data/server/instances/14/notifications/5bcce90b170116a77fb25aea4e133acc/consumer-secret +0 -1
  50. data/server/instances/14/notifications/5bcce90b170116a77fb25aea4e133acc/producer-secret +0 -1
  51. data/server/instances/14/notifications/5bcce90b170116a77fb25aea4e133acc/subscription.xml +0 -23
  52. data/server/instances/14/properties.xml +0 -332
  53. data/server/instances/15/properties.xml +0 -44
  54. data/server/instances/16/properties.xml +0 -44
  55. data/server/instances/17/properties.xml +0 -44
  56. data/server/instances/18/properties.xml +0 -45
  57. data/server/instances/19/properties.xml +0 -45
  58. data/server/instances/2/properties.xml +0 -230
  59. data/server/instances/20/properties.xml +0 -46
  60. data/server/instances/21/properties.xml +0 -46
  61. data/server/instances/22/notifications/f9c504b8c715ec94a99fc3c6a660c53a/consumer-secret +0 -1
  62. data/server/instances/22/notifications/f9c504b8c715ec94a99fc3c6a660c53a/producer-secret +0 -1
  63. data/server/instances/22/notifications/f9c504b8c715ec94a99fc3c6a660c53a/subscription.xml +0 -23
  64. data/server/instances/22/properties.xml +0 -112
  65. data/server/instances/23/notifications/0a5a059f4ae897aee1446d560210dec0/consumer-secret +0 -1
  66. data/server/instances/23/notifications/0a5a059f4ae897aee1446d560210dec0/producer-secret +0 -1
  67. data/server/instances/23/notifications/0a5a059f4ae897aee1446d560210dec0/subscription.xml +0 -23
  68. data/server/instances/23/properties.xml +0 -148
  69. data/server/instances/24/properties.xml +0 -66
  70. data/server/instances/25/properties.xml +0 -46
  71. data/server/instances/26/properties.xml +0 -112
  72. data/server/instances/27/properties.xml +0 -212
  73. data/server/instances/28/properties.xml +0 -363
  74. data/server/instances/29/properties.xml +0 -148
  75. data/server/instances/3/properties.xml +0 -109
  76. data/server/instances/30/properties.xml +0 -150
  77. data/server/instances/31/properties.xml +0 -52
  78. data/server/instances/32/properties.xml +0 -52
  79. data/server/instances/33/properties.xml +0 -60
  80. data/server/instances/34/properties.xml +0 -148
  81. data/server/instances/35/properties.xml +0 -148
  82. data/server/instances/36/properties.xml +0 -150
  83. data/server/instances/37/notifications/5f979ed943f91ff75d75e551ba0642d6/consumer-secret +0 -1
  84. data/server/instances/37/notifications/5f979ed943f91ff75d75e551ba0642d6/producer-secret +0 -1
  85. data/server/instances/37/notifications/5f979ed943f91ff75d75e551ba0642d6/subscription.xml +0 -33
  86. data/server/instances/37/properties.xml +0 -57
  87. data/server/instances/38/properties.xml +0 -46
  88. data/server/instances/39/properties.xml +0 -58
  89. data/server/instances/4/properties.xml +0 -43
  90. data/server/instances/40/properties.xml +0 -148
  91. data/server/instances/41/properties.xml +0 -46
  92. data/server/instances/42/properties.xml +0 -148
  93. data/server/instances/43/notifications/9e7d05164a8539415d008b5bca3e0672/consumer-secret +0 -1
  94. data/server/instances/43/notifications/9e7d05164a8539415d008b5bca3e0672/producer-secret +0 -1
  95. data/server/instances/43/notifications/9e7d05164a8539415d008b5bca3e0672/subscription.xml +0 -34
  96. data/server/instances/43/properties.xml +0 -148
  97. data/server/instances/44/properties.xml +0 -148
  98. data/server/instances/45/notifications/442ed76f5da42dc9c57713840d713510/consumer-secret +0 -1
  99. data/server/instances/45/notifications/442ed76f5da42dc9c57713840d713510/producer-secret +0 -1
  100. data/server/instances/45/notifications/442ed76f5da42dc9c57713840d713510/subscription.xml +0 -34
  101. data/server/instances/45/properties.xml +0 -148
  102. data/server/instances/46/properties.xml +0 -46
  103. data/server/instances/47/notifications/63fba892899cc92fca381a666089e8d9/consumer-secret +0 -1
  104. data/server/instances/47/notifications/63fba892899cc92fca381a666089e8d9/producer-secret +0 -1
  105. data/server/instances/47/notifications/63fba892899cc92fca381a666089e8d9/subscription.xml +0 -34
  106. data/server/instances/47/notifications/e0cdacd3147aa31b0478a3ab1155db6c/consumer-secret +0 -1
  107. data/server/instances/47/notifications/e0cdacd3147aa31b0478a3ab1155db6c/producer-secret +0 -1
  108. data/server/instances/47/notifications/e0cdacd3147aa31b0478a3ab1155db6c/subscription.xml +0 -34
  109. data/server/instances/47/properties.xml +0 -148
  110. data/server/instances/5/properties.xml +0 -23
  111. data/server/instances/6/properties.xml +0 -203
  112. data/server/instances/7/properties.xml +0 -149
  113. data/server/instances/8/properties.xml +0 -145
  114. data/server/instances/9/properties.xml +0 -145
  115. data/server/server.pid +0 -1
  116. data/test/delete.rb +0 -27
  117. data/test/load.rb +0 -55
  118. data/test/testset.xml +0 -297
@@ -1,114 +0,0 @@
1
- /*
2
- This file is part of CPEE.
3
-
4
- CPEE is free software: you can redistribute it and/or modify it under the terms
5
- of the GNU General Public License as published by the Free Software Foundation,
6
- either version 3 of the License, or (at your option) any later version.
7
-
8
- CPEE is distributed in the hope that it will be useful, but WITHOUT ANY
9
- WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
10
- PARTICULAR PURPOSE. See the GNU General Public License for more details.
11
-
12
- You should have received a copy of the GNU General Public License along with
13
- CPEE (file COPYING in the main directory). If not, see
14
- <http://www.gnu.org/licenses/>.
15
- */
16
-
17
- (function($) { //{{{
18
- $.fn.dragcolumn = function() {
19
- var drag = $(this);
20
- var prev = drag.prev();
21
- var next = drag.next();
22
-
23
- this.on("mousedown", function(e) {
24
- drag.addClass('draggable');
25
- $(document).one("mouseup", function(e) {
26
- drag.removeClass('draggable');
27
- e.preventDefault();
28
- });
29
- e.preventDefault();
30
- });
31
-
32
- $(document).on("mousemove", function(e) {
33
- if (!drag.hasClass('draggable'))
34
- return;
35
-
36
- // Assume 50/50 split between prev and next then adjust to
37
- // the next X for prev
38
- var total = prev.outerWidth() + next.outerWidth();
39
- var pos = e.pageX - prev.offset().left;
40
- if (pos > total) {
41
- pos = total;
42
- }
43
-
44
- var leftPercentage = pos / total;
45
- var rightPercentage = 1 - leftPercentage;
46
-
47
- prev.css('flex', leftPercentage.toString());
48
- next.css('flex', rightPercentage.toString());
49
-
50
- e.preventDefault();
51
- });
52
- }
53
- $.fn.dragresize = function() {
54
- var drag = $(this);
55
- var prev = drag.prev();
56
- var initpos = 0;
57
- var initheight = $("ui-content",prev).height();
58
-
59
- this.on("mousedown", function(e) {
60
- drag.addClass('draggable');
61
- initpos = e.pageY;
62
- $(document).one("mouseup", function(e) {
63
- drag.removeClass('draggable');
64
- e.preventDefault();
65
- });
66
- e.preventDefault();
67
- });
68
-
69
- $(document).on("mousemove", function(e) {
70
- if (!drag.hasClass('draggable'))
71
- return;
72
-
73
- var pos = initheight - (initpos - e.pageY);
74
- if (pos < 0)
75
- return;
76
-
77
- $("ui-content",prev).css('height', pos.toString());
78
-
79
- e.preventDefault();
80
- });
81
- }
82
- })(jQuery); //}}}
83
-
84
- function ui_tab_click(moi) { // {{{
85
- var active = $(moi).attr('data-tab');
86
- var tabbed = $(moi).parents('ui-tabbed, ui-rest');
87
- var tabs = [];
88
- $("ui-tabbar ui-tab",tabbed).each(function(){
89
- if (!$(this).attr('class').match(/switch/))
90
- tabs.push($(this).attr('data-tab'));
91
- });
92
- $(".inactive",tabbed).removeClass("inactive");
93
- $.each(tabs,function(a,b){
94
- if (b != active) {
95
- $("ui-tabbar ui-tab[data-tab=" + b + "]",tabbed).addClass("inactive");
96
- $("ui-content *[data-belongs-to-tab=" + b + "]",tabbed).addClass("inactive");
97
- }
98
- });
99
- } // }}}
100
- function ui_toggle_vis_tab(moi) {// {{{
101
- var tabbed = $(moi).parents('ui-tabbed');
102
- tabbed.toggleClass('off');
103
- }// }}}
104
-
105
- $(document).ready(function() {
106
- if (!($.browser.name == "Firefox" && $.browser.version >= 20) && !($.browser.name == "Chrome" && $.browser.version >= 30)) {
107
- $('body').children().remove();
108
- $('body').append('Sorry, only Firefox >= 20.0 and Chrom(e|ium) >= 17 for now.');
109
- }
110
- $('ui-rest ui-content ui-resizehandle').dragcolumn();
111
- $('*[is=x-ui] > ui-resizehandle').dragresize();
112
- $('ui-tabbar ui-tab.switch').click(function(){ui_toggle_vis_tab(this);});
113
- $('ui-tabbar ui-tab').not('.switch').click(function(){ui_tab_click(this);});
114
- });
@@ -1,27 +0,0 @@
1
- // Underscore.js 1.1.7
2
- // (c) 2011 Jeremy Ashkenas, DocumentCloud Inc.
3
- // Underscore is freely distributable under the MIT license.
4
- // Portions of Underscore are inspired or borrowed from Prototype,
5
- // Oliver Steele's Functional, and John Resig's Micro-Templating.
6
- // For all details and documentation:
7
- // http://documentcloud.github.com/underscore
8
- (function(){var p=this,C=p._,m={},i=Array.prototype,n=Object.prototype,f=i.slice,D=i.unshift,E=n.toString,l=n.hasOwnProperty,s=i.forEach,t=i.map,u=i.reduce,v=i.reduceRight,w=i.filter,x=i.every,y=i.some,o=i.indexOf,z=i.lastIndexOf;n=Array.isArray;var F=Object.keys,q=Function.prototype.bind,b=function(a){return new j(a)};typeof module!=="undefined"&&module.exports?(module.exports=b,b._=b):p._=b;b.VERSION="1.1.7";var h=b.each=b.forEach=function(a,c,b){if(a!=null)if(s&&a.forEach===s)a.forEach(c,b);else if(a.length===
9
- +a.length)for(var e=0,k=a.length;e<k;e++){if(e in a&&c.call(b,a[e],e,a)===m)break}else for(e in a)if(l.call(a,e)&&c.call(b,a[e],e,a)===m)break};b.map=function(a,c,b){var e=[];if(a==null)return e;if(t&&a.map===t)return a.map(c,b);h(a,function(a,g,G){e[e.length]=c.call(b,a,g,G)});return e};b.reduce=b.foldl=b.inject=function(a,c,d,e){var k=d!==void 0;a==null&&(a=[]);if(u&&a.reduce===u)return e&&(c=b.bind(c,e)),k?a.reduce(c,d):a.reduce(c);h(a,function(a,b,f){k?d=c.call(e,d,a,b,f):(d=a,k=!0)});if(!k)throw new TypeError("Reduce of empty array with no initial value");
10
- return d};b.reduceRight=b.foldr=function(a,c,d,e){a==null&&(a=[]);if(v&&a.reduceRight===v)return e&&(c=b.bind(c,e)),d!==void 0?a.reduceRight(c,d):a.reduceRight(c);a=(b.isArray(a)?a.slice():b.toArray(a)).reverse();return b.reduce(a,c,d,e)};b.find=b.detect=function(a,c,b){var e;A(a,function(a,g,f){if(c.call(b,a,g,f))return e=a,!0});return e};b.filter=b.select=function(a,c,b){var e=[];if(a==null)return e;if(w&&a.filter===w)return a.filter(c,b);h(a,function(a,g,f){c.call(b,a,g,f)&&(e[e.length]=a)});return e};
11
- b.reject=function(a,c,b){var e=[];if(a==null)return e;h(a,function(a,g,f){c.call(b,a,g,f)||(e[e.length]=a)});return e};b.every=b.all=function(a,c,b){var e=!0;if(a==null)return e;if(x&&a.every===x)return a.every(c,b);h(a,function(a,g,f){if(!(e=e&&c.call(b,a,g,f)))return m});return e};var A=b.some=b.any=function(a,c,d){c=c||b.identity;var e=!1;if(a==null)return e;if(y&&a.some===y)return a.some(c,d);h(a,function(a,b,f){if(e|=c.call(d,a,b,f))return m});return!!e};b.include=b.contains=function(a,c){var b=
12
- !1;if(a==null)return b;if(o&&a.indexOf===o)return a.indexOf(c)!=-1;A(a,function(a){if(b=a===c)return!0});return b};b.invoke=function(a,c){var d=f.call(arguments,2);return b.map(a,function(a){return(c.call?c||a:a[c]).apply(a,d)})};b.pluck=function(a,c){return b.map(a,function(a){return a[c]})};b.max=function(a,c,d){if(!c&&b.isArray(a))return Math.max.apply(Math,a);var e={computed:-Infinity};h(a,function(a,b,f){b=c?c.call(d,a,b,f):a;b>=e.computed&&(e={value:a,computed:b})});return e.value};b.min=function(a,
13
- c,d){if(!c&&b.isArray(a))return Math.min.apply(Math,a);var e={computed:Infinity};h(a,function(a,b,f){b=c?c.call(d,a,b,f):a;b<e.computed&&(e={value:a,computed:b})});return e.value};b.sortBy=function(a,c,d){return b.pluck(b.map(a,function(a,b,f){return{value:a,criteria:c.call(d,a,b,f)}}).sort(function(a,b){var c=a.criteria,d=b.criteria;return c<d?-1:c>d?1:0}),"value")};b.groupBy=function(a,b){var d={};h(a,function(a,f){var g=b(a,f);(d[g]||(d[g]=[])).push(a)});return d};b.sortedIndex=function(a,c,d){d||
14
- (d=b.identity);for(var e=0,f=a.length;e<f;){var g=e+f>>1;d(a[g])<d(c)?e=g+1:f=g}return e};b.toArray=function(a){if(!a)return[];if(a.toArray)return a.toArray();if(b.isArray(a))return f.call(a);if(b.isArguments(a))return f.call(a);return b.values(a)};b.size=function(a){return b.toArray(a).length};b.first=b.head=function(a,b,d){return b!=null&&!d?f.call(a,0,b):a[0]};b.rest=b.tail=function(a,b,d){return f.call(a,b==null||d?1:b)};b.last=function(a){return a[a.length-1]};b.compact=function(a){return b.filter(a,
15
- function(a){return!!a})};b.flatten=function(a){return b.reduce(a,function(a,d){if(b.isArray(d))return a.concat(b.flatten(d));a[a.length]=d;return a},[])};b.without=function(a){return b.difference(a,f.call(arguments,1))};b.uniq=b.unique=function(a,c){return b.reduce(a,function(a,e,f){if(0==f||(c===!0?b.last(a)!=e:!b.include(a,e)))a[a.length]=e;return a},[])};b.union=function(){return b.uniq(b.flatten(arguments))};b.intersection=b.intersect=function(a){var c=f.call(arguments,1);return b.filter(b.uniq(a),
16
- function(a){return b.every(c,function(c){return b.indexOf(c,a)>=0})})};b.difference=function(a,c){return b.filter(a,function(a){return!b.include(c,a)})};b.zip=function(){for(var a=f.call(arguments),c=b.max(b.pluck(a,"length")),d=Array(c),e=0;e<c;e++)d[e]=b.pluck(a,""+e);return d};b.indexOf=function(a,c,d){if(a==null)return-1;var e;if(d)return d=b.sortedIndex(a,c),a[d]===c?d:-1;if(o&&a.indexOf===o)return a.indexOf(c);d=0;for(e=a.length;d<e;d++)if(a[d]===c)return d;return-1};b.lastIndexOf=function(a,
17
- b){if(a==null)return-1;if(z&&a.lastIndexOf===z)return a.lastIndexOf(b);for(var d=a.length;d--;)if(a[d]===b)return d;return-1};b.range=function(a,b,d){arguments.length<=1&&(b=a||0,a=0);d=arguments[2]||1;for(var e=Math.max(Math.ceil((b-a)/d),0),f=0,g=Array(e);f<e;)g[f++]=a,a+=d;return g};b.bind=function(a,b){if(a.bind===q&&q)return q.apply(a,f.call(arguments,1));var d=f.call(arguments,2);return function(){return a.apply(b,d.concat(f.call(arguments)))}};b.bindAll=function(a){var c=f.call(arguments,1);
18
- c.length==0&&(c=b.functions(a));h(c,function(c){a[c]=b.bind(a[c],a)});return a};b.memoize=function(a,c){var d={};c||(c=b.identity);return function(){var b=c.apply(this,arguments);return l.call(d,b)?d[b]:d[b]=a.apply(this,arguments)}};b.delay=function(a,b){var d=f.call(arguments,2);return setTimeout(function(){return a.apply(a,d)},b)};b.defer=function(a){return b.delay.apply(b,[a,1].concat(f.call(arguments,1)))};var B=function(a,b,d){var e;return function(){var f=this,g=arguments,h=function(){e=null;
19
- a.apply(f,g)};d&&clearTimeout(e);if(d||!e)e=setTimeout(h,b)}};b.throttle=function(a,b){return B(a,b,!1)};b.debounce=function(a,b){return B(a,b,!0)};b.once=function(a){var b=!1,d;return function(){if(b)return d;b=!0;return d=a.apply(this,arguments)}};b.wrap=function(a,b){return function(){var d=[a].concat(f.call(arguments));return b.apply(this,d)}};b.compose=function(){var a=f.call(arguments);return function(){for(var b=f.call(arguments),d=a.length-1;d>=0;d--)b=[a[d].apply(this,b)];return b[0]}};b.after=
20
- function(a,b){return function(){if(--a<1)return b.apply(this,arguments)}};b.keys=F||function(a){if(a!==Object(a))throw new TypeError("Invalid object");var b=[],d;for(d in a)l.call(a,d)&&(b[b.length]=d);return b};b.values=function(a){return b.map(a,b.identity)};b.functions=b.methods=function(a){var c=[],d;for(d in a)b.isFunction(a[d])&&c.push(d);return c.sort()};b.extend=function(a){h(f.call(arguments,1),function(b){for(var d in b)b[d]!==void 0&&(a[d]=b[d])});return a};b.defaults=function(a){h(f.call(arguments,
21
- 1),function(b){for(var d in b)a[d]==null&&(a[d]=b[d])});return a};b.clone=function(a){return b.isArray(a)?a.slice():b.extend({},a)};b.tap=function(a,b){b(a);return a};b.isEqual=function(a,c){if(a===c)return!0;var d=typeof a;if(d!=typeof c)return!1;if(a==c)return!0;if(!a&&c||a&&!c)return!1;if(a._chain)a=a._wrapped;if(c._chain)c=c._wrapped;if(a.isEqual)return a.isEqual(c);if(c.isEqual)return c.isEqual(a);if(b.isDate(a)&&b.isDate(c))return a.getTime()===c.getTime();if(b.isNaN(a)&&b.isNaN(c))return!1;
22
- if(b.isRegExp(a)&&b.isRegExp(c))return a.source===c.source&&a.global===c.global&&a.ignoreCase===c.ignoreCase&&a.multiline===c.multiline;if(d!=="object")return!1;if(a.length&&a.length!==c.length)return!1;d=b.keys(a);var e=b.keys(c);if(d.length!=e.length)return!1;for(var f in a)if(!(f in c)||!b.isEqual(a[f],c[f]))return!1;return!0};b.isEmpty=function(a){if(b.isArray(a)||b.isString(a))return a.length===0;for(var c in a)if(l.call(a,c))return!1;return!0};b.isElement=function(a){return!!(a&&a.nodeType==
23
- 1)};b.isArray=n||function(a){return E.call(a)==="[object Array]"};b.isObject=function(a){return a===Object(a)};b.isArguments=function(a){return!(!a||!l.call(a,"callee"))};b.isFunction=function(a){return!(!a||!a.constructor||!a.call||!a.apply)};b.isString=function(a){return!!(a===""||a&&a.charCodeAt&&a.substr)};b.isNumber=function(a){return!!(a===0||a&&a.toExponential&&a.toFixed)};b.isNaN=function(a){return a!==a};b.isBoolean=function(a){return a===!0||a===!1};b.isDate=function(a){return!(!a||!a.getTimezoneOffset||
24
- !a.setUTCFullYear)};b.isRegExp=function(a){return!(!a||!a.test||!a.exec||!(a.ignoreCase||a.ignoreCase===!1))};b.isNull=function(a){return a===null};b.isUndefined=function(a){return a===void 0};b.noConflict=function(){p._=C;return this};b.identity=function(a){return a};b.times=function(a,b,d){for(var e=0;e<a;e++)b.call(d,e)};b.mixin=function(a){h(b.functions(a),function(c){H(c,b[c]=a[c])})};var I=0;b.uniqueId=function(a){var b=I++;return a?a+b:b};b.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g};
25
- b.template=function(a,c){var d=b.templateSettings;d="var __p=[],print=function(){__p.push.apply(__p,arguments);};with(obj||{}){__p.push('"+a.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(d.interpolate,function(a,b){return"',"+b.replace(/\\'/g,"'")+",'"}).replace(d.evaluate||null,function(a,b){return"');"+b.replace(/\\'/g,"'").replace(/[\r\n\t]/g," ")+"__p.push('"}).replace(/\r/g,"\\r").replace(/\n/g,"\\n").replace(/\t/g,"\\t")+"');}return __p.join('');";d=new Function("obj",d);return c?d(c):d};
26
- var j=function(a){this._wrapped=a};b.prototype=j.prototype;var r=function(a,c){return c?b(a).chain():a},H=function(a,c){j.prototype[a]=function(){var a=f.call(arguments);D.call(a,this._wrapped);return r(c.apply(b,a),this._chain)}};b.mixin(b);h(["pop","push","reverse","shift","sort","splice","unshift"],function(a){var b=i[a];j.prototype[a]=function(){b.apply(this._wrapped,arguments);return r(this._wrapped,this._chain)}});h(["concat","join","slice"],function(a){var b=i[a];j.prototype[a]=function(){return r(b.apply(this._wrapped,
27
- arguments),this._chain)}});j.prototype.chain=function(){this._chain=!0;return this};j.prototype.value=function(){return this._wrapped}})();
@@ -1,58 +0,0 @@
1
- $.fn.serializeXML = function () {
2
- var out = '';
3
- if (typeof XMLSerializer == 'function') {
4
- var xs = new XMLSerializer();
5
- this.each(function() {
6
- out += xs.serializeToString(this);
7
- });
8
- } else if (this[0] && this[0].xml != 'undefined') {
9
- this.each(function() {
10
- out += this.xml;
11
- });
12
- }
13
- return out;
14
- };
15
- $.fn.serializePrettyXML = function () {
16
- var out = '';
17
- if (typeof XMLSerializer == 'function') {
18
- var xs = new XMLSerializer();
19
- var xsl = $.parseXML('<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:output omit-xml-declaration="yes" indent="yes"/><xsl:template match="node()|@*"><xsl:copy><xsl:apply-templates select="node()|@*"/></xsl:copy></xsl:template></xsl:stylesheet>');
20
- var ex;
21
- this.each(function() {
22
- if (window.ActiveXObject) {
23
- // code for IE
24
- ex = this.transformNode(xsl);
25
- } else if (document.implementation && document.implementation.createDocument) {
26
- // code for Chrome, Firefox, Opera, etc.
27
- xsltProcessor = new XSLTProcessor();
28
- xsltProcessor.importStylesheet(xsl);
29
- ex = xsltProcessor.transformToFragment(this, document);
30
- }
31
- out += xs.serializeToString(ex);
32
- console.log(out);
33
- });
34
- } else if (this[0] && this[0].xml != 'undefined') {
35
- this.each(function() {
36
- out += this.xml;
37
- });
38
- }
39
- return out;
40
- };
41
-
42
- String.prototype.repeat = function(num) {
43
- return new Array(num + 1).join(this);
44
- };
45
-
46
- String.prototype.unserialize = function() {
47
- var data = this.split("&");
48
- var ret = new Array();
49
- $.each(data, function(){
50
- var properties = this.split("=");
51
- ret.push([properties[0], properties[1]]);
52
- });
53
- return ret;
54
- };
55
-
56
- $X = function(xmlstr) {
57
- return $($.parseXML(xmlstr).documentElement);
58
- };
@@ -1,517 +0,0 @@
1
- <!--
2
- This file is part of CPEE.
3
-
4
- CPEE is free software: you can redistribute it and/or modify it under the terms
5
- of the GNU General Public License as published by the Free Software Foundation,
6
- either version 3 of the License, or (at your option) any later version.
7
-
8
- CPEE is distributed in the hope that it will be useful, but WITHOUT ANY
9
- WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
10
- PARTICULAR PURPOSE. See the GNU General Public License for more details.
11
-
12
- You should have received a copy of the GNU General Public License along with
13
- CPEE (file COPYING in the main directory). If not, see
14
- <http://www.gnu.org/licenses/>.
15
- -->
16
-
17
- <html>
18
- <head>
19
- <title>WfAdaptor Demo</title>
20
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
21
- <script type="text/javascript" src="../jquery.min.js"></script>
22
- <script type="text/javascript" src="../jquery.svgdom.js"></script>
23
- <script type="text/javascript" src="../underscore.min.js"></script>
24
- <script type="text/javascript" src="../contextmenu.js"></script>
25
- <script type="text/javascript" src="../graph.js"></script>
26
- <script type="text/javascript" src="../wfadaptor.js"></script>
27
- <script type="text/javascript" src="../../js/wfadaptor.cpee.js"></script>
28
- <link rel="stylesheet" href="../wfadaptor.css" type="text/css"/>
29
- <link rel="stylesheet" href="../contextmenu.css" type="text/css"/>
30
- <script type="text/javascript">
31
- var adaptor = null;
32
- var parser = DOMParser();
33
- function click_update_graph() {
34
- console.log("Demo: Graph Update");
35
- var then = new Date();
36
- adaptor.set_description($('#description').val());
37
- $('#t_new').text((new Date()).getTime() - then.getTime() + 'ms');
38
- then = new Date();
39
- var xml = parser.parseFromString($('#description').val(),"text/xml");
40
- var g = new WFGraph(xml,xml.documentElement, $("#canvas").get(0));
41
- var width = g.generateGraph();
42
- $('#t_old').text((new Date()).getTime() - then.getTime() + 'ms');
43
- }
44
- function update_event(element_id, operation) {
45
- console.log("Demo: update notification [ID: "+element_id+ ", OP: "+operation+"]");
46
- }
47
- </script>
48
- </head>
49
- <body>
50
- <table style="background: ThreeDShadow; width: 100%; height: 100%;" border="0">
51
- <tr>
52
- <td style="text-align:center; vertical-align:middle"><button type="button" onclick="click_update_graph();">Update Graph &gt;&gt;&gt; </button></td>
53
- <td style="text-align:center; vertical-align:middle" colspan="2"><b><font size="+2">Workflow Graph</font></b></td>
54
- </tr>
55
- <tr height="95%">
56
- <td width="40%" style="vertical-align:middle; text-align:center"><!-- {{{ -->
57
- <textarea style="width:98%;height:98%" id="description">
58
- <description xmlns="http://cpee.org/ns/description/1.0">
59
- <call/><!--{{{-->
60
- <call/>
61
- <call/>
62
-
63
- <!-- Parallel {{{ -->
64
- <parallel>
65
- <parallel_branch>
66
- <call/>
67
- <call/>
68
- </parallel_branch>
69
- <parallel_branch>
70
- <call/>
71
- <call/>
72
- </parallel_branch>
73
- </parallel>
74
-
75
- <parallel>
76
- <parallel_branch>
77
- <call/>
78
- <choose>
79
- <alternative>
80
- <call/>
81
- </alternative>
82
- <otherwise>
83
- <call/>
84
- </otherwise>
85
- <alternative>
86
- <call/>
87
- </alternative>
88
- </choose>
89
- </parallel_branch>
90
- <parallel_branch>
91
- <choose>
92
- <alternative>
93
- <call/>
94
- </alternative>
95
- <otherwise>
96
- <call/>
97
- </otherwise>
98
- <alternative>
99
- <call/>
100
- </alternative>
101
- </choose>
102
- <call/>
103
- </parallel_branch>
104
- </parallel>
105
-
106
- <parallel>
107
- <parallel_branch>
108
- <call/>
109
- <parallel>
110
- <parallel_branch>
111
- <call/>
112
- </parallel_branch>
113
- <parallel_branch>
114
- <call/>
115
- <call/>
116
- <call/>
117
- </parallel_branch>
118
- </parallel>
119
- </parallel_branch>
120
- <parallel_branch>
121
- <parallel>
122
- <parallel_branch>
123
- <call/>
124
- </parallel_branch>
125
- <parallel_branch>
126
- <call/>
127
- <call/>
128
- <call/>
129
- </parallel_branch>
130
- </parallel>
131
- <call/>
132
- </parallel_branch>
133
- </parallel>
134
-
135
- <parallel>
136
- <parallel_branch>
137
- <call/>
138
- <loop>
139
- <call/>
140
- <call/>
141
- <call/>
142
- </loop>
143
- </parallel_branch>
144
- <parallel_branch>
145
- <loop>
146
- <call/>
147
- <call/>
148
- <call/>
149
- </loop>
150
- <call/>
151
- </parallel_branch>
152
- </parallel>
153
-
154
- <parallel>
155
- <loop>
156
- <call/>
157
- <parallel_branch>
158
- <call/>
159
- </parallel_branch>
160
- </loop>
161
- </parallel>
162
-
163
- <parallel>
164
- <loop>
165
- <parallel_branch>
166
- <call/>
167
- </parallel_branch>
168
- <call/>
169
- </loop>
170
- </parallel>
171
-
172
- <parallel>
173
- <loop>
174
- <parallel_branch>
175
- <call/>
176
- </parallel_branch>
177
- </loop>
178
- </parallel>
179
-
180
- <parallel>
181
- <parallel_branch>
182
- <call/>
183
- <critical>
184
- <call/>
185
- <call/>
186
- <call/>
187
- </critical>
188
- </parallel_branch>
189
- <parallel_branch>
190
- <critical>
191
- <call/>
192
- </critical>
193
- <call/>
194
- </parallel_branch>
195
- </parallel>
196
- <!-- Parallel }}} -->
197
- <!-- Choose {{{ -->
198
- <choose>
199
- <alternative>
200
- <call/>
201
- </alternative>
202
- <otherwise>
203
- <call/>
204
- </otherwise>
205
- <alternative>
206
- <call/>
207
- </alternative>
208
- </choose>
209
-
210
- <choose>
211
- <alternative>
212
- <call/>
213
- <choose>
214
- <alternative>
215
- <call/>
216
- </alternative>
217
- <otherwise>
218
- <call/>
219
- </otherwise>
220
- </choose>
221
- </alternative>
222
- <otherwise>
223
- <choose>
224
- <alternative>
225
- <call/>
226
- </alternative>
227
- <otherwise>
228
- <call/>
229
- </otherwise>
230
- </choose>
231
- <call/>
232
- </otherwise>
233
- <alternative>
234
- <call/>
235
- </alternative>
236
- </choose>
237
-
238
- <choose>
239
- <alternative>
240
- <call/>
241
- <loop>
242
- <call/>
243
- <call/>
244
- </loop>
245
- </alternative>
246
- <otherwise>
247
- <loop>
248
- <call/>
249
- <call/>
250
- </loop>
251
- <call/>
252
- </otherwise>
253
- <alternative>
254
- <call/>
255
- </alternative>
256
- </choose>
257
-
258
- <choose>
259
- <alternative>
260
- <call/>
261
- <parallel>
262
- <parallel_branch>
263
- <call/>
264
- </parallel_branch>
265
- <parallel_branch>
266
- <call/>
267
- </parallel_branch>
268
- </parallel>
269
- </alternative>
270
- <otherwise>
271
- <parallel>
272
- <parallel_branch>
273
- <call/>
274
- </parallel_branch>
275
- <parallel_branch>
276
- <call/>
277
- </parallel_branch>
278
- </parallel>
279
- <call/>
280
- </otherwise>
281
- <alternative>
282
- <call/>
283
- </alternative>
284
- </choose>
285
-
286
- <choose>
287
- <alternative>
288
- <call/>
289
- <critical>
290
- <call/>
291
- <call/>
292
- </critical>
293
- </alternative>
294
- <otherwise>
295
- <critical>
296
- <call/>
297
- <call/>
298
- </critical>
299
- <call/>
300
- </otherwise>
301
- <alternative>
302
- <call/>
303
- </alternative>
304
- </choose>
305
-
306
-
307
- <!-- Choose }}} -->
308
- <!-- loop {{{ -->
309
- <loop>
310
- <call/>
311
- <call/>
312
- </loop>
313
- <loop>
314
- <call/>
315
- <choose>
316
- <alternative>
317
- <call/>
318
- <choose>
319
- <alternative>
320
- <call/>
321
- </alternative>
322
- <otherwise>
323
- <call/>
324
- </otherwise>
325
- </choose>
326
- </alternative>
327
- <otherwise>
328
- <choose>
329
- <alternative>
330
- <call/>
331
- </alternative>
332
- <otherwise>
333
- <call/>
334
- </otherwise>
335
- </choose>
336
- <call/>
337
- </otherwise>
338
- </choose>
339
- </loop>
340
- <loop>
341
- <loop>
342
- <call/>
343
- <call/>
344
- </loop>
345
- </loop>
346
- <loop>
347
- <parallel>
348
- <parallel_branch>
349
- <call/>
350
- </parallel_branch>
351
- <parallel_branch>
352
- <call/>
353
- </parallel_branch>
354
- </parallel>
355
- </loop>
356
- <loop>
357
- <critical>
358
- <call/>
359
- <call/>
360
- </critical>
361
- </loop>
362
- <!-- loop }}} -->
363
- <!-- Critical {{{ -->
364
- <critical>
365
- <call/>
366
- <call/>
367
- </critical>
368
- <critical>
369
- <critical>
370
- <call/>
371
- <call/>
372
- </critical>
373
- </critical>
374
- <critical>
375
- <call/>
376
- <choose>
377
- <alternative>
378
- <call/>
379
- <choose>
380
- <alternative>
381
- <call/>
382
- </alternative>
383
- <otherwise>
384
- <call/>
385
- </otherwise>
386
- </choose>
387
- </alternative>
388
- <otherwise>
389
- <choose>
390
- <alternative>
391
- <call/>
392
- </alternative>
393
- <otherwise>
394
- <call/>
395
- </otherwise>
396
- </choose>
397
- <call/>
398
- </otherwise>
399
- </choose>
400
- </critical>
401
- <critical>
402
- <loop>
403
- <call/>
404
- <call/>
405
- <call/>
406
- </loop>
407
- </critical>
408
- <critical>
409
- <call/>
410
- <parallel>
411
- <parallel_branch>
412
- <call/>
413
- </parallel_branch>
414
- <parallel_branch>
415
- <call/>
416
- </parallel_branch>
417
- </parallel>
418
- </critical>
419
- <!-- Critical }}} -->
420
-
421
- <call/><!--}}}-->
422
- </description>
423
- </textarea>
424
- </td><!-- }}} -->
425
- <td style="vertical-align: top"><!-- {{{ -->
426
- <h3>New Graph Version -> Built-Time:<span id="t_new">00</span></h3>
427
- <svg xmlns="http://www.w3.org/2000/svg" version="1.1" height="600" width="300" xmlns:xlink="http://www.w3.org/1999/xlink" id="drawing_area">
428
- </svg>
429
- </td><!-- }}} -->
430
- <td style="vertical-align: top"><!-- {{{ -->
431
- <h3>Old Graph Version -> Built-Time:<span id="t_old">00</span></h3>
432
- <svg xmlns="http://www.w3.org/2000/svg" version="1.1" height="600" width="300" xmlns:xlink="http://www.w3.org/1999/xlink">
433
- <defs><!-- {{{ -->
434
- <symbol id="call" class="clickable"><!-- {{{ -->
435
- <circle cx="15" cy="15" r="14" class="stand"></circle>
436
- <text class="normal" transform='translate(15,21)'>c</text>
437
- </symbol><!-- }}} -->
438
- <symbol id="manipulate" class="clickable"><!-- {{{ -->
439
- <circle cx="15" cy="15" r="14" class="stand"></circle>
440
- <text class="normal" transform='translate(15,21)'>m</text>
441
- </symbol><!-- }}} -->
442
- <symbol id="callinject" class="clickable"><!-- {{{ -->
443
- <circle cx="15" cy="15" r="14" class="stand"></circle>
444
- <text class="normal" transform='translate(15,21)'>c</text>
445
- <circle cx="28" cy="27" r="9" class="stand"></circle>
446
- <text class="small" transform='translate(28,32)'>i</text>
447
- </symbol><!-- }}} -->
448
- <symbol id="callmanipulate" class="clickable"><!-- {{{ -->
449
- <circle cx="15" cy="15" r="14" class="stand"></circle>
450
- <text class="normal" transform='translate(15,21)'>c</text>
451
- <circle cx="28" cy="28" r="9" class="stand"></circle>
452
- <text class="small" transform='translate(28,32)'>m</text>
453
- </symbol><!-- }}} -->
454
- <symbol id="choose" class="clickable"><!-- {{{ -->
455
- <circle cx="15" cy="15" r="14" class="stand"></circle>
456
- <text class="normal" transform='translate(15,21)'>σ</text>
457
- </symbol><!-- }}} -->
458
- <symbol id="alternative" class="clickable"><!-- {{{ -->
459
- <circle cx="15" cy="15" r="14" class="standwithout"></circle>
460
- <text class="normal" transform='translate(15,20)'>{..}</text>
461
- </symbol><!-- }}} -->
462
- <symbol id="otherwise" class="clickable"><!-- {{{ -->
463
- <circle cx="15" cy="15" r="14" class="standwithout"></circle>
464
- <text class="normal" transform='translate(15,20)'>{⁎}</text>
465
- </symbol><!-- }}} -->
466
- <symbol id="parallel" class="clickable"><!-- {{{ -->
467
- <circle cx="15" cy="15" r="14" class="stand"></circle>
468
- <text class="normal" transform='translate(15,21)'>||</text>
469
- </symbol><!-- }}} -->
470
- <symbol id="parallel_branch" class="clickable"><!-- {{{ -->
471
- <circle cx="15" cy="15" r="14" class="stand"></circle>
472
- <text class="normal" transform='translate(15,21)'>|</text>
473
- </symbol><!-- }}} -->
474
- <symbol id="critical" class="clickable"><!-- {{{ -->
475
- <circle cx="15" cy="15" r="14" class="stand"></circle>
476
- <text class="normal" transform='translate(16.5,21.5)'>⚠</text>
477
- </symbol><!-- }}} -->
478
- <symbol id="loop" class="clickable"><!-- {{{ -->
479
- <circle cx="15" cy="15" r="14" class="stand"></circle>
480
- <text class="normallarge" transform='translate(15,23)'>↺</text>
481
- </symbol><!-- }}} -->
482
- <symbol id="end"><!-- {{{ -->
483
- <circle cx="15" cy="15" r="14" class="stand"></circle>
484
- <circle cx="15" cy="15" r="11" class="stand"></circle>
485
- <text class="normal" transform='translate(15,21)'>Ω</text>
486
- </symbol><!-- }}} -->
487
- <marker id="arrow" viewBox="0 0 10 10" refX="24" refY="5" orient="auto" markerUnits="strokeWidth" markerWidth="4.5" markerHeight="4.5">
488
- <path d="m 2 2 l 6 3 l -6 3 z"></path>
489
- </marker>
490
- </defs><!-- }}} -->
491
- <g id="canvas">
492
- <g id="blocks"></g>
493
- <g id="lines"></g>
494
- <g id="symbols"></g>
495
- </g>
496
- </svg>
497
- </td><!-- }}} -->
498
- </tr>
499
- </table>
500
- <script type="text/javascript">
501
- var then = new Date();
502
- adaptor = new WfAdaptor();
503
- create_cpee_elements(adaptor);
504
- adaptor.set_svg_container($('#drawing_area'));
505
- adaptor.set_description($('#description').val(), true);
506
-
507
- $('#t_new').text((new Date()).getTime() - then.getTime() + 'ms');
508
- adaptor.notify = update_event;
509
- then = new Date();
510
- var xml = parser.parseFromString($('#description').val(),"text/xml");
511
- var g = new WFGraph(xml,xml.documentElement, $("#canvas").get(0));
512
- var width = g.generateGraph();
513
- $('#t_old').text((new Date()).getTime() - then.getTime() + 'ms');
514
- //console.log(adaptor.get_description());
515
- </script>
516
- </body>
517
- </html>