bpmn-moddle 7.0.4 → 7.1.2
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.
- package/CHANGELOG.md +17 -0
- package/README.md +1 -1
- package/dist/bpmn-moddle.umd.js +78 -27
- package/dist/bpmn-moddle.umd.prod.js +1 -1
- package/dist/index.esm.js +66 -2
- package/dist/index.js +66 -2
- package/package.json +19 -13
- package/resources/bpmn/json/bpmn.json +2 -1
- package/tasks/generate-schema.js +0 -86
- package/tasks/transforms/helper.js +0 -513
- package/tasks/transforms/index.js +0 -11
- package/tasks/transforms/transformBPMN.js +0 -371
- package/tasks/transforms/transformBPMNDI.js +0 -16
- package/tasks/transforms/transformDC.js +0 -10
- package/tasks/transforms/transformDI.js +0 -63
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,23 @@ All notable changes to [bpmn-moddle](https://github.com/bpmn-io/bpmn-moddle) are
|
|
|
6
6
|
|
|
7
7
|
___Note:__ Yet to be released changes appear here._
|
|
8
8
|
|
|
9
|
+
## 7.1.2
|
|
10
|
+
|
|
11
|
+
* `FIX`: make `bpmn:InteractionNode` include `bpmn:CallActivity`
|
|
12
|
+
|
|
13
|
+
## 7.1.1
|
|
14
|
+
|
|
15
|
+
* `FIX`: properly inline BPMN in Color schema ([#88](https://github.com/bpmn-io/bpmn-moddle/pull/88))
|
|
16
|
+
|
|
17
|
+
## 7.1.0
|
|
18
|
+
|
|
19
|
+
* `FEAT`: add BPMN in Color schema ([#87](https://github.com/bpmn-io/bpmn-moddle/pull/87))
|
|
20
|
+
* `CHORE`: update dependencies
|
|
21
|
+
|
|
22
|
+
## 7.0.5
|
|
23
|
+
|
|
24
|
+
* `FIX`: correct serialization of `xml` prefixed attributes on `Any` elements
|
|
25
|
+
* `CHORE`: update to `moddle-xml@9.0.5`
|
|
9
26
|
|
|
10
27
|
## 7.0.4
|
|
11
28
|
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# bpmn-moddle
|
|
2
2
|
|
|
3
|
-
[](https://github.com/bpmn-io/bpmn-moddle/actions?query=workflow%3ACI)
|
|
4
4
|
|
|
5
5
|
Read and write BPMN 2.0 diagram files in NodeJS and the browser.
|
|
6
6
|
|
package/dist/bpmn-moddle.umd.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
2
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
3
3
|
typeof define === 'function' && define.amd ? define(factory) :
|
|
4
|
-
(global = global || self, global.BpmnModdle = factory());
|
|
5
|
-
}(this, function () { 'use strict';
|
|
4
|
+
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.BpmnModdle = factory());
|
|
5
|
+
}(this, (function () { 'use strict';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Flatten array, one level deep.
|
|
@@ -111,23 +111,6 @@
|
|
|
111
111
|
}
|
|
112
112
|
}
|
|
113
113
|
}
|
|
114
|
-
/**
|
|
115
|
-
* Transform a collection into another collection
|
|
116
|
-
* by piping each member through the given fn.
|
|
117
|
-
*
|
|
118
|
-
* @param {Object|Array} collection
|
|
119
|
-
* @param {Function} fn
|
|
120
|
-
*
|
|
121
|
-
* @return {Array} transformed collection
|
|
122
|
-
*/
|
|
123
|
-
|
|
124
|
-
function map(collection, fn) {
|
|
125
|
-
var result = [];
|
|
126
|
-
forEach(collection, function (val, key) {
|
|
127
|
-
result.push(fn(val, key));
|
|
128
|
-
});
|
|
129
|
-
return result;
|
|
130
|
-
}
|
|
131
114
|
|
|
132
115
|
function toMatcher(matcher) {
|
|
133
116
|
return isFunction(matcher) ? matcher : function (e) {
|
|
@@ -295,7 +278,7 @@
|
|
|
295
278
|
String: function(s) { return s; },
|
|
296
279
|
Boolean: function(s) { return s === 'true'; },
|
|
297
280
|
Integer: function(s) { return parseInt(s, 10); },
|
|
298
|
-
Real: function(s) { return parseFloat(s
|
|
281
|
+
Real: function(s) { return parseFloat(s); }
|
|
299
282
|
};
|
|
300
283
|
|
|
301
284
|
/**
|
|
@@ -1033,6 +1016,7 @@
|
|
|
1033
1016
|
this.properties.defineDescriptor(element, descriptor);
|
|
1034
1017
|
this.properties.defineModel(element, this);
|
|
1035
1018
|
this.properties.define(element, '$parent', { enumerable: false, writable: true });
|
|
1019
|
+
this.properties.define(element, '$instanceOf', { enumerable: false, writable: true });
|
|
1036
1020
|
|
|
1037
1021
|
forEach(properties, function(a, key) {
|
|
1038
1022
|
if (isObject(a) && a.value !== undefined) {
|
|
@@ -3005,9 +2989,8 @@
|
|
|
3005
2989
|
|
|
3006
2990
|
// strip whitespace only nodes, i.e. before
|
|
3007
2991
|
// <!CDATA[ ... ]> sections and in between tags
|
|
3008
|
-
text = text.trim();
|
|
3009
2992
|
|
|
3010
|
-
if (!text) {
|
|
2993
|
+
if (!text.trim()) {
|
|
3011
2994
|
return;
|
|
3012
2995
|
}
|
|
3013
2996
|
|
|
@@ -3225,7 +3208,11 @@
|
|
|
3225
3208
|
|
|
3226
3209
|
function getNsAttrs(namespaces) {
|
|
3227
3210
|
|
|
3228
|
-
return
|
|
3211
|
+
return namespaces.getUsed().filter(function(ns) {
|
|
3212
|
+
|
|
3213
|
+
// do not serialize built in <xml> namespace
|
|
3214
|
+
return ns.prefix !== 'xml';
|
|
3215
|
+
}).map(function(ns) {
|
|
3229
3216
|
var name = 'xmlns' + (ns.prefix ? ':' + ns.prefix : '');
|
|
3230
3217
|
return { name: name, value: ns.uri };
|
|
3231
3218
|
});
|
|
@@ -3676,7 +3663,7 @@
|
|
|
3676
3663
|
|
|
3677
3664
|
var existing = namespaces.byUri(nsUri);
|
|
3678
3665
|
|
|
3679
|
-
if (
|
|
3666
|
+
if (!existing || local) {
|
|
3680
3667
|
namespaces.add(ns, wellknown);
|
|
3681
3668
|
}
|
|
3682
3669
|
|
|
@@ -6518,7 +6505,8 @@
|
|
|
6518
6505
|
{
|
|
6519
6506
|
name: "CallActivity",
|
|
6520
6507
|
superClass: [
|
|
6521
|
-
"Activity"
|
|
6508
|
+
"Activity",
|
|
6509
|
+
"InteractionNode"
|
|
6522
6510
|
],
|
|
6523
6511
|
properties: [
|
|
6524
6512
|
{
|
|
@@ -7613,12 +7601,75 @@
|
|
|
7613
7601
|
associations: associations$4
|
|
7614
7602
|
};
|
|
7615
7603
|
|
|
7604
|
+
var name$5 = "BPMN in Color";
|
|
7605
|
+
var uri$5 = "http://www.omg.org/spec/BPMN/non-normative/color/1.0";
|
|
7606
|
+
var prefix$5 = "color";
|
|
7607
|
+
var types$5 = [
|
|
7608
|
+
{
|
|
7609
|
+
name: "ColoredLabel",
|
|
7610
|
+
"extends": [
|
|
7611
|
+
"bpmndi:BPMNLabel"
|
|
7612
|
+
],
|
|
7613
|
+
properties: [
|
|
7614
|
+
{
|
|
7615
|
+
name: "color",
|
|
7616
|
+
isAttr: true,
|
|
7617
|
+
type: "String"
|
|
7618
|
+
}
|
|
7619
|
+
]
|
|
7620
|
+
},
|
|
7621
|
+
{
|
|
7622
|
+
name: "ColoredShape",
|
|
7623
|
+
"extends": [
|
|
7624
|
+
"bpmndi:BPMNShape"
|
|
7625
|
+
],
|
|
7626
|
+
properties: [
|
|
7627
|
+
{
|
|
7628
|
+
name: "background-color",
|
|
7629
|
+
isAttr: true,
|
|
7630
|
+
type: "String"
|
|
7631
|
+
},
|
|
7632
|
+
{
|
|
7633
|
+
name: "border-color",
|
|
7634
|
+
isAttr: true,
|
|
7635
|
+
type: "String"
|
|
7636
|
+
}
|
|
7637
|
+
]
|
|
7638
|
+
},
|
|
7639
|
+
{
|
|
7640
|
+
name: "ColoredEdge",
|
|
7641
|
+
"extends": [
|
|
7642
|
+
"bpmndi:BPMNEdge"
|
|
7643
|
+
],
|
|
7644
|
+
properties: [
|
|
7645
|
+
{
|
|
7646
|
+
name: "border-color",
|
|
7647
|
+
isAttr: true,
|
|
7648
|
+
type: "String"
|
|
7649
|
+
}
|
|
7650
|
+
]
|
|
7651
|
+
}
|
|
7652
|
+
];
|
|
7653
|
+
var enumerations$3 = [
|
|
7654
|
+
];
|
|
7655
|
+
var associations$5 = [
|
|
7656
|
+
];
|
|
7657
|
+
var BpmnInColorPackage = {
|
|
7658
|
+
name: name$5,
|
|
7659
|
+
uri: uri$5,
|
|
7660
|
+
prefix: prefix$5,
|
|
7661
|
+
types: types$5,
|
|
7662
|
+
enumerations: enumerations$3,
|
|
7663
|
+
associations: associations$5
|
|
7664
|
+
};
|
|
7665
|
+
|
|
7616
7666
|
var packages = {
|
|
7617
7667
|
bpmn: BpmnPackage,
|
|
7618
7668
|
bpmndi: BpmnDiPackage,
|
|
7619
7669
|
dc: DcPackage,
|
|
7620
7670
|
di: DiPackage,
|
|
7621
|
-
bioc: BiocPackage
|
|
7671
|
+
bioc: BiocPackage,
|
|
7672
|
+
color: BpmnInColorPackage
|
|
7622
7673
|
};
|
|
7623
7674
|
|
|
7624
7675
|
function simple(additionalPackages, options) {
|
|
@@ -7629,4 +7680,4 @@
|
|
|
7629
7680
|
|
|
7630
7681
|
return simple;
|
|
7631
7682
|
|
|
7632
|
-
}));
|
|
7683
|
+
})));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).BpmnModdle=t()}(this,function(){"use strict";var e=Object.prototype.toString,t=Object.prototype.hasOwnProperty;function n(t){return"[object String]"===e.call(t)}function i(e,n){return t.call(e,n)}function r(t,n){var i;return n=function(t){return n=t,i=e.call(n),"[object Function]"===i||"[object AsyncFunction]"===i||"[object GeneratorFunction]"===i||"[object AsyncGeneratorFunction]"===i||"[object Proxy]"===i?t:function(e){return e===t};var n,i}(n),s(t,function(e,t){if(n(e,t))return i=e,!1}),i}function a(e,t){var n=[];return s(e,function(e,i){t(e,i)&&n.push(e)}),n}function s(t,n){var r;if(void 0!==t){var a=function(t){return"[object Array]"===e.call(t)}(t)?p:o;for(var s in t)if(i(t,s)&&!1===n(r=t[s],a(s)))return r}}function o(e){return e}function p(e){return Number(e)}function m(e,t){return e.bind(t)}function l(){return(l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e}).apply(this,arguments)}function u(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return l.apply(void 0,[e].concat(n))}function c(){}function y(e,t){this.model=e,this.properties=t}c.prototype.get=function(e){return this.$model.properties.get(this,e)},c.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},y.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(c.prototype);s(e.properties,function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)}),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function a(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),s(e,m(function(e,t){this.set(t,e)},this))}return a.prototype=i,a.hasType=i.$instanceOf=this.model.hasType,n.defineModel(a,t),n.defineDescriptor(a,e),a};var f={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},d={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e,10)}};function h(e,t){var n=d[e];return n?n(t):t}function g(e){return!!f[e]}function A(e){return!!d[e]}function E(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function v(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function R(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,s(e,m(this.registerPackage,this))}function b(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function C(e){this.model=e}function x(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function w(e){this.properties=new C(this),this.factory=new y(this,this.properties),this.registry=new R(e,this.properties),this.typeCache={}}v.prototype.build=function(){return e=this,t=["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"],n={},i=Object(e),s(t,function(t){t in i&&(n[t]=e[t])}),n;var e,t,n,i},v.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},v.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,a=this.propertiesByName,s=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var o=r.indexOf(e);if(-1===o)throw new Error("property <"+i.name+"> not found in property list");r.splice(o,1),this.addProperty(t,n?void 0:o,s),a[i.name]=a[i.localName]=t},v.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),a=E(r[0],i),s=E(r[1],a.prefix).name,o=this.propertiesByName[s];if(!o)throw new Error("refined property <"+s+"> not found");this.replaceProperty(o,e,n),delete e.redefines},v.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},v.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},v.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},v.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},v.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},v.prototype.hasProperty=function(e){return this.propertiesByName[e]},v.prototype.addTrait=function(e,t){var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(s(e.properties,m(function(n){n=u({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))},this)),i.push(e),n[r]=e)},R.prototype.getPackage=function(e){return this.packageMap[e]},R.prototype.getPackages=function(){return this.packages},R.prototype.registerPackage=function(e){e=u({},e);var t=this.packageMap;b(t,e,"prefix"),b(t,e,"uri"),s(e.types,m(function(t){this.registerType(t,e)},this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},R.prototype.registerType=function(e,t){var n=E((e=u({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:u(e.meta||{})})).name,t.prefix),i=n.name,r={};s(e.properties,m(function(e){var t=E(e.name,n.prefix),i=t.name;g(e.type)||(e.type=E(e.type,t.prefix).name),u(e,{ns:t,name:i}),r[i]=e},this)),u(e,{ns:n,name:i,propertiesByName:r}),s(e.extends,m(function(e){var t=this.typeMap[e];t.traits=t.traits||[],t.traits.push(i)},this)),this.definePackage(e,t),this.typeMap[i]=e},R.prototype.mapTypes=function(e,t,n){var i=g(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function a(e){return o(e,!0)}function o(n,i){var a=E(n,g(n)?"":e.prefix);r.mapTypes(a,t,i)}if(!i)throw new Error("unknown type <"+e.name+">");s(i.superClass,n?a:o),t(i,!n),s(i.traits,a)},R.prototype.getEffectiveDescriptor=function(e){var t=E(e),n=new v(t);this.mapTypes(t,function(e,t){n.addTrait(e,t)});var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},R.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},C.prototype.set=function(e,t,n){var i=this.model.getPropertyDescriptor(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[t]:i?r in e?e[r]=n:x(e,i,n):e.$attrs[t]=n},C.prototype.get=function(e,t){var n=this.model.getPropertyDescriptor(e,t);if(!n)return e.$attrs[t];var i=n.name;return!e[i]&&n.isMany&&x(e,n,[]),e[i]},C.prototype.define=function(e,t,n){Object.defineProperty(e,t,n)},C.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},C.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},w.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},w.prototype.getType=function(e){var t=this.typeCache,i=n(e)?e:e.ns.name,r=t[i];return r||(e=this.registry.getEffectiveDescriptor(i),r=t[i]=this.factory.createType(e)),r},w.prototype.createAny=function(t,n,i){var r=E(t),a={$type:t,$instanceOf:function(e){return e===this.$type}},o={name:t,isGeneric:!0,ns:{prefix:r.prefix,localName:r.localName,uri:n}};return this.properties.defineDescriptor(a,o),this.properties.defineModel(a,this),this.properties.define(a,"$parent",{enumerable:!1,writable:!0}),s(i,function(t,n){var i;i=t,"[object Object]"===e.call(i)&&void 0!==t.value?a[t.name]=t.value:a[n]=t}),a},w.prototype.getPackage=function(e){return this.registry.getPackage(e)},w.prototype.getPackages=function(){return this.registry.getPackages()},w.prototype.getElementDescriptor=function(e){return e.$descriptor},w.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},w.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},w.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var M=String.fromCharCode,N=Object.prototype.hasOwnProperty,S=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,P={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function B(e,t,n,i){return i?N.call(P,i)?P[i]:"&"+i+";":M(t||parseInt(n,16))}function D(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(S,B):e}Object.keys(P).forEach(function(e){P[e.toUpperCase()]=P[e]});var I="http://www.w3.org/2001/XMLSchema-instance",O="xsi",T="xsi:type",k="non-whitespace outside of root node";function F(e){return new Error(e)}function L(e){return"missing namespace for prefix <"+e+">"}function V(e){return{get:e,enumerable:!0}}function j(e){var t,n={};for(t in e)n[t]=e[t];return n}function $(e){return e+"$uri"}function z(){return{line:0,column:0}}function G(e){throw e}function U(e){if(!this)return new U(e);var t,n,i,r,a,s,o,p,m,l=e&&e.proxy,u=G,c=z,y=!1,f=!1,d=null,h=!1;function g(e){e instanceof Error||(e=F(e)),d=e,u(e,c)}function A(e){a&&(e instanceof Error||(e=F(e)),a(e,c))}this.on=function(e,m){if("function"!=typeof m)throw F("required args <name, cb>");switch(e){case"openTag":n=m;break;case"text":t=m;break;case"closeTag":i=m;break;case"error":u=m;break;case"warn":a=m;break;case"cdata":r=m;break;case"attention":p=m;break;case"question":o=m;break;case"comment":s=m;break;default:throw F("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw F("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return n[I]=O,f=!0,m=n,this},this.parse=function(e){if("string"!=typeof e)throw F("required args <xml=string>");return d=null,function(e){var a,u,d,E,v,R,b,C,x,w,M,N=f?[]:null,S=f?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[$(n)]=t;return i}(m):null,P=[],B=0,I=!1,O=!1,F=0,z=0,G="",U=0;function q(){if(null!==M)return M;var e,t,n,i,r,a,s,o,p,l,u,c=f&&S.xmlns,d=f&&y?[]:null,h=U,g=G,E=g.length,v={},R={};e:for(;h<E;h++)if(p=!1,!(32===(l=g.charCodeAt(h))||l<14&&l>8)){for((l<65||l>122||l>90&&l<97)&&95!==l&&58!==l&&(A("illegal first char attribute name"),p=!0),u=h+1;u<E;u++)if(!((l=g.charCodeAt(u))>96&&l<123||l>64&&l<91||l>47&&l<59||46===l||45===l||95===l)){if(32===l||l<14&&l>8){A("missing attribute value"),h=u;continue e}if(61===l)break;A("illegal attribute name char"),p=!0}if("xmlns:xmlns"===(o=g.substring(h,u))&&(A("illegal declaration of xmlns"),p=!0),34===(l=g.charCodeAt(u+1)))-1===(u=g.indexOf('"',h=u+2))&&-1!==(u=g.indexOf("'",h))&&(A("attribute value quote missmatch"),p=!0);else if(39===l)-1===(u=g.indexOf("'",h=u+2))&&-1!==(u=g.indexOf('"',h))&&(A("attribute value quote missmatch"),p=!0);else for(A("missing attribute value quotes"),p=!0,u+=1;u<E&&!(32===(l=g.charCodeAt(u+1))||l<14&&l>8);u++);for(-1===u&&(A("missing closing quotes"),u=E,p=!0),p||(a=g.substring(h,u)),h=u;u+1<E&&!(32===(l=g.charCodeAt(u+1))||l<14&&l>8);u++)h===u&&(A("illegal character after attribute end"),p=!0);if(h=u+1,!p)if(o in R)A("attribute <"+o+"> already defined");else if(R[o]=!0,f)if(y){if(null!==(r="xmlns"===o?"xmlns":120===o.charCodeAt(0)&&"xmlns:"===o.substr(0,6)?o.substr(6):null)){if(e=D(a),t=$(r),!(s=m[e])){if("xmlns"===r||t in S&&S[t]!==e)do{s="ns"+B++}while(void 0!==S[s]);else s=r;m[e]=s}S[r]!==s&&(i||(S=j(S),i=!0),S[r]=s,"xmlns"===r&&(S[$(s)]=e,c=s),S[t]=e),v[o]=a;continue}d.push(o,a)}else-1!==(l=o.indexOf(":"))?(n=S[o.substring(0,l)])?((o=c===n?o.substr(l+1):n+o.substr(l))===T&&(-1!==(l=a.indexOf(":"))?(n=a.substring(0,l),n=S[n]||n,a=n+a.substring(l)):a=c+":"+a),v[o]=a):A(L(o.substring(0,l))):v[o]=a;else v[o]=a}if(y)for(h=0,E=d.length;h<E;h++){if(o=d[h++],a=d[h],-1!==(l=o.indexOf(":"))){if(!(n=S[o.substring(0,l)])){A(L(o.substring(0,l)));continue}(o=c===n?o.substr(l+1):n+o.substr(l))===T&&(-1!==(l=a.indexOf(":"))?(n=a.substring(0,l),n=S[n]||n,a=n+a.substring(l)):a=c+":"+a)}v[o]=a}return M=v}c=function(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,a=0,s=0,o=z;F>=s&&(t=i.exec(e))&&!((o=t[0].length+t.index)>F);)r+=1,s=o;return-1==F?(a=o,n=e.substring(z)):0===z?n=e.substring(z,F):(a=F-s,n=-1==z?e.substring(F):e.substring(F,z+1)),{data:n,line:r,column:a}},l&&(w=Object.create({},{name:V(function(){return C}),originalName:V(function(){return x}),attrs:V(q),ns:V(function(){return S})}));for(;-1!==z;){if(-1===(F=60===e.charCodeAt(z)?z:e.indexOf("<",z)))return P.length?g("unexpected end of file"):0===z?g("missing start tag"):void(z<e.length&&e.substring(z).trim()&&A(k));if(z!==F)if(P.length){if(t&&(t(e.substring(z,F),D,c),h))return}else if(e.substring(z,F).trim()&&(A(k),h))return;if(33===(v=e.charCodeAt(F+1))){if(91===(E=e.charCodeAt(F+2))&&"CDATA["===e.substr(F+3,6)){if(-1===(z=e.indexOf("]]>",F)))return g("unclosed cdata");if(r&&(r(e.substring(F+9,z),c),h))return;z+=3;continue}if(45===E&&45===e.charCodeAt(F+3)){if(-1===(z=e.indexOf("--\x3e",F)))return g("unclosed comment");if(s&&(s(e.substring(F+4,z),D,c),h))return;z+=3;continue}}if(63!==v){for(u=F+1;;u++){if(R=e.charCodeAt(u),isNaN(R))return z=-1,g("unclosed tag");if(34===R)E=e.indexOf('"',u+1),u=-1!==E?E:u;else if(39===R)E=e.indexOf("'",u+1),u=-1!==E?E:u;else if(62===R){z=u;break}}if(33!==v){if(M={},47===v){if(I=!1,O=!0,!P.length)return g("missing open tag");if(u=C=P.pop(),E=F+2+u.length,e.substring(F+2,E)!==u)return g("closing tag mismatch");for(;E<z;E++)if(!(32===(v=e.charCodeAt(E))||v>8&&v<14))return g("close tag")}else{if(47===e.charCodeAt(z-1)?(u=C=e.substring(F+1,z-1),I=!0,O=!0):(u=C=e.substring(F+1,z),I=!0,O=!1),!(v>96&&v<123||v>64&&v<91||95===v||58===v))return g("illegal first char nodeName");for(E=1,d=u.length;E<d;E++)if(!((v=u.charCodeAt(E))>96&&v<123||v>64&&v<91||v>47&&v<59||45===v||95===v||46==v)){if(32===v||v<14&&v>8){C=u.substring(0,E),M=null;break}return g("invalid nodeName")}O||P.push(C)}if(f){if(a=S,I&&(O||N.push(a),null===M&&(y=-1!==u.indexOf("xmlns",E))&&(U=E,G=u,q(),y=!1)),x=C,-1!==(v=C.indexOf(":"))){if(!(b=S[C.substring(0,v)]))return g("missing namespace on <"+x+">");C=C.substr(v+1)}else b=S.xmlns;b&&(C=b+":"+C)}if(I&&(U=E,G=u,n&&(l?n(w,D,O,c):n(C,q,D,O,c),h)))return;if(O){if(i&&(i(l?w:C,D,I,c),h))return;f&&(S=I?a:N.pop())}z+=1}else{if(p&&(p(e.substring(F,z+1),D,c),h))return;z+=1}}else{if(-1===(z=e.indexOf("?>",F)))return g("unclosed question");if(o&&(o(e.substring(F,z+2),c),h))return;z+=2}}}(e),c=z,h=!1,d},this.stop=function(){h=!0}}function q(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var K={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},_="xsi:type";function H(e){return e.xml&&e.xml.serialize}function X(e){return H(e)===_}function W(e,t){return q(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function Q(e){return new Error(e)}function J(e){return e.$descriptor}function Y(e){u(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw Q("expected element");var t,n=this.elementsById,i=J(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw Q("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function Z(){}function ee(){}function te(){}function ne(e,t){this.property=e,this.context=t}function ie(e,t){this.element=t,this.propertyDesc=e}function re(){}function ae(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function se(e,t,n){ae.call(this,e,t,n)}function oe(e,t,n){this.model=e,this.context=n}function pe(e){e instanceof w&&(e={model:e}),u(this,{lax:!1},e)}Z.prototype.handleEnd=function(){},Z.prototype.handleText=function(){},Z.prototype.handleNode=function(){},ee.prototype=Object.create(Z.prototype),ee.prototype.handleNode=function(){return this},te.prototype=Object.create(Z.prototype),te.prototype.handleText=function(e){this.body=(this.body||"")+e},ne.prototype=Object.create(te.prototype),ne.prototype.handleNode=function(e){if(this.element)throw Q("expected no sub nodes");return this.element=this.createReference(e),this},ne.prototype.handleEnd=function(){this.element.id=this.body},ne.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},ie.prototype=Object.create(te.prototype),ie.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=h(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},re.prototype=Object.create(te.prototype),re.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},ae.prototype=Object.create(re.prototype),ae.prototype.addReference=function(e){this.context.addReference(e)},ae.prototype.handleText=function(e){if(!J(this.element).bodyProperty)throw Q("unexpected body text <"+e+">");te.prototype.handleText.call(this,e)},ae.prototype.handleEnd=function(){var e=this.body,t=this.element,n=J(t).bodyProperty;n&&void 0!==e&&(e=h(n.type,e),t.set(n.name,e))},ae.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=J(i),a=this.context,o=new i({}),p=this.model;return s(n,function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?s(e.split(" "),function(e){a.addReference({element:o,property:i.ns.name,id:e})}):a.addReference({element:o,property:i.ns.name,id:e}):(i?e=h(i.type,e):"xmlns"!==n&&(t=E(n,r.ns.prefix),p.getPackage(t.prefix)&&a.addWarning({message:"unknown attribute <"+n+">",element:o,property:n,value:e})),o.set(n,e))}),o},ae.prototype.getPropertyForNode=function(e){var t,n,i=E(e.name),a=this.type,s=this.model,o=J(a),p=i.name,m=o.propertiesByName[p];if(m&&!m.isAttr)return X(m)&&(t=e.attributes[_])?(t=function(e,t){var n=E(e);return function(e,t){var n=e.name,i=e.localName,r=t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(n,t.getPackage(n.prefix))}(t,s),u({},m,{effectiveType:J(n=s.getType(t)).name})):m;var l=s.getPackage(i.prefix);if(l){if(t=W(i,l),n=s.getType(t),m=r(o.properties,function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)}))return u({},m,{effectiveType:J(n).name})}else if(m=r(o.properties,function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type}))return m;throw Q("unrecognized element <"+i.name+">")},ae.prototype.toString=function(){return"ElementDescriptor["+J(this.type).name+"]"},ae.prototype.valueHandler=function(e,t){return new ie(e,t)},ae.prototype.referenceHandler=function(e){return new ne(e,this.context)},ae.prototype.handler=function(e){return"Element"===e?new oe(this.model,e,this.context):new ae(this.model,e,this.context)},ae.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,A(n=t.effectiveType||t.type))return this.valueHandler(t,i);var a=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==a&&(t.isMany?i.get(t.name).push(a):i.set(t.name,a),t.isReference?(u(a,{element:i}),this.context.addReference(a)):a.$parent=i),r},se.prototype=Object.create(ae.prototype),se.prototype.createElement=function(e){var t=e.name,n=E(t),i=this.model,r=this.type,a=i.getPackage(n.prefix),s=a&&W(n,a)||t;if(!r.hasType(s))throw Q("unexpected element <"+e.originalName+">");return ae.prototype.createElement.call(this,e)},oe.prototype=Object.create(re.prototype),oe.prototype.createElement=function(e){var t=e.name,n=E(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},oe.prototype.handleChild=function(e){var t=new oe(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},oe.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},pe.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof ae?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,a=this.lax,s=new Y(u({},t,{rootHandler:i})),o=new U({proxy:!0}),p=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function m(e,t,n){var i=t(),r=i.line,a=i.column,o=i.data;"<"===o.charAt(0)&&-1!==o.indexOf(" ")&&(o=o.slice(0,o.indexOf(" "))+">");var p="unparsable content "+(o?o+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+a+"\n\tnested error: "+e.message;if(n)return s.addWarning({message:p,error:e}),!0;throw Q(p)}function l(e,t){return m(e,t,!0)}i.context=s,p.push(i);var c=/^<\?xml /i,y=/ encoding="([^"]+)"/i,f=/^utf-8$/i;function d(e,t){try{p.peek().handleText(e)}catch(e){l(e,t)}}var h=r.getPackages().reduce(function(e,t){return e[t.uri]=t.prefix,e},{"http://www.w3.org/XML/1998/namespace":"xml"});return o.ns(h).on("openTag",function(e,t,n,i){var r=e.attrs||{},s=Object.keys(r).reduce(function(e,n){var i=t(r[n]);return e[n]=i,e},{});!function(e,t){var n=p.peek();try{p.push(n.handleNode(e))}catch(e){m(e,t,a)&&p.push(new ee)}}({name:e.name,originalName:e.originalName,attributes:s,ns:e.ns},i)}).on("question",function(e){if(c.test(e)){var t=y.exec(e),n=t&&t[1];n&&!f.test(n)&&s.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}}).on("closeTag",function(){p.pop().handleEnd()}).on("cdata",d).on("text",function(e,t,n){!function(e,t){(e=e.trim())&&d(e,t)}(t(e),n)}).on("error",m).on("warn",l),new Promise(function(t,n){var r;try{o.parse(e),function(){var e,t,n=s.elementsById,i=s.references;for(e=0;t=i[e];e++){var r=t.element,a=n[t.id],o=J(r).propertiesByName[t.property];if(a||s.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),o.isMany){var p=r.get(o.name),m=p.indexOf(t);-1===m&&(m=p.length),a?p[m]=a:p.splice(m,1)}else r.set(o.name,a)}}()}catch(e){r=e}var a=i.element;r||a||(r=Q("failed to parse document as <"+i.type.$descriptor.name+">"));var p=s.warnings,m=s.references,l=s.elementsById;return r?(r.warnings=p,n(r)):t({rootElement:a,elementsById:l,references:m,warnings:p})})},pe.prototype.handler=function(e){return new se(this.model,e)};var me='<?xml version="1.0" encoding="UTF-8"?>\n',le=/<|>|'|"|&|\n\r|\n/g,ue=/<|>|&/g;function ce(e){var t={},n={},i={},r=[],a=[];this.byUri=function(t){return n[t]||e&&e.byUri(t)},this.add=function(e,t){n[e.uri]=e,t?r.push(e):a.push(e),this.mapPrefix(e.prefix,e.uri)},this.uriByPrefix=function(e){return t[e||"xmlns"]},this.mapPrefix=function(e,n){t[e||"xmlns"]=n},this.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},this.logUsed=function(t){var n=t.uri,r=this.getNSKey(t);i[r]=this.byUri(n),e&&e.logUsed(t)},this.getUsed=function(e){var t=this;return[].concat(r,a).filter(function(e){var n=t.getNSKey(e);return i[n]})}}function ye(e,t){return q(t)?(n=e).charAt(0).toLowerCase()+n.slice(1):e;var n}function fe(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function de(e){return n(e)?e:(e.prefix?e.prefix+":":"")+e.localName}function he(e){return t=e.getUsed(),n=function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}},i=[],s(t,function(e,t){i.push(n(e,t))}),i;var t,n,i}var ge={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},Ae={"<":"lt",">":"gt","&":"amp"};function Ee(e,t,i){return(e=n(e)?e:""+e).replace(t,function(e){return"&"+i[e]+";"})}function ve(e){this.tagName=e}function Re(){}function be(e){this.tagName=e}function Ce(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function xe(e,t){Ce.call(this,e,t)}function we(){this.value="",this.write=function(e){this.value+=e}}function Me(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function Ne(e){return e=u({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new we,r=new Me(i,e.format);if(e.preamble&&r.append(me),(new Ce).build(t).serializeTo(r),!n)return i.value}}}function Se(e,t){w.call(this,e,t)}ve.prototype.build=function(e){return this.element=e,this},ve.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},Re.prototype.serializeValue=Re.prototype.serializeTo=function(e){e.append(this.escape?Ee(this.value,ue,Ae):this.value)},Re.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(ue)&&(this.escape=!0),this},fe(be,Re),be.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},Ce.prototype.build=function(e){this.element=e;var t,n,r=e.$descriptor,s=this.propertyDescriptor,o=r.isGeneric;return t=o?this.parseGeneric(e):this.parseNsAttributes(e),this.ns=s?this.nsPropertyTagName(s):this.nsTagName(r),this.tagName=this.addTagName(this.ns),o||(n=function(e){return a(e.$descriptor.properties,function(t){var n=t.name;if(t.isVirtual)return!1;if(!i(e,n))return!1;var r=e[n];return r!==t.default&&null!==r&&(!t.isMany||r.length)})}(e),this.parseAttributes(a(n,function(e){return e.isAttr})),this.parseContainments(function(e){return a(e,function(e){return!e.isAttr})}(n))),this.parseGenericAttributes(e,t),this},Ce.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?u({localName:t.ns.localName},e):u({localName:ye(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},Ce.prototype.nsPropertyTagName=function(e){return function(e,t){return u({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},Ce.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},Ce.prototype.nsAttributeName=function(e){var t;if(t=n(e)?E(e):e.ns,e.inherited)return{localName:t.localName};var i=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(i),this.isLocalNs(i)?{localName:t.localName}:u({localName:t.localName},i)},Ce.prototype.parseGeneric=function(e){var t=this,n=this.body,i=[];return s(e,function(r,a){"$body"===a?n.push((new Re).build({type:"String"},r)):"$children"===a?s(r,function(e){n.push(new Ce(t).build(e))}):0!==a.indexOf("$")&&t.parseNsAttribute(e,a,r)&&i.push({name:a,value:r})}),i},Ce.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,a=E(t);if("xmlns"===a.prefix&&(i={prefix:a.localName,uri:n}),a.prefix||"xmlns"!==a.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var s=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(s)}},Ce.prototype.parseNsAttributes=function(e,t){var n=this,i=e.$attrs,r=[];return s(i,function(t,i){var a=n.parseNsAttribute(e,i,t);a&&r.push(a)}),r},Ce.prototype.parseGenericAttributes=function(e,t){var n=this;s(t,function(t){if(t.name!==_)try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){console.warn("missing namespace information for ",t.name,"=",t.value,"on",e,n)}})},Ce.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;s(e,function(e){var r=i.get(e.name),a=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new Re).build(e,r[0]));else if(A(e.type))s(r,function(i){n.push(new be(t.addTagName(t.nsPropertyTagName(e))).build(e,i))});else if(a)s(r,function(i){n.push(new ve(t.addTagName(t.nsPropertyTagName(e))).build(i))});else{var o=X(e),p=function(e){return"property"===H(e)}(e);s(r,function(i){var r;r=o?new xe(t,e):p?new Ce(t,e):new Ce(t),n.push(r.build(i))})}})},Ce.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new ce(t):n=t),n},Ce.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,a=e.prefix,s=i.byUri(r);return"xml"===a||s&&!n||i.add(e,t),i.mapPrefix(a,r),e},Ce.prototype.logNamespaceUsed=function(e,t){var n,i,r,a=this.element.$model,s=this.getNamespaces(t),o=e.prefix,p=e.uri;if(!o&&!p)return{localName:e.localName};if(r=K[o]||a&&(a.getPackage(o)||{}).uri,!(p=p||r||s.uriByPrefix(o)))throw new Error("no namespace uri given for prefix <"+o+">");if(!(e=s.byUri(p))){for(n=o,i=1;s.uriByPrefix(n);)n=o+"_"+i++;e=this.logNamespace({prefix:n,uri:p},r===p)}return o&&s.mapPrefix(o,p),e},Ce.prototype.parseAttributes=function(e){var t=this,n=this.element;s(e,function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];s(i,function(e){r.push(e.id)}),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)})},Ce.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),de(e)},Ce.prototype.addAttribute=function(e,t){var i=this.attrs;n(t)&&(t=Ee(t,le,ge)),i.push({name:e,value:t})},Ce.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=he(n).concat(t)),s(t,function(t){e.append(" ").append(de(t.name)).append('="').append(t.value).append('"')})},Ce.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==Re;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),s(this.body,function(t){t.serializeTo(e)}),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},fe(xe,Ce),xe.prototype.parseNsAttributes=function(e){var t=Ce.prototype.parseNsAttributes.call(this,e),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),a=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(_),(i.prefix?i.prefix+":":"")+a+n.ns.localName),t},xe.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},Se.prototype=Object.create(w.prototype),Se.prototype.fromXML=function(e,t,i){n(t)||(i=t,t="bpmn:Definitions");var r=new pe(u({model:this,lax:!0},i)),a=r.handler(t);return r.fromXML(e,a)},Se.prototype.toXML=function(e,t){var n=new Ne(t);return new Promise(function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}})};var Pe={bpmn:{name:"BPMN20",uri:"http://www.omg.org/spec/BPMN/20100524/MODEL",prefix:"bpmn",associations:[],types:[{name:"Interface",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"operations",type:"Operation",isMany:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"Operation",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"inMessageRef",type:"Message",isReference:!0},{name:"outMessageRef",type:"Message",isReference:!0},{name:"errorRef",type:"Error",isMany:!0,isReference:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"EndPoint",superClass:["RootElement"]},{name:"Auditing",superClass:["BaseElement"]},{name:"GlobalTask",superClass:["CallableElement"],properties:[{name:"resources",type:"ResourceRole",isMany:!0}]},{name:"Monitoring",superClass:["BaseElement"]},{name:"Performer",superClass:["ResourceRole"]},{name:"Process",superClass:["FlowElementsContainer","CallableElement"],properties:[{name:"processType",type:"ProcessType",isAttr:!0},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"properties",type:"Property",isMany:!0},{name:"laneSets",isMany:!0,replaces:"FlowElementsContainer#laneSets",type:"LaneSet"},{name:"flowElements",isMany:!0,replaces:"FlowElementsContainer#flowElements",type:"FlowElement"},{name:"artifacts",type:"Artifact",isMany:!0},{name:"resources",type:"ResourceRole",isMany:!0},{name:"correlationSubscriptions",type:"CorrelationSubscription",isMany:!0},{name:"supports",type:"Process",isMany:!0,isReference:!0},{name:"definitionalCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"isExecutable",isAttr:!0,type:"Boolean"}]},{name:"LaneSet",superClass:["BaseElement"],properties:[{name:"lanes",type:"Lane",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Lane",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"partitionElementRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"partitionElement",type:"BaseElement"},{name:"flowNodeRef",type:"FlowNode",isMany:!0,isReference:!0},{name:"childLaneSet",type:"LaneSet",xml:{serialize:"xsi:type"}}]},{name:"GlobalManualTask",superClass:["GlobalTask"]},{name:"ManualTask",superClass:["Task"]},{name:"UserTask",superClass:["Task"],properties:[{name:"renderings",type:"Rendering",isMany:!0},{name:"implementation",isAttr:!0,type:"String"}]},{name:"Rendering",superClass:["BaseElement"]},{name:"HumanPerformer",superClass:["Performer"]},{name:"PotentialOwner",superClass:["HumanPerformer"]},{name:"GlobalUserTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"renderings",type:"Rendering",isMany:!0}]},{name:"Gateway",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"gatewayDirection",type:"GatewayDirection",default:"Unspecified",isAttr:!0}]},{name:"EventBasedGateway",superClass:["Gateway"],properties:[{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"eventGatewayType",type:"EventBasedGatewayType",isAttr:!0,default:"Exclusive"}]},{name:"ComplexGateway",superClass:["Gateway"],properties:[{name:"activationCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ExclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"InclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ParallelGateway",superClass:["Gateway"]},{name:"RootElement",isAbstract:!0,superClass:["BaseElement"]},{name:"Relationship",superClass:["BaseElement"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"direction",type:"RelationshipDirection",isAttr:!0},{name:"source",isMany:!0,isReference:!0,type:"Element"},{name:"target",isMany:!0,isReference:!0,type:"Element"}]},{name:"BaseElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,type:"String",isId:!0},{name:"documentation",type:"Documentation",isMany:!0},{name:"extensionDefinitions",type:"ExtensionDefinition",isMany:!0,isReference:!0},{name:"extensionElements",type:"ExtensionElements"}]},{name:"Extension",properties:[{name:"mustUnderstand",default:!1,isAttr:!0,type:"Boolean"},{name:"definition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"extensionAttributeDefinitions",type:"ExtensionAttributeDefinition",isMany:!0}]},{name:"ExtensionAttributeDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"type",isAttr:!0,type:"String"},{name:"isReference",default:!1,isAttr:!0,type:"Boolean"},{name:"extensionDefinition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionElements",properties:[{name:"valueRef",isAttr:!0,isReference:!0,type:"Element"},{name:"values",type:"Element",isMany:!0},{name:"extensionAttributeDefinition",type:"ExtensionAttributeDefinition",isAttr:!0,isReference:!0}]},{name:"Documentation",superClass:["BaseElement"],properties:[{name:"text",type:"String",isBody:!0},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Event",isAbstract:!0,superClass:["FlowNode","InteractionNode"],properties:[{name:"properties",type:"Property",isMany:!0}]},{name:"IntermediateCatchEvent",superClass:["CatchEvent"]},{name:"IntermediateThrowEvent",superClass:["ThrowEvent"]},{name:"EndEvent",superClass:["ThrowEvent"]},{name:"StartEvent",superClass:["CatchEvent"],properties:[{name:"isInterrupting",default:!0,isAttr:!0,type:"Boolean"}]},{name:"ThrowEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"inputSet",type:"InputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"CatchEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"parallelMultiple",isAttr:!0,type:"Boolean",default:!1},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"outputSet",type:"OutputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"BoundaryEvent",superClass:["CatchEvent"],properties:[{name:"cancelActivity",default:!0,isAttr:!0,type:"Boolean"},{name:"attachedToRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"EventDefinition",isAbstract:!0,superClass:["RootElement"]},{name:"CancelEventDefinition",superClass:["EventDefinition"]},{name:"ErrorEventDefinition",superClass:["EventDefinition"],properties:[{name:"errorRef",type:"Error",isAttr:!0,isReference:!0}]},{name:"TerminateEventDefinition",superClass:["EventDefinition"]},{name:"EscalationEventDefinition",superClass:["EventDefinition"],properties:[{name:"escalationRef",type:"Escalation",isAttr:!0,isReference:!0}]},{name:"Escalation",properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"escalationCode",isAttr:!0,type:"String"}],superClass:["RootElement"]},{name:"CompensateEventDefinition",superClass:["EventDefinition"],properties:[{name:"waitForCompletion",isAttr:!0,type:"Boolean",default:!0},{name:"activityRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"TimerEventDefinition",superClass:["EventDefinition"],properties:[{name:"timeDate",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeCycle",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeDuration",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"LinkEventDefinition",superClass:["EventDefinition"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"target",type:"LinkEventDefinition",isAttr:!0,isReference:!0},{name:"source",type:"LinkEventDefinition",isMany:!0,isReference:!0}]},{name:"MessageEventDefinition",superClass:["EventDefinition"],properties:[{name:"messageRef",type:"Message",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"ConditionalEventDefinition",superClass:["EventDefinition"],properties:[{name:"condition",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"SignalEventDefinition",superClass:["EventDefinition"],properties:[{name:"signalRef",type:"Signal",isAttr:!0,isReference:!0}]},{name:"Signal",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ImplicitThrowEvent",superClass:["ThrowEvent"]},{name:"DataState",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ItemAwareElement",superClass:["BaseElement"],properties:[{name:"itemSubjectRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"dataState",type:"DataState"}]},{name:"DataAssociation",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"ItemAwareElement",isMany:!0,isReference:!0},{name:"targetRef",type:"ItemAwareElement",isReference:!0},{name:"transformation",type:"FormalExpression",xml:{serialize:"property"}},{name:"assignment",type:"Assignment",isMany:!0}]},{name:"DataInput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"inputSetRef",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithOptional",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithWhileExecuting",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"DataOutput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"outputSetRef",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithOptional",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithWhileExecuting",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"InputSet",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"dataInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"optionalInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"whileExecutingInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"outputSetRefs",type:"OutputSet",isMany:!0,isReference:!0}]},{name:"OutputSet",superClass:["BaseElement"],properties:[{name:"dataOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"inputSetRefs",type:"InputSet",isMany:!0,isReference:!0},{name:"optionalOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"whileExecutingOutputRefs",type:"DataOutput",isMany:!0,isReference:!0}]},{name:"Property",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"DataInputAssociation",superClass:["DataAssociation"]},{name:"DataOutputAssociation",superClass:["DataAssociation"]},{name:"InputOutputSpecification",superClass:["BaseElement"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"inputSets",type:"InputSet",isMany:!0},{name:"outputSets",type:"OutputSet",isMany:!0}]},{name:"DataObject",superClass:["FlowElement","ItemAwareElement"],properties:[{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"}]},{name:"InputOutputBinding",properties:[{name:"inputDataRef",type:"InputSet",isAttr:!0,isReference:!0},{name:"outputDataRef",type:"OutputSet",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"Assignment",superClass:["BaseElement"],properties:[{name:"from",type:"Expression",xml:{serialize:"xsi:type"}},{name:"to",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"DataStore",superClass:["RootElement","ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"capacity",isAttr:!0,type:"Integer"},{name:"isUnlimited",default:!0,isAttr:!0,type:"Boolean"}]},{name:"DataStoreReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataStoreRef",type:"DataStore",isAttr:!0,isReference:!0}]},{name:"DataObjectReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataObjectRef",type:"DataObject",isAttr:!0,isReference:!0}]},{name:"ConversationLink",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ConversationAssociation",superClass:["BaseElement"],properties:[{name:"innerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0},{name:"outerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0}]},{name:"CallConversation",superClass:["ConversationNode"],properties:[{name:"calledCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"Conversation",superClass:["ConversationNode"]},{name:"SubConversation",superClass:["ConversationNode"],properties:[{name:"conversationNodes",type:"ConversationNode",isMany:!0}]},{name:"ConversationNode",isAbstract:!0,superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"messageFlowRefs",type:"MessageFlow",isMany:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0}]},{name:"GlobalConversation",superClass:["Collaboration"]},{name:"PartnerEntity",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"PartnerRole",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"CorrelationProperty",superClass:["RootElement"],properties:[{name:"correlationPropertyRetrievalExpression",type:"CorrelationPropertyRetrievalExpression",isMany:!0},{name:"name",isAttr:!0,type:"String"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Error",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"errorCode",isAttr:!0,type:"String"}]},{name:"CorrelationKey",superClass:["BaseElement"],properties:[{name:"correlationPropertyRef",type:"CorrelationProperty",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Expression",superClass:["BaseElement"],isAbstract:!1,properties:[{name:"body",isBody:!0,type:"String"}]},{name:"FormalExpression",superClass:["Expression"],properties:[{name:"language",isAttr:!0,type:"String"},{name:"evaluatesToTypeRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Message",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"itemRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"ItemDefinition",superClass:["RootElement"],properties:[{name:"itemKind",type:"ItemKind",isAttr:!0},{name:"structureRef",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"import",type:"Import",isAttr:!0,isReference:!0}]},{name:"FlowElement",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"categoryValueRef",type:"CategoryValue",isMany:!0,isReference:!0}]},{name:"SequenceFlow",superClass:["FlowElement"],properties:[{name:"isImmediate",isAttr:!0,type:"Boolean"},{name:"conditionExpression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"sourceRef",type:"FlowNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"FlowNode",isAttr:!0,isReference:!0}]},{name:"FlowElementsContainer",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"laneSets",type:"LaneSet",isMany:!0},{name:"flowElements",type:"FlowElement",isMany:!0}]},{name:"CallableElement",isAbstract:!0,superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"supportedInterfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"ioBinding",type:"InputOutputBinding",isMany:!0,xml:{serialize:"property"}}]},{name:"FlowNode",isAbstract:!0,superClass:["FlowElement"],properties:[{name:"incoming",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"outgoing",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"lanes",type:"Lane",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"CorrelationPropertyRetrievalExpression",superClass:["BaseElement"],properties:[{name:"messagePath",type:"FormalExpression"},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"CorrelationPropertyBinding",superClass:["BaseElement"],properties:[{name:"dataPath",type:"FormalExpression"},{name:"correlationPropertyRef",type:"CorrelationProperty",isAttr:!0,isReference:!0}]},{name:"Resource",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"resourceParameters",type:"ResourceParameter",isMany:!0}]},{name:"ResourceParameter",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isRequired",isAttr:!0,type:"Boolean"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"CorrelationSubscription",superClass:["BaseElement"],properties:[{name:"correlationKeyRef",type:"CorrelationKey",isAttr:!0,isReference:!0},{name:"correlationPropertyBinding",type:"CorrelationPropertyBinding",isMany:!0}]},{name:"MessageFlow",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"MessageFlowAssociation",superClass:["BaseElement"],properties:[{name:"innerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0},{name:"outerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0}]},{name:"InteractionNode",isAbstract:!0,properties:[{name:"incomingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0},{name:"outgoingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"Participant",superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"interfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"participantMultiplicity",type:"ParticipantMultiplicity"},{name:"endPointRefs",type:"EndPoint",isMany:!0,isReference:!0},{name:"processRef",type:"Process",isAttr:!0,isReference:!0}]},{name:"ParticipantAssociation",superClass:["BaseElement"],properties:[{name:"innerParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"outerParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"ParticipantMultiplicity",properties:[{name:"minimum",default:0,isAttr:!0,type:"Integer"},{name:"maximum",default:1,isAttr:!0,type:"Integer"}],superClass:["BaseElement"]},{name:"Collaboration",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"participants",type:"Participant",isMany:!0},{name:"messageFlows",type:"MessageFlow",isMany:!0},{name:"artifacts",type:"Artifact",isMany:!0},{name:"conversations",type:"ConversationNode",isMany:!0},{name:"conversationAssociations",type:"ConversationAssociation"},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0},{name:"messageFlowAssociations",type:"MessageFlowAssociation",isMany:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"choreographyRef",type:"Choreography",isMany:!0,isReference:!0},{name:"conversationLinks",type:"ConversationLink",isMany:!0}]},{name:"ChoreographyActivity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"loopType",type:"ChoreographyLoopType",default:"None",isAttr:!0}]},{name:"CallChoreography",superClass:["ChoreographyActivity"],properties:[{name:"calledChoreographyRef",type:"Choreography",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"SubChoreography",superClass:["ChoreographyActivity","FlowElementsContainer"],properties:[{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"ChoreographyTask",superClass:["ChoreographyActivity"],properties:[{name:"messageFlowRef",type:"MessageFlow",isMany:!0,isReference:!0}]},{name:"Choreography",superClass:["Collaboration","FlowElementsContainer"]},{name:"GlobalChoreographyTask",superClass:["Choreography"],properties:[{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Group",superClass:["Artifact"],properties:[{name:"categoryValueRef",type:"CategoryValue",isAttr:!0,isReference:!0}]},{name:"Association",superClass:["Artifact"],properties:[{name:"associationDirection",type:"AssociationDirection",isAttr:!0},{name:"sourceRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"targetRef",type:"BaseElement",isAttr:!0,isReference:!0}]},{name:"Category",superClass:["RootElement"],properties:[{name:"categoryValue",type:"CategoryValue",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Artifact",isAbstract:!0,superClass:["BaseElement"]},{name:"CategoryValue",superClass:["BaseElement"],properties:[{name:"categorizedFlowElements",type:"FlowElement",isMany:!0,isVirtual:!0,isReference:!0},{name:"value",isAttr:!0,type:"String"}]},{name:"Activity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"isForCompensation",default:!1,isAttr:!0,type:"Boolean"},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"boundaryEventRefs",type:"BoundaryEvent",isMany:!0,isReference:!0},{name:"properties",type:"Property",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"startQuantity",default:1,isAttr:!0,type:"Integer"},{name:"resources",type:"ResourceRole",isMany:!0},{name:"completionQuantity",default:1,isAttr:!0,type:"Integer"},{name:"loopCharacteristics",type:"LoopCharacteristics"}]},{name:"ServiceTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"SubProcess",superClass:["Activity","FlowElementsContainer","InteractionNode"],properties:[{name:"triggeredByEvent",default:!1,isAttr:!0,type:"Boolean"},{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"LoopCharacteristics",isAbstract:!0,superClass:["BaseElement"]},{name:"MultiInstanceLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"isSequential",default:!1,isAttr:!0,type:"Boolean"},{name:"behavior",type:"MultiInstanceBehavior",default:"All",isAttr:!0},{name:"loopCardinality",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopDataInputRef",type:"ItemAwareElement",isReference:!0},{name:"loopDataOutputRef",type:"ItemAwareElement",isReference:!0},{name:"inputDataItem",type:"DataInput",xml:{serialize:"property"}},{name:"outputDataItem",type:"DataOutput",xml:{serialize:"property"}},{name:"complexBehaviorDefinition",type:"ComplexBehaviorDefinition",isMany:!0},{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"oneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0},{name:"noneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0}]},{name:"StandardLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"testBefore",default:!1,isAttr:!0,type:"Boolean"},{name:"loopCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopMaximum",type:"Integer",isAttr:!0}]},{name:"CallActivity",superClass:["Activity"],properties:[{name:"calledElement",type:"String",isAttr:!0}]},{name:"Task",superClass:["Activity","InteractionNode"]},{name:"SendTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ReceiveTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ScriptTask",superClass:["Task"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"script",type:"String"}]},{name:"BusinessRuleTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"AdHocSubProcess",superClass:["SubProcess"],properties:[{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"ordering",type:"AdHocOrdering",isAttr:!0},{name:"cancelRemainingInstances",default:!0,isAttr:!0,type:"Boolean"}]},{name:"Transaction",superClass:["SubProcess"],properties:[{name:"protocol",isAttr:!0,type:"String"},{name:"method",isAttr:!0,type:"String"}]},{name:"GlobalScriptTask",superClass:["GlobalTask"],properties:[{name:"scriptLanguage",isAttr:!0,type:"String"},{name:"script",isAttr:!0,type:"String"}]},{name:"GlobalBusinessRuleTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"ComplexBehaviorDefinition",superClass:["BaseElement"],properties:[{name:"condition",type:"FormalExpression"},{name:"event",type:"ImplicitThrowEvent"}]},{name:"ResourceRole",superClass:["BaseElement"],properties:[{name:"resourceRef",type:"Resource",isReference:!0},{name:"resourceParameterBindings",type:"ResourceParameterBinding",isMany:!0},{name:"resourceAssignmentExpression",type:"ResourceAssignmentExpression"},{name:"name",isAttr:!0,type:"String"}]},{name:"ResourceParameterBinding",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"parameterRef",type:"ResourceParameter",isAttr:!0,isReference:!0}],superClass:["BaseElement"]},{name:"ResourceAssignmentExpression",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}}],superClass:["BaseElement"]},{name:"Import",properties:[{name:"importType",isAttr:!0,type:"String"},{name:"location",isAttr:!0,type:"String"},{name:"namespace",isAttr:!0,type:"String"}]},{name:"Definitions",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"targetNamespace",isAttr:!0,type:"String"},{name:"expressionLanguage",default:"http://www.w3.org/1999/XPath",isAttr:!0,type:"String"},{name:"typeLanguage",default:"http://www.w3.org/2001/XMLSchema",isAttr:!0,type:"String"},{name:"imports",type:"Import",isMany:!0},{name:"extensions",type:"Extension",isMany:!0},{name:"rootElements",type:"RootElement",isMany:!0},{name:"diagrams",isMany:!0,type:"bpmndi:BPMNDiagram"},{name:"exporter",isAttr:!0,type:"String"},{name:"relationships",type:"Relationship",isMany:!0},{name:"exporterVersion",isAttr:!0,type:"String"}]}],enumerations:[{name:"ProcessType",literalValues:[{name:"None"},{name:"Public"},{name:"Private"}]},{name:"GatewayDirection",literalValues:[{name:"Unspecified"},{name:"Converging"},{name:"Diverging"},{name:"Mixed"}]},{name:"EventBasedGatewayType",literalValues:[{name:"Parallel"},{name:"Exclusive"}]},{name:"RelationshipDirection",literalValues:[{name:"None"},{name:"Forward"},{name:"Backward"},{name:"Both"}]},{name:"ItemKind",literalValues:[{name:"Physical"},{name:"Information"}]},{name:"ChoreographyLoopType",literalValues:[{name:"None"},{name:"Standard"},{name:"MultiInstanceSequential"},{name:"MultiInstanceParallel"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"MultiInstanceBehavior",literalValues:[{name:"None"},{name:"One"},{name:"All"},{name:"Complex"}]},{name:"AdHocOrdering",literalValues:[{name:"Parallel"},{name:"Sequential"}]}],xml:{tagAlias:"lowerCase",typePrefix:"t"}},bpmndi:{name:"BPMNDI",uri:"http://www.omg.org/spec/BPMN/20100524/DI",prefix:"bpmndi",types:[{name:"BPMNDiagram",properties:[{name:"plane",type:"BPMNPlane",redefines:"di:Diagram#rootElement"},{name:"labelStyle",type:"BPMNLabelStyle",isMany:!0}],superClass:["di:Diagram"]},{name:"BPMNPlane",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"}],superClass:["di:Plane"]},{name:"BPMNShape",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"isHorizontal",isAttr:!0,type:"Boolean"},{name:"isExpanded",isAttr:!0,type:"Boolean"},{name:"isMarkerVisible",isAttr:!0,type:"Boolean"},{name:"label",type:"BPMNLabel"},{name:"isMessageVisible",isAttr:!0,type:"Boolean"},{name:"participantBandKind",type:"ParticipantBandKind",isAttr:!0},{name:"choreographyActivityShape",type:"BPMNShape",isAttr:!0,isReference:!0}],superClass:["di:LabeledShape"]},{name:"BPMNEdge",properties:[{name:"label",type:"BPMNLabel"},{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"sourceElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#source"},{name:"targetElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#target"},{name:"messageVisibleKind",type:"MessageVisibleKind",isAttr:!0,default:"initiating"}],superClass:["di:LabeledEdge"]},{name:"BPMNLabel",properties:[{name:"labelStyle",type:"BPMNLabelStyle",isAttr:!0,isReference:!0,redefines:"di:DiagramElement#style"}],superClass:["di:Label"]},{name:"BPMNLabelStyle",properties:[{name:"font",type:"dc:Font"}],superClass:["di:Style"]}],enumerations:[{name:"ParticipantBandKind",literalValues:[{name:"top_initiating"},{name:"middle_initiating"},{name:"bottom_initiating"},{name:"top_non_initiating"},{name:"middle_non_initiating"},{name:"bottom_non_initiating"}]},{name:"MessageVisibleKind",literalValues:[{name:"initiating"},{name:"non_initiating"}]}],associations:[]},dc:{name:"DC",uri:"http://www.omg.org/spec/DD/20100524/DC",prefix:"dc",types:[{name:"Boolean"},{name:"Integer"},{name:"Real"},{name:"String"},{name:"Font",properties:[{name:"name",type:"String",isAttr:!0},{name:"size",type:"Real",isAttr:!0},{name:"isBold",type:"Boolean",isAttr:!0},{name:"isItalic",type:"Boolean",isAttr:!0},{name:"isUnderline",type:"Boolean",isAttr:!0},{name:"isStrikeThrough",type:"Boolean",isAttr:!0}]},{name:"Point",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0}]},{name:"Bounds",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0},{name:"width",type:"Real",isAttr:!0},{name:"height",type:"Real",isAttr:!0}]}],associations:[]},di:{name:"DI",uri:"http://www.omg.org/spec/DD/20100524/DI",prefix:"di",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"extension",type:"Extension"},{name:"owningDiagram",type:"Diagram",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"owningElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"modelElement",isReadOnly:!0,isVirtual:!0,isReference:!0,type:"Element"},{name:"style",type:"Style",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"ownedElement",type:"DiagramElement",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Node",isAbstract:!0,superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,superClass:["DiagramElement"],properties:[{name:"source",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"target",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"waypoint",isUnique:!1,isMany:!0,type:"dc:Point",xml:{serialize:"xsi:type"}}]},{name:"Diagram",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"rootElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0},{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"},{name:"ownedStyle",type:"Style",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Shape",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Plane",isAbstract:!0,superClass:["Node"],properties:[{name:"planeElement",type:"DiagramElement",subsettedProperty:"DiagramElement-ownedElement",isMany:!0}]},{name:"LabeledEdge",isAbstract:!0,superClass:["Edge"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"LabeledShape",isAbstract:!0,superClass:["Shape"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"Label",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],xml:{tagAlias:"lowerCase"}},bioc:{name:"bpmn.io colors for BPMN",uri:"http://bpmn.io/schema/bpmn/biocolor/1.0",prefix:"bioc",types:[{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]}};return function(e,t){return new Se(u({},Pe,e),t)}});
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).BpmnModdle=t()}(this,(function(){"use strict";var e=Object.prototype.toString,t=Object.prototype.hasOwnProperty;function n(t){return"[object String]"===e.call(t)}function i(e,n){return t.call(e,n)}function r(t,n){var i;return n=function(t){return n=t,i=e.call(n),"[object Function]"===i||"[object AsyncFunction]"===i||"[object GeneratorFunction]"===i||"[object AsyncGeneratorFunction]"===i||"[object Proxy]"===i?t:function(e){return e===t};var n,i}(n),s(t,(function(e,t){if(n(e,t))return i=e,!1})),i}function a(e,t){var n=[];return s(e,(function(e,i){t(e,i)&&n.push(e)})),n}function s(t,n){var r;if(void 0!==t){var a=function(t){return"[object Array]"===e.call(t)}(t)?p:o;for(var s in t)if(i(t,s)&&!1===n(r=t[s],a(s)))return r}}function o(e){return e}function p(e){return Number(e)}function m(e,t){return e.bind(t)}function l(){return(l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e}).apply(this,arguments)}function u(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];return l.apply(void 0,[e].concat(n))}function c(){}function y(e,t){this.model=e,this.properties=t}c.prototype.get=function(e){return this.$model.properties.get(this,e)},c.prototype.set=function(e,t){this.$model.properties.set(this,e,t)},y.prototype.createType=function(e){var t=this.model,n=this.properties,i=Object.create(c.prototype);s(e.properties,(function(e){e.isMany||void 0===e.default||(i[e.name]=e.default)})),n.defineModel(i,t),n.defineDescriptor(i,e);var r=e.ns.name;function a(e){n.define(this,"$type",{value:r,enumerable:!0}),n.define(this,"$attrs",{value:{}}),n.define(this,"$parent",{writable:!0}),s(e,m((function(e,t){this.set(t,e)}),this))}return a.prototype=i,a.hasType=i.$instanceOf=this.model.hasType,n.defineModel(a,t),n.defineDescriptor(a,e),a};var f={String:!0,Boolean:!0,Integer:!0,Real:!0,Element:!0},d={String:function(e){return e},Boolean:function(e){return"true"===e},Integer:function(e){return parseInt(e,10)},Real:function(e){return parseFloat(e)}};function h(e,t){var n=d[e];return n?n(t):t}function g(e){return!!f[e]}function A(e){return!!d[e]}function E(e,t){var n,i,r=e.split(/:/);if(1===r.length)n=e,i=t;else{if(2!==r.length)throw new Error("expected <prefix:localName> or <localName>, got "+e);n=r[1],i=r[0]}return{name:e=(i?i+":":"")+n,prefix:i,localName:n}}function b(e){this.ns=e,this.name=e.name,this.allTypes=[],this.allTypesByName={},this.properties=[],this.propertiesByName={}}function v(e,t){this.packageMap={},this.typeMap={},this.packages=[],this.properties=t,s(e,m(this.registerPackage,this))}function R(e,t,n){var i=t[n];if(i in e)throw new Error("package with "+n+" <"+i+"> already defined")}function C(e){this.model=e}function x(e,t,n){Object.defineProperty(e,t.name,{enumerable:!t.isReference,writable:!0,value:n,configurable:!0})}function w(e){this.properties=new C(this),this.factory=new y(this,this.properties),this.registry=new v(e,this.properties),this.typeCache={}}b.prototype.build=function(){return e=this,t=["ns","name","allTypes","allTypesByName","properties","propertiesByName","bodyProperty","idProperty"],n={},i=Object(e),s(t,(function(t){t in i&&(n[t]=e[t])})),n;var e,t,n,i},b.prototype.addProperty=function(e,t,n){"boolean"==typeof t&&(n=t,t=void 0),this.addNamedProperty(e,!1!==n);var i=this.properties;void 0!==t?i.splice(t,0,e):i.push(e)},b.prototype.replaceProperty=function(e,t,n){var i=e.ns,r=this.properties,a=this.propertiesByName,s=e.name!==t.name;if(e.isId){if(!t.isId)throw new Error("property <"+t.ns.name+"> must be id property to refine <"+e.ns.name+">");this.setIdProperty(t,!1)}if(e.isBody){if(!t.isBody)throw new Error("property <"+t.ns.name+"> must be body property to refine <"+e.ns.name+">");this.setBodyProperty(t,!1)}var o=r.indexOf(e);if(-1===o)throw new Error("property <"+i.name+"> not found in property list");r.splice(o,1),this.addProperty(t,n?void 0:o,s),a[i.name]=a[i.localName]=t},b.prototype.redefineProperty=function(e,t,n){var i=e.ns.prefix,r=t.split("#"),a=E(r[0],i),s=E(r[1],a.prefix).name,o=this.propertiesByName[s];if(!o)throw new Error("refined property <"+s+"> not found");this.replaceProperty(o,e,n),delete e.redefines},b.prototype.addNamedProperty=function(e,t){var n=e.ns,i=this.propertiesByName;t&&(this.assertNotDefined(e,n.name),this.assertNotDefined(e,n.localName)),i[n.name]=i[n.localName]=e},b.prototype.removeNamedProperty=function(e){var t=e.ns,n=this.propertiesByName;delete n[t.name],delete n[t.localName]},b.prototype.setBodyProperty=function(e,t){if(t&&this.bodyProperty)throw new Error("body property defined multiple times (<"+this.bodyProperty.ns.name+">, <"+e.ns.name+">)");this.bodyProperty=e},b.prototype.setIdProperty=function(e,t){if(t&&this.idProperty)throw new Error("id property defined multiple times (<"+this.idProperty.ns.name+">, <"+e.ns.name+">)");this.idProperty=e},b.prototype.assertNotDefined=function(e,t){var n=e.name,i=this.propertiesByName[n];if(i)throw new Error("property <"+n+"> already defined; override of <"+i.definedBy.ns.name+"#"+i.ns.name+"> by <"+e.definedBy.ns.name+"#"+e.ns.name+"> not allowed without redefines")},b.prototype.hasProperty=function(e){return this.propertiesByName[e]},b.prototype.addTrait=function(e,t){var n=this.allTypesByName,i=this.allTypes,r=e.name;r in n||(s(e.properties,m((function(n){n=u({},n,{name:n.ns.localName,inherited:t}),Object.defineProperty(n,"definedBy",{value:e});var i=n.replaces,r=n.redefines;i||r?this.redefineProperty(n,i||r,i):(n.isBody&&this.setBodyProperty(n),n.isId&&this.setIdProperty(n),this.addProperty(n))}),this)),i.push(e),n[r]=e)},v.prototype.getPackage=function(e){return this.packageMap[e]},v.prototype.getPackages=function(){return this.packages},v.prototype.registerPackage=function(e){e=u({},e);var t=this.packageMap;R(t,e,"prefix"),R(t,e,"uri"),s(e.types,m((function(t){this.registerType(t,e)}),this)),t[e.uri]=t[e.prefix]=e,this.packages.push(e)},v.prototype.registerType=function(e,t){var n=E((e=u({},e,{superClass:(e.superClass||[]).slice(),extends:(e.extends||[]).slice(),properties:(e.properties||[]).slice(),meta:u(e.meta||{})})).name,t.prefix),i=n.name,r={};s(e.properties,m((function(e){var t=E(e.name,n.prefix),i=t.name;g(e.type)||(e.type=E(e.type,t.prefix).name),u(e,{ns:t,name:i}),r[i]=e}),this)),u(e,{ns:n,name:i,propertiesByName:r}),s(e.extends,m((function(e){var t=this.typeMap[e];t.traits=t.traits||[],t.traits.push(i)}),this)),this.definePackage(e,t),this.typeMap[i]=e},v.prototype.mapTypes=function(e,t,n){var i=g(e.name)?{name:e.name}:this.typeMap[e.name],r=this;function a(e){return o(e,!0)}function o(n,i){var a=E(n,g(n)?"":e.prefix);r.mapTypes(a,t,i)}if(!i)throw new Error("unknown type <"+e.name+">");s(i.superClass,n?a:o),t(i,!n),s(i.traits,a)},v.prototype.getEffectiveDescriptor=function(e){var t=E(e),n=new b(t);this.mapTypes(t,(function(e,t){n.addTrait(e,t)}));var i=n.build();return this.definePackage(i,i.allTypes[i.allTypes.length-1].$pkg),i},v.prototype.definePackage=function(e,t){this.properties.define(e,"$pkg",{value:t})},C.prototype.set=function(e,t,n){var i=this.model.getPropertyDescriptor(e,t),r=i&&i.name;void 0===n?i?delete e[r]:delete e.$attrs[t]:i?r in e?e[r]=n:x(e,i,n):e.$attrs[t]=n},C.prototype.get=function(e,t){var n=this.model.getPropertyDescriptor(e,t);if(!n)return e.$attrs[t];var i=n.name;return!e[i]&&n.isMany&&x(e,n,[]),e[i]},C.prototype.define=function(e,t,n){Object.defineProperty(e,t,n)},C.prototype.defineDescriptor=function(e,t){this.define(e,"$descriptor",{value:t})},C.prototype.defineModel=function(e,t){this.define(e,"$model",{value:t})},w.prototype.create=function(e,t){var n=this.getType(e);if(!n)throw new Error("unknown type <"+e+">");return new n(t)},w.prototype.getType=function(e){var t=this.typeCache,i=n(e)?e:e.ns.name,r=t[i];return r||(e=this.registry.getEffectiveDescriptor(i),r=t[i]=this.factory.createType(e)),r},w.prototype.createAny=function(t,n,i){var r=E(t),a={$type:t,$instanceOf:function(e){return e===this.$type}},o={name:t,isGeneric:!0,ns:{prefix:r.prefix,localName:r.localName,uri:n}};return this.properties.defineDescriptor(a,o),this.properties.defineModel(a,this),this.properties.define(a,"$parent",{enumerable:!1,writable:!0}),this.properties.define(a,"$instanceOf",{enumerable:!1,writable:!0}),s(i,(function(t,n){var i;i=t,"[object Object]"===e.call(i)&&void 0!==t.value?a[t.name]=t.value:a[n]=t})),a},w.prototype.getPackage=function(e){return this.registry.getPackage(e)},w.prototype.getPackages=function(){return this.registry.getPackages()},w.prototype.getElementDescriptor=function(e){return e.$descriptor},w.prototype.hasType=function(e,t){return void 0===t&&(t=e,e=this),t in e.$model.getElementDescriptor(e).allTypesByName},w.prototype.getPropertyDescriptor=function(e,t){return this.getElementDescriptor(e).propertiesByName[t]},w.prototype.getTypeDescriptor=function(e){return this.registry.typeMap[e]};var M=String.fromCharCode,N=Object.prototype.hasOwnProperty,S=/&#(\d+);|&#x([0-9a-f]+);|&(\w+);/gi,P={amp:"&",apos:"'",gt:">",lt:"<",quot:'"'};function B(e,t,n,i){return i?N.call(P,i)?P[i]:"&"+i+";":M(t||parseInt(n,16))}function D(e){return e.length>3&&-1!==e.indexOf("&")?e.replace(S,B):e}Object.keys(P).forEach((function(e){P[e.toUpperCase()]=P[e]}));var I="xsi:type",O="non-whitespace outside of root node";function T(e){return new Error(e)}function k(e){return"missing namespace for prefix <"+e+">"}function F(e){return{get:e,enumerable:!0}}function L(e){var t,n={};for(t in e)n[t]=e[t];return n}function V(e){return e+"$uri"}function j(){return{line:0,column:0}}function $(e){throw e}function z(e){if(!this)return new z(e);var t,n,i,r,a,s,o,p,m,l=e&&e.proxy,u=$,c=j,y=!1,f=!1,d=null,h=!1;function g(e){e instanceof Error||(e=T(e)),d=e,u(e,c)}function A(e){a&&(e instanceof Error||(e=T(e)),a(e,c))}this.on=function(e,m){if("function"!=typeof m)throw T("required args <name, cb>");switch(e){case"openTag":n=m;break;case"text":t=m;break;case"closeTag":i=m;break;case"error":u=m;break;case"warn":a=m;break;case"cdata":r=m;break;case"attention":p=m;break;case"question":o=m;break;case"comment":s=m;break;default:throw T("unsupported event: "+e)}return this},this.ns=function(e){if(void 0===e&&(e={}),"object"!=typeof e)throw T("required args <nsMap={}>");var t,n={};for(t in e)n[t]=e[t];return n["http://www.w3.org/2001/XMLSchema-instance"]="xsi",f=!0,m=n,this},this.parse=function(e){if("string"!=typeof e)throw T("required args <xml=string>");return d=null,function(e){var a,u,d,E,b,v,R,C,x,w,M,N=f?[]:null,S=f?function(e){var t,n,i={};for(t in e)i[n=e[t]]=n,i[V(n)]=t;return i}(m):null,P=[],B=0,T=!1,j=!1,$=0,z=0,G="",U=0;function q(){if(null!==M)return M;var e,t,n,i,r,a,s,o,p,l,u,c=f&&S.xmlns,d=f&&y?[]:null,h=U,g=G,E=g.length,b={},v={};e:for(;h<E;h++)if(p=!1,!(32===(l=g.charCodeAt(h))||l<14&&l>8)){for((l<65||l>122||l>90&&l<97)&&95!==l&&58!==l&&(A("illegal first char attribute name"),p=!0),u=h+1;u<E;u++)if(!((l=g.charCodeAt(u))>96&&l<123||l>64&&l<91||l>47&&l<59||46===l||45===l||95===l)){if(32===l||l<14&&l>8){A("missing attribute value"),h=u;continue e}if(61===l)break;A("illegal attribute name char"),p=!0}if("xmlns:xmlns"===(o=g.substring(h,u))&&(A("illegal declaration of xmlns"),p=!0),34===(l=g.charCodeAt(u+1)))-1===(u=g.indexOf('"',h=u+2))&&-1!==(u=g.indexOf("'",h))&&(A("attribute value quote missmatch"),p=!0);else if(39===l)-1===(u=g.indexOf("'",h=u+2))&&-1!==(u=g.indexOf('"',h))&&(A("attribute value quote missmatch"),p=!0);else for(A("missing attribute value quotes"),p=!0,u+=1;u<E&&!(32===(l=g.charCodeAt(u+1))||l<14&&l>8);u++);for(-1===u&&(A("missing closing quotes"),u=E,p=!0),p||(a=g.substring(h,u)),h=u;u+1<E&&!(32===(l=g.charCodeAt(u+1))||l<14&&l>8);u++)h===u&&(A("illegal character after attribute end"),p=!0);if(h=u+1,!p)if(o in v)A("attribute <"+o+"> already defined");else if(v[o]=!0,f)if(y){if(null!==(r="xmlns"===o?"xmlns":120===o.charCodeAt(0)&&"xmlns:"===o.substr(0,6)?o.substr(6):null)){if(e=D(a),t=V(r),!(s=m[e])){if("xmlns"===r||t in S&&S[t]!==e)do{s="ns"+B++}while(void 0!==S[s]);else s=r;m[e]=s}S[r]!==s&&(i||(S=L(S),i=!0),S[r]=s,"xmlns"===r&&(S[V(s)]=e,c=s),S[t]=e),b[o]=a;continue}d.push(o,a)}else-1!==(l=o.indexOf(":"))?(n=S[o.substring(0,l)])?((o=c===n?o.substr(l+1):n+o.substr(l))===I&&(-1!==(l=a.indexOf(":"))?(n=a.substring(0,l),a=(n=S[n]||n)+a.substring(l)):a=c+":"+a),b[o]=a):A(k(o.substring(0,l))):b[o]=a;else b[o]=a}if(y)for(h=0,E=d.length;h<E;h++){if(o=d[h++],a=d[h],-1!==(l=o.indexOf(":"))){if(!(n=S[o.substring(0,l)])){A(k(o.substring(0,l)));continue}(o=c===n?o.substr(l+1):n+o.substr(l))===I&&(-1!==(l=a.indexOf(":"))?(n=a.substring(0,l),a=(n=S[n]||n)+a.substring(l)):a=c+":"+a)}b[o]=a}return M=b}function K(){for(var t,n,i=/(\r\n|\r|\n)/g,r=0,a=0,s=0,o=z;$>=s&&(t=i.exec(e))&&!((o=t[0].length+t.index)>$);)r+=1,s=o;return-1==$?(a=o,n=e.substring(z)):0===z?n=e.substring(z,$):(a=$-s,n=-1==z?e.substring($):e.substring($,z+1)),{data:n,line:r,column:a}}c=K,l&&(w=Object.create({},{name:F((function(){return C})),originalName:F((function(){return x})),attrs:F(q),ns:F((function(){return S}))}));for(;-1!==z;){if(-1===($=60===e.charCodeAt(z)?z:e.indexOf("<",z)))return P.length?g("unexpected end of file"):0===z?g("missing start tag"):void(z<e.length&&e.substring(z).trim()&&A(O));if(z!==$)if(P.length){if(t&&(t(e.substring(z,$),D,c),h))return}else if(e.substring(z,$).trim()&&(A(O),h))return;if(33===(b=e.charCodeAt($+1))){if(91===(E=e.charCodeAt($+2))&&"CDATA["===e.substr($+3,6)){if(-1===(z=e.indexOf("]]>",$)))return g("unclosed cdata");if(r&&(r(e.substring($+9,z),c),h))return;z+=3;continue}if(45===E&&45===e.charCodeAt($+3)){if(-1===(z=e.indexOf("--\x3e",$)))return g("unclosed comment");if(s&&(s(e.substring($+4,z),D,c),h))return;z+=3;continue}}if(63!==b){for(u=$+1;;u++){if(v=e.charCodeAt(u),isNaN(v))return z=-1,g("unclosed tag");if(34===v)u=-1!==(E=e.indexOf('"',u+1))?E:u;else if(39===v)u=-1!==(E=e.indexOf("'",u+1))?E:u;else if(62===v){z=u;break}}if(33!==b){if(M={},47===b){if(T=!1,j=!0,!P.length)return g("missing open tag");if(u=C=P.pop(),E=$+2+u.length,e.substring($+2,E)!==u)return g("closing tag mismatch");for(;E<z;E++)if(!(32===(b=e.charCodeAt(E))||b>8&&b<14))return g("close tag")}else{if(47===e.charCodeAt(z-1)?(u=C=e.substring($+1,z-1),T=!0,j=!0):(u=C=e.substring($+1,z),T=!0,j=!1),!(b>96&&b<123||b>64&&b<91||95===b||58===b))return g("illegal first char nodeName");for(E=1,d=u.length;E<d;E++)if(!((b=u.charCodeAt(E))>96&&b<123||b>64&&b<91||b>47&&b<59||45===b||95===b||46==b)){if(32===b||b<14&&b>8){C=u.substring(0,E),M=null;break}return g("invalid nodeName")}j||P.push(C)}if(f){if(a=S,T&&(j||N.push(a),null===M&&(y=-1!==u.indexOf("xmlns",E))&&(U=E,G=u,q(),y=!1)),x=C,-1!==(b=C.indexOf(":"))){if(!(R=S[C.substring(0,b)]))return g("missing namespace on <"+x+">");C=C.substr(b+1)}else R=S.xmlns;R&&(C=R+":"+C)}if(T&&(U=E,G=u,n&&(l?n(w,D,j,c):n(C,q,D,j,c),h)))return;if(j){if(i&&(i(l?w:C,D,T,c),h))return;f&&(S=T?a:N.pop())}z+=1}else{if(p&&(p(e.substring($,z+1),D,c),h))return;z+=1}}else{if(-1===(z=e.indexOf("?>",$)))return g("unclosed question");if(o&&(o(e.substring($,z+2),c),h))return;z+=2}}}(e),c=j,h=!1,d},this.stop=function(){h=!0}}function G(e){return e.xml&&"lowerCase"===e.xml.tagAlias}var U={xsi:"http://www.w3.org/2001/XMLSchema-instance",xml:"http://www.w3.org/XML/1998/namespace"},q="xsi:type";function K(e){return e.xml&&e.xml.serialize}function _(e){return K(e)===q}function H(e,t){return G(t)?e.prefix+":"+((n=e.localName).charAt(0).toUpperCase()+n.slice(1)):e.name;var n}function X(e){return new Error(e)}function W(e){return e.$descriptor}function Q(e){u(this,e),this.elementsById={},this.references=[],this.warnings=[],this.addReference=function(e){this.references.push(e)},this.addElement=function(e){if(!e)throw X("expected element");var t,n=this.elementsById,i=W(e).idProperty;if(i&&(t=e.get(i.name))){if(!/^([a-z][\w-.]*:)?[a-z_][\w-.]*$/i.test(t))throw new Error("illegal ID <"+t+">");if(n[t])throw X("duplicate ID <"+t+">");n[t]=e}},this.addWarning=function(e){this.warnings.push(e)}}function J(){}function Y(){}function Z(){}function ee(e,t){this.property=e,this.context=t}function te(e,t){this.element=t,this.propertyDesc=e}function ne(){}function ie(e,t,n){this.model=e,this.type=e.getType(t),this.context=n}function re(e,t,n){ie.call(this,e,t,n)}function ae(e,t,n){this.model=e,this.context=n}function se(e){e instanceof w&&(e={model:e}),u(this,{lax:!1},e)}J.prototype.handleEnd=function(){},J.prototype.handleText=function(){},J.prototype.handleNode=function(){},Y.prototype=Object.create(J.prototype),Y.prototype.handleNode=function(){return this},Z.prototype=Object.create(J.prototype),Z.prototype.handleText=function(e){this.body=(this.body||"")+e},ee.prototype=Object.create(Z.prototype),ee.prototype.handleNode=function(e){if(this.element)throw X("expected no sub nodes");return this.element=this.createReference(e),this},ee.prototype.handleEnd=function(){this.element.id=this.body},ee.prototype.createReference=function(e){return{property:this.property.ns.name,id:""}},te.prototype=Object.create(Z.prototype),te.prototype.handleEnd=function(){var e=this.body||"",t=this.element,n=this.propertyDesc;e=h(n.type,e),n.isMany?t.get(n.name).push(e):t.set(n.name,e)},ne.prototype=Object.create(Z.prototype),ne.prototype.handleNode=function(e){var t=this,n=this.element;return n?t=this.handleChild(e):(n=this.element=this.createElement(e),this.context.addElement(n)),t},ie.prototype=Object.create(ne.prototype),ie.prototype.addReference=function(e){this.context.addReference(e)},ie.prototype.handleText=function(e){if(!W(this.element).bodyProperty)throw X("unexpected body text <"+e+">");Z.prototype.handleText.call(this,e)},ie.prototype.handleEnd=function(){var e=this.body,t=this.element,n=W(t).bodyProperty;n&&void 0!==e&&(e=h(n.type,e),t.set(n.name,e))},ie.prototype.createElement=function(e){var t,n=e.attributes,i=this.type,r=W(i),a=this.context,o=new i({}),p=this.model;return s(n,(function(e,n){var i=r.propertiesByName[n];i&&i.isReference?i.isMany?s(e.split(" "),(function(e){a.addReference({element:o,property:i.ns.name,id:e})})):a.addReference({element:o,property:i.ns.name,id:e}):(i?e=h(i.type,e):"xmlns"!==n&&(t=E(n,r.ns.prefix),p.getPackage(t.prefix)&&a.addWarning({message:"unknown attribute <"+n+">",element:o,property:n,value:e})),o.set(n,e))})),o},ie.prototype.getPropertyForNode=function(e){var t,n,i=E(e.name),a=this.type,s=this.model,o=W(a),p=i.name,m=o.propertiesByName[p];if(m&&!m.isAttr)return _(m)&&(t=e.attributes[q])?(t=function(e,t){var n=E(e);return function(e,t){var n=e.name,i=e.localName,r=t.xml&&t.xml.typePrefix;return r&&0===i.indexOf(r)?e.prefix+":"+i.slice(r.length):n}(n,t.getPackage(n.prefix))}(t,s),u({},m,{effectiveType:W(n=s.getType(t)).name})):m;var l=s.getPackage(i.prefix);if(l){if(t=H(i,l),n=s.getType(t),m=r(o.properties,(function(e){return!e.isVirtual&&!e.isReference&&!e.isAttribute&&n.hasType(e.type)})))return u({},m,{effectiveType:W(n).name})}else if(m=r(o.properties,(function(e){return!e.isReference&&!e.isAttribute&&"Element"===e.type})))return m;throw X("unrecognized element <"+i.name+">")},ie.prototype.toString=function(){return"ElementDescriptor["+W(this.type).name+"]"},ie.prototype.valueHandler=function(e,t){return new te(e,t)},ie.prototype.referenceHandler=function(e){return new ee(e,this.context)},ie.prototype.handler=function(e){return"Element"===e?new ae(this.model,e,this.context):new ie(this.model,e,this.context)},ie.prototype.handleChild=function(e){var t,n,i,r;if(t=this.getPropertyForNode(e),i=this.element,A(n=t.effectiveType||t.type))return this.valueHandler(t,i);var a=(r=t.isReference?this.referenceHandler(t).handleNode(e):this.handler(n).handleNode(e)).element;return void 0!==a&&(t.isMany?i.get(t.name).push(a):i.set(t.name,a),t.isReference?(u(a,{element:i}),this.context.addReference(a)):a.$parent=i),r},re.prototype=Object.create(ie.prototype),re.prototype.createElement=function(e){var t=e.name,n=E(t),i=this.model,r=this.type,a=i.getPackage(n.prefix),s=a&&H(n,a)||t;if(!r.hasType(s))throw X("unexpected element <"+e.originalName+">");return ie.prototype.createElement.call(this,e)},ae.prototype=Object.create(ne.prototype),ae.prototype.createElement=function(e){var t=e.name,n=E(t).prefix,i=e.ns[n+"$uri"],r=e.attributes;return this.model.createAny(t,i,r)},ae.prototype.handleChild=function(e){var t=new ae(this.model,"Element",this.context).handleNode(e),n=this.element,i=t.element;return void 0!==i&&((n.$children=n.$children||[]).push(i),i.$parent=n),t},ae.prototype.handleEnd=function(){this.body&&(this.element.$body=this.body)},se.prototype.fromXML=function(e,t,n){var i=t.rootHandler;t instanceof ie?(i=t,t={}):"string"==typeof t?(i=this.handler(t),t={}):"string"==typeof i&&(i=this.handler(i));var r=this.model,a=this.lax,s=new Q(u({},t,{rootHandler:i})),o=new z({proxy:!0}),p=function(){var e=[];return Object.defineProperty(e,"peek",{value:function(){return this[this.length-1]}}),e}();function m(e,t,n){var i=t(),r=i.line,a=i.column,o=i.data;"<"===o.charAt(0)&&-1!==o.indexOf(" ")&&(o=o.slice(0,o.indexOf(" "))+">");var p="unparsable content "+(o?o+" ":"")+"detected\n\tline: "+r+"\n\tcolumn: "+a+"\n\tnested error: "+e.message;if(n)return s.addWarning({message:p,error:e}),!0;throw X(p)}function l(e,t){return m(e,t,!0)}i.context=s,p.push(i);var c=/^<\?xml /i,y=/ encoding="([^"]+)"/i,f=/^utf-8$/i;function d(e,t){try{p.peek().handleText(e)}catch(e){l(e,t)}}var h=r.getPackages().reduce((function(e,t){return e[t.uri]=t.prefix,e}),{"http://www.w3.org/XML/1998/namespace":"xml"});return o.ns(h).on("openTag",(function(e,t,n,i){var r=e.attrs||{},s=Object.keys(r).reduce((function(e,n){var i=t(r[n]);return e[n]=i,e}),{});!function(e,t){var n=p.peek();try{p.push(n.handleNode(e))}catch(e){m(e,t,a)&&p.push(new Y)}}({name:e.name,originalName:e.originalName,attributes:s,ns:e.ns},i)})).on("question",(function(e){if(c.test(e)){var t=y.exec(e),n=t&&t[1];n&&!f.test(n)&&s.addWarning({message:"unsupported document encoding <"+n+">, falling back to UTF-8"})}})).on("closeTag",(function(){p.pop().handleEnd()})).on("cdata",d).on("text",(function(e,t,n){!function(e,t){e.trim()&&d(e,t)}(t(e),n)})).on("error",m).on("warn",l),new Promise((function(t,n){var r;try{o.parse(e),function(){var e,t,n=s.elementsById,i=s.references;for(e=0;t=i[e];e++){var r=t.element,a=n[t.id],o=W(r).propertiesByName[t.property];if(a||s.addWarning({message:"unresolved reference <"+t.id+">",element:t.element,property:t.property,value:t.id}),o.isMany){var p=r.get(o.name),m=p.indexOf(t);-1===m&&(m=p.length),a?p[m]=a:p.splice(m,1)}else r.set(o.name,a)}}()}catch(e){r=e}var a=i.element;r||a||(r=X("failed to parse document as <"+i.type.$descriptor.name+">"));var p=s.warnings,m=s.references,l=s.elementsById;return r?(r.warnings=p,n(r)):t({rootElement:a,elementsById:l,references:m,warnings:p})}))},se.prototype.handler=function(e){return new re(this.model,e)};var oe=/<|>|'|"|&|\n\r|\n/g,pe=/<|>|&/g;function me(e){var t={},n={},i={},r=[],a=[];this.byUri=function(t){return n[t]||e&&e.byUri(t)},this.add=function(e,t){n[e.uri]=e,t?r.push(e):a.push(e),this.mapPrefix(e.prefix,e.uri)},this.uriByPrefix=function(e){return t[e||"xmlns"]},this.mapPrefix=function(e,n){t[e||"xmlns"]=n},this.getNSKey=function(e){return void 0!==e.prefix?e.uri+"|"+e.prefix:e.uri},this.logUsed=function(t){var n=t.uri,r=this.getNSKey(t);i[r]=this.byUri(n),e&&e.logUsed(t)},this.getUsed=function(e){var t=this;return[].concat(r,a).filter((function(e){var n=t.getNSKey(e);return i[n]}))}}function le(e,t){return G(t)?(n=e).charAt(0).toLowerCase()+n.slice(1):e;var n}function ue(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function ce(e){return n(e)?e:(e.prefix?e.prefix+":":"")+e.localName}var ye={"\n":"#10","\n\r":"#10",'"':"#34","'":"#39","<":"#60",">":"#62","&":"#38"},fe={"<":"lt",">":"gt","&":"amp"};function de(e,t,i){return(e=n(e)?e:""+e).replace(t,(function(e){return"&"+i[e]+";"}))}function he(e){this.tagName=e}function ge(){}function Ae(e){this.tagName=e}function Ee(e,t){this.body=[],this.attrs=[],this.parent=e,this.propertyDescriptor=t}function be(e,t){Ee.call(this,e,t)}function ve(){this.value="",this.write=function(e){this.value+=e}}function Re(e,t){var n=[""];this.append=function(t){return e.write(t),this},this.appendNewLine=function(){return t&&e.write("\n"),this},this.appendIndent=function(){return t&&e.write(n.join(" ")),this},this.indent=function(){return n.push(""),this},this.unindent=function(){return n.pop(),this}}function Ce(e){return e=u({format:!1,preamble:!0},e||{}),{toXML:function(t,n){var i=n||new ve,r=new Re(i,e.format);if(e.preamble&&r.append('<?xml version="1.0" encoding="UTF-8"?>\n'),(new Ee).build(t).serializeTo(r),!n)return i.value}}}function xe(e,t){w.call(this,e,t)}he.prototype.build=function(e){return this.element=e,this},he.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"+this.element.id+"</"+this.tagName+">").appendNewLine()},ge.prototype.serializeValue=ge.prototype.serializeTo=function(e){e.append(this.escape?de(this.value,pe,fe):this.value)},ge.prototype.build=function(e,t){return this.value=t,"String"===e.type&&-1!==t.search(pe)&&(this.escape=!0),this},ue(Ae,ge),Ae.prototype.serializeTo=function(e){e.appendIndent().append("<"+this.tagName+">"),this.serializeValue(e),e.append("</"+this.tagName+">").appendNewLine()},Ee.prototype.build=function(e){this.element=e;var t,n,r=e.$descriptor,s=this.propertyDescriptor,o=r.isGeneric;return t=o?this.parseGeneric(e):this.parseNsAttributes(e),this.ns=s?this.nsPropertyTagName(s):this.nsTagName(r),this.tagName=this.addTagName(this.ns),o||(n=function(e){return a(e.$descriptor.properties,(function(t){var n=t.name;if(t.isVirtual)return!1;if(!i(e,n))return!1;var r=e[n];return r!==t.default&&null!==r&&(!t.isMany||r.length)}))}(e),this.parseAttributes(a(n,(function(e){return e.isAttr}))),this.parseContainments(function(e){return a(e,(function(e){return!e.isAttr}))}(n))),this.parseGenericAttributes(e,t),this},Ee.prototype.nsTagName=function(e){return function(e,t){return t.isGeneric?u({localName:t.ns.localName},e):u({localName:le(t.ns.localName,t.$pkg)},e)}(this.logNamespaceUsed(e.ns),e)},Ee.prototype.nsPropertyTagName=function(e){return function(e,t){return u({localName:t.ns.localName},e)}(this.logNamespaceUsed(e.ns),e)},Ee.prototype.isLocalNs=function(e){return e.uri===this.ns.uri},Ee.prototype.nsAttributeName=function(e){var t;if(t=n(e)?E(e):e.ns,e.inherited)return{localName:t.localName};var i=this.logNamespaceUsed(t);return this.getNamespaces().logUsed(i),this.isLocalNs(i)?{localName:t.localName}:u({localName:t.localName},i)},Ee.prototype.parseGeneric=function(e){var t=this,n=this.body,i=[];return s(e,(function(r,a){"$body"===a?n.push((new ge).build({type:"String"},r)):"$children"===a?s(r,(function(e){n.push(new Ee(t).build(e))})):0!==a.indexOf("$")&&t.parseNsAttribute(e,a,r)&&i.push({name:a,value:r})})),i},Ee.prototype.parseNsAttribute=function(e,t,n){var i,r=e.$model,a=E(t);if("xmlns"===a.prefix&&(i={prefix:a.localName,uri:n}),a.prefix||"xmlns"!==a.localName||(i={uri:n}),!i)return{name:t,value:n};if(r&&r.getPackage(n))this.logNamespace(i,!0,!0);else{var s=this.logNamespaceUsed(i,!0);this.getNamespaces().logUsed(s)}},Ee.prototype.parseNsAttributes=function(e,t){var n=this,i=e.$attrs,r=[];return s(i,(function(t,i){var a=n.parseNsAttribute(e,i,t);a&&r.push(a)})),r},Ee.prototype.parseGenericAttributes=function(e,t){var n=this;s(t,(function(t){if(t.name!==q)try{n.addAttribute(n.nsAttributeName(t.name),t.value)}catch(n){console.warn("missing namespace information for ",t.name,"=",t.value,"on",e,n)}}))},Ee.prototype.parseContainments=function(e){var t=this,n=this.body,i=this.element;s(e,(function(e){var r=i.get(e.name),a=e.isReference;if(e.isMany||(r=[r]),e.isBody)n.push((new ge).build(e,r[0]));else if(A(e.type))s(r,(function(i){n.push(new Ae(t.addTagName(t.nsPropertyTagName(e))).build(e,i))}));else if(a)s(r,(function(i){n.push(new he(t.addTagName(t.nsPropertyTagName(e))).build(i))}));else{var o=_(e),p=function(e){return"property"===K(e)}(e);s(r,(function(i){var r;r=o?new be(t,e):p?new Ee(t,e):new Ee(t),n.push(r.build(i))}))}}))},Ee.prototype.getNamespaces=function(e){var t,n=this.namespaces,i=this.parent;return n||(t=i&&i.getNamespaces(),e||!t?this.namespaces=n=new me(t):n=t),n},Ee.prototype.logNamespace=function(e,t,n){var i=this.getNamespaces(n),r=e.uri,a=e.prefix;return i.byUri(r)&&!n||i.add(e,t),i.mapPrefix(a,r),e},Ee.prototype.logNamespaceUsed=function(e,t){var n,i,r,a=this.element.$model,s=this.getNamespaces(t),o=e.prefix,p=e.uri;if(!o&&!p)return{localName:e.localName};if(r=U[o]||a&&(a.getPackage(o)||{}).uri,!(p=p||r||s.uriByPrefix(o)))throw new Error("no namespace uri given for prefix <"+o+">");if(!(e=s.byUri(p))){for(n=o,i=1;s.uriByPrefix(n);)n=o+"_"+i++;e=this.logNamespace({prefix:n,uri:p},r===p)}return o&&s.mapPrefix(o,p),e},Ee.prototype.parseAttributes=function(e){var t=this,n=this.element;s(e,(function(e){var i=n.get(e.name);if(e.isReference)if(e.isMany){var r=[];s(i,(function(e){r.push(e.id)})),i=r.join(" ")}else i=i.id;t.addAttribute(t.nsAttributeName(e),i)}))},Ee.prototype.addTagName=function(e){var t=this.logNamespaceUsed(e);return this.getNamespaces().logUsed(t),ce(e)},Ee.prototype.addAttribute=function(e,t){var i=this.attrs;n(t)&&(t=de(t,oe,ye)),i.push({name:e,value:t})},Ee.prototype.serializeAttributes=function(e){var t=this.attrs,n=this.namespaces;n&&(t=function(e){return e.getUsed().filter((function(e){return"xml"!==e.prefix})).map((function(e){return{name:"xmlns"+(e.prefix?":"+e.prefix:""),value:e.uri}}))}(n).concat(t)),s(t,(function(t){e.append(" ").append(ce(t.name)).append('="').append(t.value).append('"')}))},Ee.prototype.serializeTo=function(e){var t=this.body[0],n=t&&t.constructor!==ge;e.appendIndent().append("<"+this.tagName),this.serializeAttributes(e),e.append(t?">":" />"),t&&(n&&e.appendNewLine().indent(),s(this.body,(function(t){t.serializeTo(e)})),n&&e.unindent().appendIndent(),e.append("</"+this.tagName+">")),e.appendNewLine()},ue(be,Ee),be.prototype.parseNsAttributes=function(e){var t=Ee.prototype.parseNsAttributes.call(this,e),n=e.$descriptor;if(n.name===this.propertyDescriptor.type)return t;var i=this.typeNs=this.nsTagName(n);this.getNamespaces().logUsed(this.typeNs);var r=e.$model.getPackage(i.uri),a=r.xml&&r.xml.typePrefix||"";return this.addAttribute(this.nsAttributeName(q),(i.prefix?i.prefix+":":"")+a+n.ns.localName),t},be.prototype.isLocalNs=function(e){return e.uri===(this.typeNs||this.ns).uri},xe.prototype=Object.create(w.prototype),xe.prototype.fromXML=function(e,t,i){n(t)||(i=t,t="bpmn:Definitions");var r=new se(u({model:this,lax:!0},i)),a=r.handler(t);return r.fromXML(e,a)},xe.prototype.toXML=function(e,t){var n=new Ce(t);return new Promise((function(t,i){try{return t({xml:n.toXML(e)})}catch(e){return i(e)}}))};var we={bpmn:{name:"BPMN20",uri:"http://www.omg.org/spec/BPMN/20100524/MODEL",prefix:"bpmn",associations:[],types:[{name:"Interface",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"operations",type:"Operation",isMany:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"Operation",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"inMessageRef",type:"Message",isReference:!0},{name:"outMessageRef",type:"Message",isReference:!0},{name:"errorRef",type:"Error",isMany:!0,isReference:!0},{name:"implementationRef",isAttr:!0,type:"String"}]},{name:"EndPoint",superClass:["RootElement"]},{name:"Auditing",superClass:["BaseElement"]},{name:"GlobalTask",superClass:["CallableElement"],properties:[{name:"resources",type:"ResourceRole",isMany:!0}]},{name:"Monitoring",superClass:["BaseElement"]},{name:"Performer",superClass:["ResourceRole"]},{name:"Process",superClass:["FlowElementsContainer","CallableElement"],properties:[{name:"processType",type:"ProcessType",isAttr:!0},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"properties",type:"Property",isMany:!0},{name:"laneSets",isMany:!0,replaces:"FlowElementsContainer#laneSets",type:"LaneSet"},{name:"flowElements",isMany:!0,replaces:"FlowElementsContainer#flowElements",type:"FlowElement"},{name:"artifacts",type:"Artifact",isMany:!0},{name:"resources",type:"ResourceRole",isMany:!0},{name:"correlationSubscriptions",type:"CorrelationSubscription",isMany:!0},{name:"supports",type:"Process",isMany:!0,isReference:!0},{name:"definitionalCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"isExecutable",isAttr:!0,type:"Boolean"}]},{name:"LaneSet",superClass:["BaseElement"],properties:[{name:"lanes",type:"Lane",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Lane",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"partitionElementRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"partitionElement",type:"BaseElement"},{name:"flowNodeRef",type:"FlowNode",isMany:!0,isReference:!0},{name:"childLaneSet",type:"LaneSet",xml:{serialize:"xsi:type"}}]},{name:"GlobalManualTask",superClass:["GlobalTask"]},{name:"ManualTask",superClass:["Task"]},{name:"UserTask",superClass:["Task"],properties:[{name:"renderings",type:"Rendering",isMany:!0},{name:"implementation",isAttr:!0,type:"String"}]},{name:"Rendering",superClass:["BaseElement"]},{name:"HumanPerformer",superClass:["Performer"]},{name:"PotentialOwner",superClass:["HumanPerformer"]},{name:"GlobalUserTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"renderings",type:"Rendering",isMany:!0}]},{name:"Gateway",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"gatewayDirection",type:"GatewayDirection",default:"Unspecified",isAttr:!0}]},{name:"EventBasedGateway",superClass:["Gateway"],properties:[{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"eventGatewayType",type:"EventBasedGatewayType",isAttr:!0,default:"Exclusive"}]},{name:"ComplexGateway",superClass:["Gateway"],properties:[{name:"activationCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ExclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"InclusiveGateway",superClass:["Gateway"],properties:[{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0}]},{name:"ParallelGateway",superClass:["Gateway"]},{name:"RootElement",isAbstract:!0,superClass:["BaseElement"]},{name:"Relationship",superClass:["BaseElement"],properties:[{name:"type",isAttr:!0,type:"String"},{name:"direction",type:"RelationshipDirection",isAttr:!0},{name:"source",isMany:!0,isReference:!0,type:"Element"},{name:"target",isMany:!0,isReference:!0,type:"Element"}]},{name:"BaseElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,type:"String",isId:!0},{name:"documentation",type:"Documentation",isMany:!0},{name:"extensionDefinitions",type:"ExtensionDefinition",isMany:!0,isReference:!0},{name:"extensionElements",type:"ExtensionElements"}]},{name:"Extension",properties:[{name:"mustUnderstand",default:!1,isAttr:!0,type:"Boolean"},{name:"definition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"extensionAttributeDefinitions",type:"ExtensionAttributeDefinition",isMany:!0}]},{name:"ExtensionAttributeDefinition",properties:[{name:"name",isAttr:!0,type:"String"},{name:"type",isAttr:!0,type:"String"},{name:"isReference",default:!1,isAttr:!0,type:"Boolean"},{name:"extensionDefinition",type:"ExtensionDefinition",isAttr:!0,isReference:!0}]},{name:"ExtensionElements",properties:[{name:"valueRef",isAttr:!0,isReference:!0,type:"Element"},{name:"values",type:"Element",isMany:!0},{name:"extensionAttributeDefinition",type:"ExtensionAttributeDefinition",isAttr:!0,isReference:!0}]},{name:"Documentation",superClass:["BaseElement"],properties:[{name:"text",type:"String",isBody:!0},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Event",isAbstract:!0,superClass:["FlowNode","InteractionNode"],properties:[{name:"properties",type:"Property",isMany:!0}]},{name:"IntermediateCatchEvent",superClass:["CatchEvent"]},{name:"IntermediateThrowEvent",superClass:["ThrowEvent"]},{name:"EndEvent",superClass:["ThrowEvent"]},{name:"StartEvent",superClass:["CatchEvent"],properties:[{name:"isInterrupting",default:!0,isAttr:!0,type:"Boolean"}]},{name:"ThrowEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"inputSet",type:"InputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"CatchEvent",isAbstract:!0,superClass:["Event"],properties:[{name:"parallelMultiple",isAttr:!0,type:"Boolean",default:!1},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"outputSet",type:"OutputSet"},{name:"eventDefinitions",type:"EventDefinition",isMany:!0},{name:"eventDefinitionRef",type:"EventDefinition",isMany:!0,isReference:!0}]},{name:"BoundaryEvent",superClass:["CatchEvent"],properties:[{name:"cancelActivity",default:!0,isAttr:!0,type:"Boolean"},{name:"attachedToRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"EventDefinition",isAbstract:!0,superClass:["RootElement"]},{name:"CancelEventDefinition",superClass:["EventDefinition"]},{name:"ErrorEventDefinition",superClass:["EventDefinition"],properties:[{name:"errorRef",type:"Error",isAttr:!0,isReference:!0}]},{name:"TerminateEventDefinition",superClass:["EventDefinition"]},{name:"EscalationEventDefinition",superClass:["EventDefinition"],properties:[{name:"escalationRef",type:"Escalation",isAttr:!0,isReference:!0}]},{name:"Escalation",properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"escalationCode",isAttr:!0,type:"String"}],superClass:["RootElement"]},{name:"CompensateEventDefinition",superClass:["EventDefinition"],properties:[{name:"waitForCompletion",isAttr:!0,type:"Boolean",default:!0},{name:"activityRef",type:"Activity",isAttr:!0,isReference:!0}]},{name:"TimerEventDefinition",superClass:["EventDefinition"],properties:[{name:"timeDate",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeCycle",type:"Expression",xml:{serialize:"xsi:type"}},{name:"timeDuration",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"LinkEventDefinition",superClass:["EventDefinition"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"target",type:"LinkEventDefinition",isAttr:!0,isReference:!0},{name:"source",type:"LinkEventDefinition",isMany:!0,isReference:!0}]},{name:"MessageEventDefinition",superClass:["EventDefinition"],properties:[{name:"messageRef",type:"Message",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"ConditionalEventDefinition",superClass:["EventDefinition"],properties:[{name:"condition",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"SignalEventDefinition",superClass:["EventDefinition"],properties:[{name:"signalRef",type:"Signal",isAttr:!0,isReference:!0}]},{name:"Signal",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ImplicitThrowEvent",superClass:["ThrowEvent"]},{name:"DataState",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"ItemAwareElement",superClass:["BaseElement"],properties:[{name:"itemSubjectRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"dataState",type:"DataState"}]},{name:"DataAssociation",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"ItemAwareElement",isMany:!0,isReference:!0},{name:"targetRef",type:"ItemAwareElement",isReference:!0},{name:"transformation",type:"FormalExpression",xml:{serialize:"property"}},{name:"assignment",type:"Assignment",isMany:!0}]},{name:"DataInput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"inputSetRef",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithOptional",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"inputSetWithWhileExecuting",type:"InputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"DataOutput",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"outputSetRef",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithOptional",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0},{name:"outputSetWithWhileExecuting",type:"OutputSet",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"InputSet",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"dataInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"optionalInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"whileExecutingInputRefs",type:"DataInput",isMany:!0,isReference:!0},{name:"outputSetRefs",type:"OutputSet",isMany:!0,isReference:!0}]},{name:"OutputSet",superClass:["BaseElement"],properties:[{name:"dataOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"inputSetRefs",type:"InputSet",isMany:!0,isReference:!0},{name:"optionalOutputRefs",type:"DataOutput",isMany:!0,isReference:!0},{name:"whileExecutingOutputRefs",type:"DataOutput",isMany:!0,isReference:!0}]},{name:"Property",superClass:["ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"}]},{name:"DataInputAssociation",superClass:["DataAssociation"]},{name:"DataOutputAssociation",superClass:["DataAssociation"]},{name:"InputOutputSpecification",superClass:["BaseElement"],properties:[{name:"dataInputs",type:"DataInput",isMany:!0},{name:"dataOutputs",type:"DataOutput",isMany:!0},{name:"inputSets",type:"InputSet",isMany:!0},{name:"outputSets",type:"OutputSet",isMany:!0}]},{name:"DataObject",superClass:["FlowElement","ItemAwareElement"],properties:[{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"}]},{name:"InputOutputBinding",properties:[{name:"inputDataRef",type:"InputSet",isAttr:!0,isReference:!0},{name:"outputDataRef",type:"OutputSet",isAttr:!0,isReference:!0},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"Assignment",superClass:["BaseElement"],properties:[{name:"from",type:"Expression",xml:{serialize:"xsi:type"}},{name:"to",type:"Expression",xml:{serialize:"xsi:type"}}]},{name:"DataStore",superClass:["RootElement","ItemAwareElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"capacity",isAttr:!0,type:"Integer"},{name:"isUnlimited",default:!0,isAttr:!0,type:"Boolean"}]},{name:"DataStoreReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataStoreRef",type:"DataStore",isAttr:!0,isReference:!0}]},{name:"DataObjectReference",superClass:["ItemAwareElement","FlowElement"],properties:[{name:"dataObjectRef",type:"DataObject",isAttr:!0,isReference:!0}]},{name:"ConversationLink",superClass:["BaseElement"],properties:[{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"ConversationAssociation",superClass:["BaseElement"],properties:[{name:"innerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0},{name:"outerConversationNodeRef",type:"ConversationNode",isAttr:!0,isReference:!0}]},{name:"CallConversation",superClass:["ConversationNode"],properties:[{name:"calledCollaborationRef",type:"Collaboration",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"Conversation",superClass:["ConversationNode"]},{name:"SubConversation",superClass:["ConversationNode"],properties:[{name:"conversationNodes",type:"ConversationNode",isMany:!0}]},{name:"ConversationNode",isAbstract:!0,superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"messageFlowRefs",type:"MessageFlow",isMany:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0}]},{name:"GlobalConversation",superClass:["Collaboration"]},{name:"PartnerEntity",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"PartnerRole",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"participantRef",type:"Participant",isMany:!0,isReference:!0}]},{name:"CorrelationProperty",superClass:["RootElement"],properties:[{name:"correlationPropertyRetrievalExpression",type:"CorrelationPropertyRetrievalExpression",isMany:!0},{name:"name",isAttr:!0,type:"String"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Error",superClass:["RootElement"],properties:[{name:"structureRef",type:"ItemDefinition",isAttr:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"},{name:"errorCode",isAttr:!0,type:"String"}]},{name:"CorrelationKey",superClass:["BaseElement"],properties:[{name:"correlationPropertyRef",type:"CorrelationProperty",isMany:!0,isReference:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Expression",superClass:["BaseElement"],isAbstract:!1,properties:[{name:"body",isBody:!0,type:"String"}]},{name:"FormalExpression",superClass:["Expression"],properties:[{name:"language",isAttr:!0,type:"String"},{name:"evaluatesToTypeRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"Message",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"itemRef",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"ItemDefinition",superClass:["RootElement"],properties:[{name:"itemKind",type:"ItemKind",isAttr:!0},{name:"structureRef",isAttr:!0,type:"String"},{name:"isCollection",default:!1,isAttr:!0,type:"Boolean"},{name:"import",type:"Import",isAttr:!0,isReference:!0}]},{name:"FlowElement",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"auditing",type:"Auditing"},{name:"monitoring",type:"Monitoring"},{name:"categoryValueRef",type:"CategoryValue",isMany:!0,isReference:!0}]},{name:"SequenceFlow",superClass:["FlowElement"],properties:[{name:"isImmediate",isAttr:!0,type:"Boolean"},{name:"conditionExpression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"sourceRef",type:"FlowNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"FlowNode",isAttr:!0,isReference:!0}]},{name:"FlowElementsContainer",isAbstract:!0,superClass:["BaseElement"],properties:[{name:"laneSets",type:"LaneSet",isMany:!0},{name:"flowElements",type:"FlowElement",isMany:!0}]},{name:"CallableElement",isAbstract:!0,superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"supportedInterfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"ioBinding",type:"InputOutputBinding",isMany:!0,xml:{serialize:"property"}}]},{name:"FlowNode",isAbstract:!0,superClass:["FlowElement"],properties:[{name:"incoming",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"outgoing",type:"SequenceFlow",isMany:!0,isReference:!0},{name:"lanes",type:"Lane",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"CorrelationPropertyRetrievalExpression",superClass:["BaseElement"],properties:[{name:"messagePath",type:"FormalExpression"},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"CorrelationPropertyBinding",superClass:["BaseElement"],properties:[{name:"dataPath",type:"FormalExpression"},{name:"correlationPropertyRef",type:"CorrelationProperty",isAttr:!0,isReference:!0}]},{name:"Resource",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"resourceParameters",type:"ResourceParameter",isMany:!0}]},{name:"ResourceParameter",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isRequired",isAttr:!0,type:"Boolean"},{name:"type",type:"ItemDefinition",isAttr:!0,isReference:!0}]},{name:"CorrelationSubscription",superClass:["BaseElement"],properties:[{name:"correlationKeyRef",type:"CorrelationKey",isAttr:!0,isReference:!0},{name:"correlationPropertyBinding",type:"CorrelationPropertyBinding",isMany:!0}]},{name:"MessageFlow",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"sourceRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"targetRef",type:"InteractionNode",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"MessageFlowAssociation",superClass:["BaseElement"],properties:[{name:"innerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0},{name:"outerMessageFlowRef",type:"MessageFlow",isAttr:!0,isReference:!0}]},{name:"InteractionNode",isAbstract:!0,properties:[{name:"incomingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0},{name:"outgoingConversationLinks",type:"ConversationLink",isMany:!0,isVirtual:!0,isReference:!0}]},{name:"Participant",superClass:["InteractionNode","BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"interfaceRef",type:"Interface",isMany:!0,isReference:!0},{name:"participantMultiplicity",type:"ParticipantMultiplicity"},{name:"endPointRefs",type:"EndPoint",isMany:!0,isReference:!0},{name:"processRef",type:"Process",isAttr:!0,isReference:!0}]},{name:"ParticipantAssociation",superClass:["BaseElement"],properties:[{name:"innerParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"outerParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"ParticipantMultiplicity",properties:[{name:"minimum",default:0,isAttr:!0,type:"Integer"},{name:"maximum",default:1,isAttr:!0,type:"Integer"}],superClass:["BaseElement"]},{name:"Collaboration",superClass:["RootElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"isClosed",isAttr:!0,type:"Boolean"},{name:"participants",type:"Participant",isMany:!0},{name:"messageFlows",type:"MessageFlow",isMany:!0},{name:"artifacts",type:"Artifact",isMany:!0},{name:"conversations",type:"ConversationNode",isMany:!0},{name:"conversationAssociations",type:"ConversationAssociation"},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0},{name:"messageFlowAssociations",type:"MessageFlowAssociation",isMany:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"choreographyRef",type:"Choreography",isMany:!0,isReference:!0},{name:"conversationLinks",type:"ConversationLink",isMany:!0}]},{name:"ChoreographyActivity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"participantRef",type:"Participant",isMany:!0,isReference:!0},{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0},{name:"correlationKeys",type:"CorrelationKey",isMany:!0},{name:"loopType",type:"ChoreographyLoopType",default:"None",isAttr:!0}]},{name:"CallChoreography",superClass:["ChoreographyActivity"],properties:[{name:"calledChoreographyRef",type:"Choreography",isAttr:!0,isReference:!0},{name:"participantAssociations",type:"ParticipantAssociation",isMany:!0}]},{name:"SubChoreography",superClass:["ChoreographyActivity","FlowElementsContainer"],properties:[{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"ChoreographyTask",superClass:["ChoreographyActivity"],properties:[{name:"messageFlowRef",type:"MessageFlow",isMany:!0,isReference:!0}]},{name:"Choreography",superClass:["Collaboration","FlowElementsContainer"]},{name:"GlobalChoreographyTask",superClass:["Choreography"],properties:[{name:"initiatingParticipantRef",type:"Participant",isAttr:!0,isReference:!0}]},{name:"TextAnnotation",superClass:["Artifact"],properties:[{name:"text",type:"String"},{name:"textFormat",default:"text/plain",isAttr:!0,type:"String"}]},{name:"Group",superClass:["Artifact"],properties:[{name:"categoryValueRef",type:"CategoryValue",isAttr:!0,isReference:!0}]},{name:"Association",superClass:["Artifact"],properties:[{name:"associationDirection",type:"AssociationDirection",isAttr:!0},{name:"sourceRef",type:"BaseElement",isAttr:!0,isReference:!0},{name:"targetRef",type:"BaseElement",isAttr:!0,isReference:!0}]},{name:"Category",superClass:["RootElement"],properties:[{name:"categoryValue",type:"CategoryValue",isMany:!0},{name:"name",isAttr:!0,type:"String"}]},{name:"Artifact",isAbstract:!0,superClass:["BaseElement"]},{name:"CategoryValue",superClass:["BaseElement"],properties:[{name:"categorizedFlowElements",type:"FlowElement",isMany:!0,isVirtual:!0,isReference:!0},{name:"value",isAttr:!0,type:"String"}]},{name:"Activity",isAbstract:!0,superClass:["FlowNode"],properties:[{name:"isForCompensation",default:!1,isAttr:!0,type:"Boolean"},{name:"default",type:"SequenceFlow",isAttr:!0,isReference:!0},{name:"ioSpecification",type:"InputOutputSpecification",xml:{serialize:"property"}},{name:"boundaryEventRefs",type:"BoundaryEvent",isMany:!0,isReference:!0},{name:"properties",type:"Property",isMany:!0},{name:"dataInputAssociations",type:"DataInputAssociation",isMany:!0},{name:"dataOutputAssociations",type:"DataOutputAssociation",isMany:!0},{name:"startQuantity",default:1,isAttr:!0,type:"Integer"},{name:"resources",type:"ResourceRole",isMany:!0},{name:"completionQuantity",default:1,isAttr:!0,type:"Integer"},{name:"loopCharacteristics",type:"LoopCharacteristics"}]},{name:"ServiceTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0}]},{name:"SubProcess",superClass:["Activity","FlowElementsContainer","InteractionNode"],properties:[{name:"triggeredByEvent",default:!1,isAttr:!0,type:"Boolean"},{name:"artifacts",type:"Artifact",isMany:!0}]},{name:"LoopCharacteristics",isAbstract:!0,superClass:["BaseElement"]},{name:"MultiInstanceLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"isSequential",default:!1,isAttr:!0,type:"Boolean"},{name:"behavior",type:"MultiInstanceBehavior",default:"All",isAttr:!0},{name:"loopCardinality",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopDataInputRef",type:"ItemAwareElement",isReference:!0},{name:"loopDataOutputRef",type:"ItemAwareElement",isReference:!0},{name:"inputDataItem",type:"DataInput",xml:{serialize:"property"}},{name:"outputDataItem",type:"DataOutput",xml:{serialize:"property"}},{name:"complexBehaviorDefinition",type:"ComplexBehaviorDefinition",isMany:!0},{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"oneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0},{name:"noneBehaviorEventRef",type:"EventDefinition",isAttr:!0,isReference:!0}]},{name:"StandardLoopCharacteristics",superClass:["LoopCharacteristics"],properties:[{name:"testBefore",default:!1,isAttr:!0,type:"Boolean"},{name:"loopCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"loopMaximum",type:"Integer",isAttr:!0}]},{name:"CallActivity",superClass:["Activity","InteractionNode"],properties:[{name:"calledElement",type:"String",isAttr:!0}]},{name:"Task",superClass:["Activity","InteractionNode"]},{name:"SendTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ReceiveTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"},{name:"instantiate",default:!1,isAttr:!0,type:"Boolean"},{name:"operationRef",type:"Operation",isAttr:!0,isReference:!0},{name:"messageRef",type:"Message",isAttr:!0,isReference:!0}]},{name:"ScriptTask",superClass:["Task"],properties:[{name:"scriptFormat",isAttr:!0,type:"String"},{name:"script",type:"String"}]},{name:"BusinessRuleTask",superClass:["Task"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"AdHocSubProcess",superClass:["SubProcess"],properties:[{name:"completionCondition",type:"Expression",xml:{serialize:"xsi:type"}},{name:"ordering",type:"AdHocOrdering",isAttr:!0},{name:"cancelRemainingInstances",default:!0,isAttr:!0,type:"Boolean"}]},{name:"Transaction",superClass:["SubProcess"],properties:[{name:"protocol",isAttr:!0,type:"String"},{name:"method",isAttr:!0,type:"String"}]},{name:"GlobalScriptTask",superClass:["GlobalTask"],properties:[{name:"scriptLanguage",isAttr:!0,type:"String"},{name:"script",isAttr:!0,type:"String"}]},{name:"GlobalBusinessRuleTask",superClass:["GlobalTask"],properties:[{name:"implementation",isAttr:!0,type:"String"}]},{name:"ComplexBehaviorDefinition",superClass:["BaseElement"],properties:[{name:"condition",type:"FormalExpression"},{name:"event",type:"ImplicitThrowEvent"}]},{name:"ResourceRole",superClass:["BaseElement"],properties:[{name:"resourceRef",type:"Resource",isReference:!0},{name:"resourceParameterBindings",type:"ResourceParameterBinding",isMany:!0},{name:"resourceAssignmentExpression",type:"ResourceAssignmentExpression"},{name:"name",isAttr:!0,type:"String"}]},{name:"ResourceParameterBinding",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}},{name:"parameterRef",type:"ResourceParameter",isAttr:!0,isReference:!0}],superClass:["BaseElement"]},{name:"ResourceAssignmentExpression",properties:[{name:"expression",type:"Expression",xml:{serialize:"xsi:type"}}],superClass:["BaseElement"]},{name:"Import",properties:[{name:"importType",isAttr:!0,type:"String"},{name:"location",isAttr:!0,type:"String"},{name:"namespace",isAttr:!0,type:"String"}]},{name:"Definitions",superClass:["BaseElement"],properties:[{name:"name",isAttr:!0,type:"String"},{name:"targetNamespace",isAttr:!0,type:"String"},{name:"expressionLanguage",default:"http://www.w3.org/1999/XPath",isAttr:!0,type:"String"},{name:"typeLanguage",default:"http://www.w3.org/2001/XMLSchema",isAttr:!0,type:"String"},{name:"imports",type:"Import",isMany:!0},{name:"extensions",type:"Extension",isMany:!0},{name:"rootElements",type:"RootElement",isMany:!0},{name:"diagrams",isMany:!0,type:"bpmndi:BPMNDiagram"},{name:"exporter",isAttr:!0,type:"String"},{name:"relationships",type:"Relationship",isMany:!0},{name:"exporterVersion",isAttr:!0,type:"String"}]}],enumerations:[{name:"ProcessType",literalValues:[{name:"None"},{name:"Public"},{name:"Private"}]},{name:"GatewayDirection",literalValues:[{name:"Unspecified"},{name:"Converging"},{name:"Diverging"},{name:"Mixed"}]},{name:"EventBasedGatewayType",literalValues:[{name:"Parallel"},{name:"Exclusive"}]},{name:"RelationshipDirection",literalValues:[{name:"None"},{name:"Forward"},{name:"Backward"},{name:"Both"}]},{name:"ItemKind",literalValues:[{name:"Physical"},{name:"Information"}]},{name:"ChoreographyLoopType",literalValues:[{name:"None"},{name:"Standard"},{name:"MultiInstanceSequential"},{name:"MultiInstanceParallel"}]},{name:"AssociationDirection",literalValues:[{name:"None"},{name:"One"},{name:"Both"}]},{name:"MultiInstanceBehavior",literalValues:[{name:"None"},{name:"One"},{name:"All"},{name:"Complex"}]},{name:"AdHocOrdering",literalValues:[{name:"Parallel"},{name:"Sequential"}]}],xml:{tagAlias:"lowerCase",typePrefix:"t"}},bpmndi:{name:"BPMNDI",uri:"http://www.omg.org/spec/BPMN/20100524/DI",prefix:"bpmndi",types:[{name:"BPMNDiagram",properties:[{name:"plane",type:"BPMNPlane",redefines:"di:Diagram#rootElement"},{name:"labelStyle",type:"BPMNLabelStyle",isMany:!0}],superClass:["di:Diagram"]},{name:"BPMNPlane",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"}],superClass:["di:Plane"]},{name:"BPMNShape",properties:[{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"isHorizontal",isAttr:!0,type:"Boolean"},{name:"isExpanded",isAttr:!0,type:"Boolean"},{name:"isMarkerVisible",isAttr:!0,type:"Boolean"},{name:"label",type:"BPMNLabel"},{name:"isMessageVisible",isAttr:!0,type:"Boolean"},{name:"participantBandKind",type:"ParticipantBandKind",isAttr:!0},{name:"choreographyActivityShape",type:"BPMNShape",isAttr:!0,isReference:!0}],superClass:["di:LabeledShape"]},{name:"BPMNEdge",properties:[{name:"label",type:"BPMNLabel"},{name:"bpmnElement",isAttr:!0,isReference:!0,type:"bpmn:BaseElement",redefines:"di:DiagramElement#modelElement"},{name:"sourceElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#source"},{name:"targetElement",isAttr:!0,isReference:!0,type:"di:DiagramElement",redefines:"di:Edge#target"},{name:"messageVisibleKind",type:"MessageVisibleKind",isAttr:!0,default:"initiating"}],superClass:["di:LabeledEdge"]},{name:"BPMNLabel",properties:[{name:"labelStyle",type:"BPMNLabelStyle",isAttr:!0,isReference:!0,redefines:"di:DiagramElement#style"}],superClass:["di:Label"]},{name:"BPMNLabelStyle",properties:[{name:"font",type:"dc:Font"}],superClass:["di:Style"]}],enumerations:[{name:"ParticipantBandKind",literalValues:[{name:"top_initiating"},{name:"middle_initiating"},{name:"bottom_initiating"},{name:"top_non_initiating"},{name:"middle_non_initiating"},{name:"bottom_non_initiating"}]},{name:"MessageVisibleKind",literalValues:[{name:"initiating"},{name:"non_initiating"}]}],associations:[]},dc:{name:"DC",uri:"http://www.omg.org/spec/DD/20100524/DC",prefix:"dc",types:[{name:"Boolean"},{name:"Integer"},{name:"Real"},{name:"String"},{name:"Font",properties:[{name:"name",type:"String",isAttr:!0},{name:"size",type:"Real",isAttr:!0},{name:"isBold",type:"Boolean",isAttr:!0},{name:"isItalic",type:"Boolean",isAttr:!0},{name:"isUnderline",type:"Boolean",isAttr:!0},{name:"isStrikeThrough",type:"Boolean",isAttr:!0}]},{name:"Point",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0}]},{name:"Bounds",properties:[{name:"x",type:"Real",default:"0",isAttr:!0},{name:"y",type:"Real",default:"0",isAttr:!0},{name:"width",type:"Real",isAttr:!0},{name:"height",type:"Real",isAttr:!0}]}],associations:[]},di:{name:"DI",uri:"http://www.omg.org/spec/DD/20100524/DI",prefix:"di",types:[{name:"DiagramElement",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"extension",type:"Extension"},{name:"owningDiagram",type:"Diagram",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"owningElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"modelElement",isReadOnly:!0,isVirtual:!0,isReference:!0,type:"Element"},{name:"style",type:"Style",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"ownedElement",type:"DiagramElement",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Node",isAbstract:!0,superClass:["DiagramElement"]},{name:"Edge",isAbstract:!0,superClass:["DiagramElement"],properties:[{name:"source",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"target",type:"DiagramElement",isReadOnly:!0,isVirtual:!0,isReference:!0},{name:"waypoint",isUnique:!1,isMany:!0,type:"dc:Point",xml:{serialize:"xsi:type"}}]},{name:"Diagram",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"},{name:"rootElement",type:"DiagramElement",isReadOnly:!0,isVirtual:!0},{name:"name",isAttr:!0,type:"String"},{name:"documentation",isAttr:!0,type:"String"},{name:"resolution",isAttr:!0,type:"Real"},{name:"ownedStyle",type:"Style",isReadOnly:!0,isMany:!0,isVirtual:!0}]},{name:"Shape",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Plane",isAbstract:!0,superClass:["Node"],properties:[{name:"planeElement",type:"DiagramElement",subsettedProperty:"DiagramElement-ownedElement",isMany:!0}]},{name:"LabeledEdge",isAbstract:!0,superClass:["Edge"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"LabeledShape",isAbstract:!0,superClass:["Shape"],properties:[{name:"ownedLabel",type:"Label",isReadOnly:!0,subsettedProperty:"DiagramElement-ownedElement",isMany:!0,isVirtual:!0}]},{name:"Label",isAbstract:!0,superClass:["Node"],properties:[{name:"bounds",type:"dc:Bounds"}]},{name:"Style",isAbstract:!0,properties:[{name:"id",isAttr:!0,isId:!0,type:"String"}]},{name:"Extension",properties:[{name:"values",isMany:!0,type:"Element"}]}],associations:[],xml:{tagAlias:"lowerCase"}},bioc:{name:"bpmn.io colors for BPMN",uri:"http://bpmn.io/schema/bpmn/biocolor/1.0",prefix:"bioc",types:[{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"stroke",isAttr:!0,type:"String"},{name:"fill",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]},color:{name:"BPMN in Color",uri:"http://www.omg.org/spec/BPMN/non-normative/color/1.0",prefix:"color",types:[{name:"ColoredLabel",extends:["bpmndi:BPMNLabel"],properties:[{name:"color",isAttr:!0,type:"String"}]},{name:"ColoredShape",extends:["bpmndi:BPMNShape"],properties:[{name:"background-color",isAttr:!0,type:"String"},{name:"border-color",isAttr:!0,type:"String"}]},{name:"ColoredEdge",extends:["bpmndi:BPMNEdge"],properties:[{name:"border-color",isAttr:!0,type:"String"}]}],enumerations:[],associations:[]}};return function(e,t){return new xe(u({},we,e),t)}}));
|