@primmel/primmel 1.18.0 → 1.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/check-rules.d.ts.map +1 -1
- package/dist/src/check-rules.js +30 -0
- package/dist/src/check-rules.js.map +1 -1
- package/dist/src/check.d.ts.map +1 -1
- package/dist/src/check.js +126 -0
- package/dist/src/check.js.map +1 -1
- package/dist/src/ser-des/config/conformanceTest.d.ts.map +1 -1
- package/dist/src/ser-des/config/conformanceTest.js +310 -0
- package/dist/src/ser-des/config/conformanceTest.js.map +1 -1
- package/dist/src/ser-des/config/note.d.ts.map +1 -1
- package/dist/src/ser-des/config/note.js.map +1 -1
- package/dist/src/ser-des/config/packageManifest.d.ts.map +1 -1
- package/dist/src/ser-des/config/packageManifest.js +43 -0
- package/dist/src/ser-des/config/packageManifest.js.map +1 -1
- package/dist/src/types/ConformanceTest.d.ts +86 -0
- package/dist/src/types/ConformanceTest.d.ts.map +1 -1
- package/dist/src/types/Package.d.ts +25 -0
- package/dist/src/types/Package.d.ts.map +1 -1
- package/dist-browser/index.mjs +937 -822
- package/dist-cli/primmel.mjs +419 -0
- package/package.json +1 -1
package/dist-browser/index.mjs
CHANGED
|
@@ -4905,7 +4905,116 @@ function Di(e) {
|
|
|
4905
4905
|
}
|
|
4906
4906
|
return t;
|
|
4907
4907
|
}
|
|
4908
|
-
|
|
4908
|
+
function Oi(e) {
|
|
4909
|
+
let t = {}, r = n(e), i = 0;
|
|
4910
|
+
for (; i < r.length;) {
|
|
4911
|
+
let e = P(r[i++]);
|
|
4912
|
+
if (i >= r.length) break;
|
|
4913
|
+
if (r[i] === ":" && i++, i < r.length) {
|
|
4914
|
+
let n = M(r, i);
|
|
4915
|
+
t[e] = a(n.text), i = n.next;
|
|
4916
|
+
}
|
|
4917
|
+
}
|
|
4918
|
+
return t;
|
|
4919
|
+
}
|
|
4920
|
+
function ki(e) {
|
|
4921
|
+
let t = {
|
|
4922
|
+
read: "",
|
|
4923
|
+
tolerance: ""
|
|
4924
|
+
}, r = n(e), o = 0;
|
|
4925
|
+
for (; o < r.length;) {
|
|
4926
|
+
let e = r[o++];
|
|
4927
|
+
if (o >= r.length) break;
|
|
4928
|
+
e === "read" ? t.read = a(r[o++]) : e === "tolerance" ? t.tolerance = a(r[o++]) : i(r[o++]);
|
|
4929
|
+
}
|
|
4930
|
+
return t;
|
|
4931
|
+
}
|
|
4932
|
+
function Ai(e, t, r, o, s) {
|
|
4933
|
+
let c = {
|
|
4934
|
+
description: "",
|
|
4935
|
+
entries: [],
|
|
4936
|
+
sourceRefs: []
|
|
4937
|
+
}, l = n(e), u = 0;
|
|
4938
|
+
for (; u < l.length;) {
|
|
4939
|
+
let e = l[u++];
|
|
4940
|
+
if (u >= l.length) throw Error(`Parsing error: ${s}: Expecting value for ${e}`);
|
|
4941
|
+
if (e === "description") c.description = a(l[u++]);
|
|
4942
|
+
else if (e === "source") c.sourceRefs.push(I(i(l[u++])));
|
|
4943
|
+
else if (e === "ref") {
|
|
4944
|
+
let e = S(l, u, a, i);
|
|
4945
|
+
T(c, e.ref), u = e.next;
|
|
4946
|
+
} else if (e === t) {
|
|
4947
|
+
let e = r(), t = l[u++];
|
|
4948
|
+
t.startsWith("{") || (e.order = Number(a(t)), t = u < l.length && l[u].startsWith("{") ? l[u++] : ""), t.startsWith("{") && o(i(t), e), c.entries.push(e);
|
|
4949
|
+
} else u = y(l, u, e);
|
|
4950
|
+
}
|
|
4951
|
+
return c;
|
|
4952
|
+
}
|
|
4953
|
+
function ji(e, t) {
|
|
4954
|
+
return Ai(e, "step", () => ({
|
|
4955
|
+
order: null,
|
|
4956
|
+
action: "",
|
|
4957
|
+
drive: "",
|
|
4958
|
+
args: {},
|
|
4959
|
+
hold: "",
|
|
4960
|
+
verify: null
|
|
4961
|
+
}), (e, n) => {
|
|
4962
|
+
v(e, (e, t) => {
|
|
4963
|
+
if (e === "action") n.action = x(t);
|
|
4964
|
+
else if (e === "drive") n.drive = a(t());
|
|
4965
|
+
else if (e === "args") n.args = Oi(i(t()));
|
|
4966
|
+
else if (e === "hold") n.hold = a(t());
|
|
4967
|
+
else if (e === "verify") n.verify = ki(i(t()));
|
|
4968
|
+
else return !1;
|
|
4969
|
+
return !0;
|
|
4970
|
+
}, {
|
|
4971
|
+
construct: "conformance_test.preparation",
|
|
4972
|
+
id: t
|
|
4973
|
+
});
|
|
4974
|
+
}, `conformance_test.preparation. ID ${t}`);
|
|
4975
|
+
}
|
|
4976
|
+
function Mi(e, t) {
|
|
4977
|
+
return Ai(e, "point", () => ({
|
|
4978
|
+
order: null,
|
|
4979
|
+
drive: "",
|
|
4980
|
+
args: {},
|
|
4981
|
+
hold: "",
|
|
4982
|
+
freshWithin: "",
|
|
4983
|
+
acceptance: ""
|
|
4984
|
+
}), (e, n) => {
|
|
4985
|
+
v(e, (e, t) => {
|
|
4986
|
+
if (e === "drive") n.drive = a(t());
|
|
4987
|
+
else if (e === "args") n.args = Oi(i(t()));
|
|
4988
|
+
else if (e === "hold") n.hold = a(t());
|
|
4989
|
+
else if (e === "fresh_within") n.freshWithin = a(t());
|
|
4990
|
+
else if (e === "acceptance") n.acceptance = a(t());
|
|
4991
|
+
else return !1;
|
|
4992
|
+
return !0;
|
|
4993
|
+
}, {
|
|
4994
|
+
construct: "conformance_test.stimulus",
|
|
4995
|
+
id: t
|
|
4996
|
+
});
|
|
4997
|
+
}, `conformance_test.stimulus. ID ${t}`);
|
|
4998
|
+
}
|
|
4999
|
+
function Ni(e) {
|
|
5000
|
+
let t = Object.keys(e);
|
|
5001
|
+
return t.length === 0 ? "" : " args { " + t.map((t) => t + ": \"" + s(e[t]) + "\"").join(" ") + " }";
|
|
5002
|
+
}
|
|
5003
|
+
function Pi(e) {
|
|
5004
|
+
let t = " preparation {\n";
|
|
5005
|
+
e.description !== "" && (t += " description \"" + s(e.description) + "\"\n");
|
|
5006
|
+
for (let n of e.entries) t += " step" + (n.order === null ? "" : " " + n.order) + " {", n.action !== "" && (t += " action \"" + s(n.action) + "\""), n.drive !== "" && (t += " drive " + N(n.drive)), t += Ni(n.args), n.hold !== "" && (t += " hold " + N(n.hold)), n.verify && (t += " verify {", n.verify.read !== "" && (t += " read " + N(n.verify.read)), n.verify.tolerance !== "" && (t += " tolerance " + N(n.verify.tolerance)), t += " }"), t += " }\n";
|
|
5007
|
+
for (let n of e.sourceRefs) t += E(n, " ", s);
|
|
5008
|
+
return t + " }\n";
|
|
5009
|
+
}
|
|
5010
|
+
function Fi(e) {
|
|
5011
|
+
let t = " stimulus {\n";
|
|
5012
|
+
e.description !== "" && (t += " description \"" + s(e.description) + "\"\n");
|
|
5013
|
+
for (let n of e.entries) t += " point" + (n.order === null ? "" : " " + n.order) + " {", n.drive !== "" && (t += " drive " + N(n.drive)), t += Ni(n.args), n.hold !== "" && (t += " hold " + N(n.hold)), n.freshWithin !== "" && (t += " fresh_within " + N(n.freshWithin)), n.acceptance !== "" && (t += " acceptance " + N(n.acceptance)), t += " }\n";
|
|
5014
|
+
for (let n of e.sourceRefs) t += E(n, " ", s);
|
|
5015
|
+
return t + " }\n";
|
|
5016
|
+
}
|
|
5017
|
+
var Ii = function(e, t) {
|
|
4909
5018
|
let o = {
|
|
4910
5019
|
id: e,
|
|
4911
5020
|
name: "",
|
|
@@ -4916,6 +5025,8 @@ var Oi = function(e, t) {
|
|
|
4916
5025
|
bindsTo: [],
|
|
4917
5026
|
applicability: [],
|
|
4918
5027
|
procedure: [],
|
|
5028
|
+
preparation: null,
|
|
5029
|
+
stimulus: null,
|
|
4919
5030
|
measurements: [],
|
|
4920
5031
|
kind: "",
|
|
4921
5032
|
obligation: "",
|
|
@@ -4941,15 +5052,15 @@ var Oi = function(e, t) {
|
|
|
4941
5052
|
sourceDiscrepancy: null,
|
|
4942
5053
|
sourceRef: null
|
|
4943
5054
|
};
|
|
4944
|
-
return v(t, (
|
|
4945
|
-
if (
|
|
4946
|
-
else if (
|
|
4947
|
-
else if (
|
|
4948
|
-
else if (
|
|
4949
|
-
else if (
|
|
4950
|
-
else if (
|
|
4951
|
-
else if (
|
|
4952
|
-
let e =
|
|
5055
|
+
return v(t, (t, s, c) => {
|
|
5056
|
+
if (t === "name") o.name = x(s);
|
|
5057
|
+
else if (t === "purpose") o.purpose = x(s);
|
|
5058
|
+
else if (t === "method") o.method = x(s);
|
|
5059
|
+
else if (t === "method_ref") o.methodRef = a(s());
|
|
5060
|
+
else if (t === "guidance") o.guidance = x(s);
|
|
5061
|
+
else if (t === "type") o.type = s();
|
|
5062
|
+
else if (t === "reference") {
|
|
5063
|
+
let e = s();
|
|
4953
5064
|
if (e.startsWith("{")) {
|
|
4954
5065
|
let t = n(i(e));
|
|
4955
5066
|
if (t.includes("doc") || t.includes("clause")) {
|
|
@@ -4961,58 +5072,60 @@ var Oi = function(e, t) {
|
|
|
4961
5072
|
o.sourceRef ||= e, (o.sourceRefs ??= []).push(e), o.reference ||= e.doc;
|
|
4962
5073
|
} else o.sourceRef = null, o.sourceRefs = void 0, o.reference = i(e).trim();
|
|
4963
5074
|
} else o.sourceRef = null, o.sourceRefs = void 0, o.reference = e;
|
|
4964
|
-
} else if (
|
|
4965
|
-
else if (
|
|
4966
|
-
let e = C(
|
|
5075
|
+
} else if (t === "targets") o.targets = r(s());
|
|
5076
|
+
else if (t === "ref") {
|
|
5077
|
+
let e = C(s, c, a, i);
|
|
4967
5078
|
T(o, e) || (o.refs ??= []).push(e);
|
|
4968
|
-
} else if (
|
|
4969
|
-
else if (
|
|
4970
|
-
else if (
|
|
4971
|
-
else if (
|
|
4972
|
-
let e = r(
|
|
4973
|
-
for (;
|
|
4974
|
-
let
|
|
4975
|
-
if (!isNaN(
|
|
5079
|
+
} else if (t === "corresponds") (o.correspondences ??= []).push(O(s, c, a));
|
|
5080
|
+
else if (t === "binds_to") o.bindsTo = r(s());
|
|
5081
|
+
else if (t === "applicability") o.applicability = L(i(s()));
|
|
5082
|
+
else if (t === "procedure") {
|
|
5083
|
+
let e = r(s()), t = 0;
|
|
5084
|
+
for (; t < e.length;) {
|
|
5085
|
+
let n = parseInt(e[t], 10);
|
|
5086
|
+
if (!isNaN(n) && t + 1 < e.length) {
|
|
4976
5087
|
let r = {
|
|
4977
|
-
order:
|
|
4978
|
-
action: x(() => e[
|
|
5088
|
+
order: n,
|
|
5089
|
+
action: x(() => e[t + 1]),
|
|
4979
5090
|
outputs: []
|
|
4980
5091
|
};
|
|
4981
|
-
|
|
4982
|
-
} else
|
|
5092
|
+
t += 2, e[t] === "inputs" && t + 1 < e.length && (r.inputs = V(e[t + 1]), t += 2), e[t] === "outputs" && t + 1 < e.length && (r.outputs = V(e[t + 1]), t += 2), o.procedure.push(r);
|
|
5093
|
+
} else t++;
|
|
4983
5094
|
}
|
|
4984
|
-
} else if (
|
|
4985
|
-
else if (
|
|
4986
|
-
else if (
|
|
4987
|
-
else if (
|
|
4988
|
-
else if (
|
|
4989
|
-
else if (
|
|
4990
|
-
else if (
|
|
4991
|
-
else if (
|
|
4992
|
-
else if (
|
|
4993
|
-
else if (
|
|
4994
|
-
else if (
|
|
4995
|
-
else if (
|
|
4996
|
-
else if (
|
|
4997
|
-
else if (
|
|
4998
|
-
else if (
|
|
4999
|
-
else if (
|
|
5000
|
-
else if (
|
|
5001
|
-
else if (
|
|
5002
|
-
else if (
|
|
5003
|
-
else if (
|
|
5004
|
-
else if (
|
|
5005
|
-
else if (
|
|
5006
|
-
|
|
5095
|
+
} else if (t === "procedure_steps") o.procedureSteps = V(s());
|
|
5096
|
+
else if (t === "preparation") o.preparation = ji(i(s()), e);
|
|
5097
|
+
else if (t === "stimulus") o.stimulus = Mi(i(s()), e);
|
|
5098
|
+
else if (t === "kind") o.kind = a(s());
|
|
5099
|
+
else if (t === "obligation") o.obligation = a(s());
|
|
5100
|
+
else if (t === "obligation_note") o.obligationNote = x(s);
|
|
5101
|
+
else if (t === "test_subject") o.testSubject = Ei(i(s()));
|
|
5102
|
+
else if (t === "variables") o.variables = xi(i(s()));
|
|
5103
|
+
else if (t === "observables") o.observables = Ci(i(s()));
|
|
5104
|
+
else if (t === "conditions_to_enforce" || t === "conditionsToEnforce") o.conditionsToEnforce = V(s());
|
|
5105
|
+
else if (t === "preconditions") o.preconditions = Si(i(s()));
|
|
5106
|
+
else if (t === "reference_materials") o.referenceMaterials = V(s());
|
|
5107
|
+
else if (t === "required_competence") o.requiredCompetence = pi(i(s()));
|
|
5108
|
+
else if (t === "acceptance_criteria") wi(i(s()), o);
|
|
5109
|
+
else if (t === "design") o.design = ii(i(s()));
|
|
5110
|
+
else if (t === "acceptance") o.acceptance = Yr(i(s()));
|
|
5111
|
+
else if (t === "dependencies") o.dependencies = V(s());
|
|
5112
|
+
else if (t === "instances") o.instances = Di(i(s()));
|
|
5113
|
+
else if (t === "inherits_from") o.inheritsFrom = a(s());
|
|
5114
|
+
else if (t === "result_forms") o.resultForms = V(s());
|
|
5115
|
+
else if (t === "produces_artifacts") o.producesArtifacts = V(s());
|
|
5116
|
+
else if (t === "report_rows") o.reportRows = V(s());
|
|
5117
|
+
else if (t === "derived_values") o.derivedValues = Ti(i(s()));
|
|
5118
|
+
else if (t === "validate_measurement") {
|
|
5119
|
+
let e = r(s());
|
|
5007
5120
|
for (let t of e) t.startsWith("\"") && o.measurements.push(i(t));
|
|
5008
|
-
} else if (
|
|
5121
|
+
} else if (t === "source_discrepancy") o.sourceDiscrepancy = A(i(s()));
|
|
5009
5122
|
else return !1;
|
|
5010
5123
|
return !0;
|
|
5011
5124
|
}, {
|
|
5012
5125
|
construct: "conformance_test",
|
|
5013
5126
|
id: e
|
|
5014
5127
|
}), (t) => (t.conformanceTests[e] = o, t);
|
|
5015
|
-
},
|
|
5128
|
+
}, Li = function(e) {
|
|
5016
5129
|
let t = "conformance_test " + e.id + " {\n";
|
|
5017
5130
|
if (e.name && (t += " name \"" + s(e.name) + "\"\n"), e.type && (t += " type " + e.type + "\n"), e.purpose && (t += " purpose \"" + s(e.purpose) + "\"\n"), e.method && (t += " method \"" + s(e.method) + "\"\n"), e.methodRef && (t += " method_ref " + e.methodRef + "\n"), e.guidance && (t += " guidance \"" + s(e.guidance) + "\"\n"), e.sourceRefs && e.sourceRefs.length > 0) for (let n of e.sourceRefs) t += E(n, " ", s);
|
|
5018
5131
|
else e.sourceRef && e.sourceRef.doc ? t += E(e.sourceRef, " ", s) : e.reference && (t += " reference " + e.reference + "\n");
|
|
@@ -5035,7 +5148,7 @@ var Oi = function(e, t) {
|
|
|
5035
5148
|
}
|
|
5036
5149
|
t += " }\n";
|
|
5037
5150
|
}
|
|
5038
|
-
if (e.procedureSteps && e.procedureSteps.length > 0 && (t += " procedure_steps { " + e.procedureSteps.join(" ") + " }\n"), e.measurements.length > 0) {
|
|
5151
|
+
if (e.procedureSteps && e.procedureSteps.length > 0 && (t += " procedure_steps { " + e.procedureSteps.join(" ") + " }\n"), e.preparation && (t += Pi(e.preparation)), e.stimulus && (t += Fi(e.stimulus)), e.measurements.length > 0) {
|
|
5039
5152
|
t += " validate_measurement {\n";
|
|
5040
5153
|
for (let n of e.measurements) t += " \"" + s(n) + "\"\n";
|
|
5041
5154
|
t += " }\n";
|
|
@@ -5096,23 +5209,23 @@ var Oi = function(e, t) {
|
|
|
5096
5209
|
t += " }\n";
|
|
5097
5210
|
}
|
|
5098
5211
|
return e.sourceDiscrepancy && (t += j(e.sourceDiscrepancy, " ") + "\n"), t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
5099
|
-
},
|
|
5212
|
+
}, Ri = {
|
|
5100
5213
|
aliases: "aliases",
|
|
5101
5214
|
alt: "aliases",
|
|
5102
5215
|
colloquial: "colloquial",
|
|
5103
5216
|
abbreviations: "abbreviations",
|
|
5104
5217
|
deprecated: "deprecated"
|
|
5105
5218
|
};
|
|
5106
|
-
function
|
|
5107
|
-
return e in
|
|
5219
|
+
function zi(e) {
|
|
5220
|
+
return e in Ri;
|
|
5108
5221
|
}
|
|
5109
|
-
function
|
|
5222
|
+
function Bi(e, t, n) {
|
|
5110
5223
|
if (t === "aliases") {
|
|
5111
5224
|
let t = [...e.aliases ?? [], ...n];
|
|
5112
5225
|
e.aliases = t, e.alt = t;
|
|
5113
5226
|
} else (e[t] ??= []).push(...n);
|
|
5114
5227
|
}
|
|
5115
|
-
var
|
|
5228
|
+
var Vi = function(e, t) {
|
|
5116
5229
|
let n = {
|
|
5117
5230
|
id: e,
|
|
5118
5231
|
label: "",
|
|
@@ -5147,7 +5260,7 @@ var Ni = function(e, t) {
|
|
|
5147
5260
|
else if (t === "language") n.language = x(o);
|
|
5148
5261
|
else if (t === "form_type") n.formType = x(o);
|
|
5149
5262
|
else if (t === "part_of_speech") n.partOfSpeech = x(o);
|
|
5150
|
-
else if (
|
|
5263
|
+
else if (zi(t)) {
|
|
5151
5264
|
let i = o(), c, l = i;
|
|
5152
5265
|
if (!i.startsWith("{")) {
|
|
5153
5266
|
c = i;
|
|
@@ -5155,8 +5268,8 @@ var Ni = function(e, t) {
|
|
|
5155
5268
|
if (n === void 0 || !n.startsWith("{")) throw Error(`Parsing error: term. ID ${e}: alias-family facet "${t}" with spelling code "${c}" expects a list block`);
|
|
5156
5269
|
l = o();
|
|
5157
5270
|
}
|
|
5158
|
-
let u = r(l).map(a), d =
|
|
5159
|
-
if (c === void 0)
|
|
5271
|
+
let u = r(l).map(a), d = Ri[t];
|
|
5272
|
+
if (c === void 0) Bi(n, d, u);
|
|
5160
5273
|
else {
|
|
5161
5274
|
let e = (n.aliasSpellings ??= {})[c] ??= {};
|
|
5162
5275
|
(e[d] ??= []).push(...u);
|
|
@@ -5168,7 +5281,7 @@ var Ni = function(e, t) {
|
|
|
5168
5281
|
construct: "term",
|
|
5169
5282
|
id: e
|
|
5170
5283
|
}), (t) => (t.terms[e] = n, t);
|
|
5171
|
-
},
|
|
5284
|
+
}, Hi = function(e) {
|
|
5172
5285
|
let t = "term " + e.id + " {\n";
|
|
5173
5286
|
e.label && (t += " label \"" + s(e.label) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.symbolId && (t += " symbol " + e.symbolId + "\n"), e.vocabRef && (t += " vocab_ref { register " + e.vocabRef.register + " clause \"" + s(e.vocabRef.clause) + "\" }\n"), e.vocabTerm && (t += " vocab_term \"" + s(e.vocabTerm) + "\"\n"), e.section && (t += " section \"" + s(e.section) + "\"\n"), e.note && (t += " note \"" + s(e.note) + "\"\n"), e.source && (t += " source \"" + s(e.source) + "\"\n"), e.overlay && (t += " overlay true\n"), e.scopeNote && (t += " scope_note \"" + s(e.scopeNote) + "\"\n"), e.language && (t += " language \"" + s(e.language) + "\"\n"), e.formType && (t += " form_type \"" + s(e.formType) + "\"\n"), e.partOfSpeech && (t += " part_of_speech \"" + s(e.partOfSpeech) + "\"\n");
|
|
5174
5287
|
let n = (e) => /\s/.test(e) ? "\"" + s(e) + "\"" : e, r = (e, t, r) => " " + e + (r ? " " + r : "") + " { " + t.map(n).join(" ") + " }\n", i = e.aliases ?? e.alt;
|
|
@@ -5191,17 +5304,17 @@ var Ni = function(e, t) {
|
|
|
5191
5304
|
t += " }\n";
|
|
5192
5305
|
}
|
|
5193
5306
|
return t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
5194
|
-
},
|
|
5307
|
+
}, Ui = [
|
|
5195
5308
|
"none",
|
|
5196
5309
|
"max",
|
|
5197
5310
|
"mean",
|
|
5198
5311
|
"worst_case",
|
|
5199
5312
|
"max_abs_over_window"
|
|
5200
5313
|
];
|
|
5201
|
-
function
|
|
5314
|
+
function Wi(e) {
|
|
5202
5315
|
return n(a(e)).map(P).map(a).filter((e) => e.length > 0);
|
|
5203
5316
|
}
|
|
5204
|
-
var
|
|
5317
|
+
var Gi = function(e, t) {
|
|
5205
5318
|
let r = {
|
|
5206
5319
|
id: e,
|
|
5207
5320
|
quantityKind: "",
|
|
@@ -5223,10 +5336,10 @@ var Li = function(e, t) {
|
|
|
5223
5336
|
} else if (t === "symbol") r.symbol = x(o);
|
|
5224
5337
|
else if (t === "behavior") r.behavior = o();
|
|
5225
5338
|
else if (t === "derive" || t === "expression") r.derive = x(o);
|
|
5226
|
-
else if (t === "inputs" || t === "uses") r.inputs =
|
|
5339
|
+
else if (t === "inputs" || t === "uses") r.inputs = Wi(o());
|
|
5227
5340
|
else if (t === "series_reduction") {
|
|
5228
5341
|
let t = o();
|
|
5229
|
-
if (!
|
|
5342
|
+
if (!Ui.includes(t)) throw Error(`Parsing error: verdict. ID ${e}: Unknown series_reduction ${t} (valid: ${Ui.join(", ")})`);
|
|
5230
5343
|
r.seriesReduction = t;
|
|
5231
5344
|
} else if (t === "acceptance") r.acceptance = Yr(i(o()));
|
|
5232
5345
|
else if (t === "source" || t === "reference") {
|
|
@@ -5242,7 +5355,7 @@ var Li = function(e, t) {
|
|
|
5242
5355
|
construct: "verdict",
|
|
5243
5356
|
id: e
|
|
5244
5357
|
}), (t) => (t.verdicts[e] = r, t);
|
|
5245
|
-
},
|
|
5358
|
+
}, Ki = function(e) {
|
|
5246
5359
|
let t = "verdict " + e.id + " {\n";
|
|
5247
5360
|
e.symbol && (t += " symbol \"" + s(e.symbol) + "\"\n"), e.behavior && (t += " behavior " + e.behavior + "\n"), e.quantityKind && (t += " quantity { kind " + e.quantityKind, e.unit && (t += " unit \"" + s(e.unit) + "\""), t += " }\n"), e.derive && (t += " derive \"" + s(e.derive) + "\"\n"), e.inputs.length > 0 && (t += " inputs { " + e.inputs.join(" ") + " }\n"), e.seriesReduction && (t += " series_reduction " + e.seriesReduction + "\n"), e.acceptance && (t += Xr(e.acceptance, " ") + "\n");
|
|
5248
5361
|
let n = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source && (e.source.doc || e.source.clause) ? [e.source] : [];
|
|
@@ -5251,7 +5364,7 @@ var Li = function(e, t) {
|
|
|
5251
5364
|
};
|
|
5252
5365
|
//#endregion
|
|
5253
5366
|
//#region src/ser-des/config/referenceMaterial.ts
|
|
5254
|
-
function
|
|
5367
|
+
function qi(e) {
|
|
5255
5368
|
let t = [], r = n(e), o = 0;
|
|
5256
5369
|
for (; o < r.length;) {
|
|
5257
5370
|
if (r[o++] !== "field") {
|
|
@@ -5277,7 +5390,7 @@ function zi(e) {
|
|
|
5277
5390
|
}
|
|
5278
5391
|
return t;
|
|
5279
5392
|
}
|
|
5280
|
-
function
|
|
5393
|
+
function Ji(e) {
|
|
5281
5394
|
let t = [], r = n(e), o = 0;
|
|
5282
5395
|
for (; o < r.length;) {
|
|
5283
5396
|
if (r[o++] !== "constraint") {
|
|
@@ -5334,7 +5447,7 @@ function Bi(e) {
|
|
|
5334
5447
|
}
|
|
5335
5448
|
return t;
|
|
5336
5449
|
}
|
|
5337
|
-
var
|
|
5450
|
+
var Yi = function(e, t) {
|
|
5338
5451
|
let n = {
|
|
5339
5452
|
id: e,
|
|
5340
5453
|
kind: "",
|
|
@@ -5355,15 +5468,15 @@ var Vi = function(e, t) {
|
|
|
5355
5468
|
let e = C(t, r, a, i);
|
|
5356
5469
|
T(n, e) || (n.refs ??= []).push(e);
|
|
5357
5470
|
} else if (e === "corresponds") (n.correspondences ??= []).push(O(t, r, a));
|
|
5358
|
-
else if (e === "identity_fields") n.identityFields =
|
|
5359
|
-
else if (e === "constraints") n.constraints =
|
|
5471
|
+
else if (e === "identity_fields") n.identityFields = qi(i(t()));
|
|
5472
|
+
else if (e === "constraints") n.constraints = Ji(i(t()));
|
|
5360
5473
|
else return !1;
|
|
5361
5474
|
return !0;
|
|
5362
5475
|
}, {
|
|
5363
5476
|
construct: "reference_material",
|
|
5364
5477
|
id: e
|
|
5365
5478
|
}), (t) => (t.referenceMaterials[e] = n, t);
|
|
5366
|
-
},
|
|
5479
|
+
}, Xi = function(e) {
|
|
5367
5480
|
let t = "reference_material " + e.id + " {\n";
|
|
5368
5481
|
e.kind && (t += " kind " + e.kind + "\n"), e.name && (t += " name \"" + s(e.name) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n");
|
|
5369
5482
|
let n = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source ? [e.source] : [];
|
|
@@ -5386,21 +5499,21 @@ var Vi = function(e, t) {
|
|
|
5386
5499
|
t += " }\n";
|
|
5387
5500
|
}
|
|
5388
5501
|
return t += "}\n", t;
|
|
5389
|
-
},
|
|
5502
|
+
}, Zi = [
|
|
5390
5503
|
"common",
|
|
5391
5504
|
"determination",
|
|
5392
5505
|
"attestation",
|
|
5393
5506
|
"surveillance"
|
|
5394
|
-
],
|
|
5507
|
+
], Qi = [
|
|
5395
5508
|
"product_type",
|
|
5396
5509
|
"batch",
|
|
5397
5510
|
"ongoing_production",
|
|
5398
5511
|
"service_or_process"
|
|
5399
5512
|
];
|
|
5400
|
-
function
|
|
5513
|
+
function $i(e) {
|
|
5401
5514
|
return r(i(e)).map(P).map(a).filter((e) => e.length > 0);
|
|
5402
5515
|
}
|
|
5403
|
-
var
|
|
5516
|
+
var ea = (e, t) => {
|
|
5404
5517
|
let n = {
|
|
5405
5518
|
id: e,
|
|
5406
5519
|
family: "common",
|
|
@@ -5414,7 +5527,7 @@ var Ki = (e, t) => {
|
|
|
5414
5527
|
return v(t, (t, r) => {
|
|
5415
5528
|
if (t === "family") {
|
|
5416
5529
|
let t = a(r());
|
|
5417
|
-
if (!
|
|
5530
|
+
if (!Zi.includes(t)) throw Error(`Parsing error: scheme_activity_kind. ID ${e}: Unknown family "${t}" (valid: ${Zi.join(", ")})`);
|
|
5418
5531
|
n.family = t;
|
|
5419
5532
|
} else if (t === "row") n.row = a(r());
|
|
5420
5533
|
else if (t === "label") n.label = a(r());
|
|
@@ -5426,14 +5539,14 @@ var Ki = (e, t) => {
|
|
|
5426
5539
|
id: e
|
|
5427
5540
|
}), (t) => (t.schemeActivityKinds[e] = n, t);
|
|
5428
5541
|
};
|
|
5429
|
-
function
|
|
5542
|
+
function ta(e) {
|
|
5430
5543
|
let t = {
|
|
5431
5544
|
required: !1,
|
|
5432
5545
|
activities: []
|
|
5433
5546
|
};
|
|
5434
5547
|
return v(e, (e, n) => {
|
|
5435
5548
|
if (e === "required") t.required = a(n()) === "true";
|
|
5436
|
-
else if (e === "activities") t.activities =
|
|
5549
|
+
else if (e === "activities") t.activities = $i(n());
|
|
5437
5550
|
else return !1;
|
|
5438
5551
|
return !0;
|
|
5439
5552
|
}, {
|
|
@@ -5441,7 +5554,7 @@ function qi(e) {
|
|
|
5441
5554
|
id: ""
|
|
5442
5555
|
}), t;
|
|
5443
5556
|
}
|
|
5444
|
-
var
|
|
5557
|
+
var na = (e, t) => {
|
|
5445
5558
|
let n = {
|
|
5446
5559
|
id: e,
|
|
5447
5560
|
label: "",
|
|
@@ -5465,11 +5578,11 @@ var Ji = (e, t) => {
|
|
|
5465
5578
|
else if (t === "sampling") n.sampling = a(o());
|
|
5466
5579
|
else if (t === "attestation_object") {
|
|
5467
5580
|
let t = a(o());
|
|
5468
|
-
if (!
|
|
5581
|
+
if (!Qi.includes(t)) throw Error(`Parsing error: scheme_type. ID ${e}: Unknown attestation_object "${t}" (valid: ${Qi.join(", ")})`);
|
|
5469
5582
|
n.attestationObject = t;
|
|
5470
|
-
} else if (t === "determination") n.determination =
|
|
5471
|
-
else if (t === "attestation") n.attestation =
|
|
5472
|
-
else if (t === "surveillance") n.surveillance =
|
|
5583
|
+
} else if (t === "determination") n.determination = $i(o());
|
|
5584
|
+
else if (t === "attestation") n.attestation = $i(o());
|
|
5585
|
+
else if (t === "surveillance") n.surveillance = ta(i(o()));
|
|
5473
5586
|
else if (t === "notes") n.notes = r(i(o())).map(a).filter((e) => e.length > 0);
|
|
5474
5587
|
else if (t === "source") n.source = I(i(o()));
|
|
5475
5588
|
else return !1;
|
|
@@ -5479,23 +5592,23 @@ var Ji = (e, t) => {
|
|
|
5479
5592
|
id: e
|
|
5480
5593
|
}), (t) => (t.schemeTypes[e] = n, t);
|
|
5481
5594
|
};
|
|
5482
|
-
function
|
|
5595
|
+
function ra(e, t) {
|
|
5483
5596
|
if (!e.doc && !e.clause) return "";
|
|
5484
5597
|
let n = t + "source {\n";
|
|
5485
5598
|
return e.doc && (n += t + " doc \"" + s(e.doc) + "\"\n"), e.clause && (n += t + " clause \"" + s(e.clause) + "\"\n"), n += t + "}\n", n;
|
|
5486
5599
|
}
|
|
5487
|
-
var
|
|
5600
|
+
var ia = function(e) {
|
|
5488
5601
|
let t = "scheme_activity_kind " + e.id + " {\n";
|
|
5489
|
-
return t += " family " + e.family + "\n", e.row && (t += " row \"" + s(e.row) + "\"\n"), e.label && (t += " label \"" + s(e.label) + "\"\n"), t +=
|
|
5490
|
-
},
|
|
5602
|
+
return t += " family " + e.family + "\n", e.row && (t += " row \"" + s(e.row) + "\"\n"), e.label && (t += " label \"" + s(e.label) + "\"\n"), t += ra(e.source, " "), t += "}\n", t;
|
|
5603
|
+
}, aa = function(e) {
|
|
5491
5604
|
let t = "scheme_type " + e.id + " {\n";
|
|
5492
5605
|
if (e.label && (t += " label \"" + s(e.label) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.sampling && (t += " sampling \"" + s(e.sampling) + "\"\n"), e.attestationObject && (t += " attestation_object " + e.attestationObject + "\n"), e.determination.length > 0 && (t += " determination { " + e.determination.map(N).join(" ") + " }\n"), e.attestation.length > 0 && (t += " attestation { " + e.attestation.map(N).join(" ") + " }\n"), e.surveillance && (t += " surveillance {\n", t += " required " + (e.surveillance.required ? "true" : "false") + "\n", e.surveillance.activities.length > 0 && (t += " activities { " + e.surveillance.activities.map(N).join(" ") + " }\n"), t += " }\n"), e.notes.length > 0) {
|
|
5493
5606
|
t += " notes {\n";
|
|
5494
5607
|
for (let n of e.notes) t += " \"" + s(n) + "\"\n";
|
|
5495
5608
|
t += " }\n";
|
|
5496
5609
|
}
|
|
5497
|
-
return t +=
|
|
5498
|
-
},
|
|
5610
|
+
return t += ra(e.source, " "), t += "}\n", t;
|
|
5611
|
+
}, oa = function(e, t) {
|
|
5499
5612
|
let n = {
|
|
5500
5613
|
id: e,
|
|
5501
5614
|
kind: "",
|
|
@@ -5517,16 +5630,16 @@ var Xi = function(e) {
|
|
|
5517
5630
|
} else t === "description" || t === "definition" ? n.description = a(o[s++]) : t === "subject_kinds" ? n.subjectKinds = r(i(o[s++])).map(a) : t === "target_kinds" ? n.targetKinds = r(i(o[s++])).map(a) : t === "resolution" ? n.resolution = a(o[s++]) : t === "inverse" ? n.inverse = a(o[s++]) : t === "transitive" ? n.transitive = a(o[s++]) === "true" : t === "symmetric" ? n.symmetric = a(o[s++]) === "true" : s++;
|
|
5518
5631
|
}
|
|
5519
5632
|
return (t) => (t.predicates ??= {}, t.predicates[e] = n, t);
|
|
5520
|
-
},
|
|
5633
|
+
}, sa = function(e) {
|
|
5521
5634
|
let t = "predicate " + e.id + " {\n";
|
|
5522
5635
|
return e.kind && (t += " kind " + e.kind + "\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.subjectKinds.length > 0 && (t += " subject_kinds { " + e.subjectKinds.join(" ") + " }\n"), e.targetKinds.length > 0 && (t += " target_kinds { " + e.targetKinds.join(" ") + " }\n"), e.resolution && (t += " resolution " + e.resolution + "\n"), e.inverse && (t += " inverse " + e.inverse + "\n"), e.transitive && (t += " transitive true\n"), e.symmetric && (t += " symmetric true\n"), t += "}\n", t;
|
|
5523
5636
|
};
|
|
5524
5637
|
//#endregion
|
|
5525
5638
|
//#region src/ser-des/config/constraint.ts
|
|
5526
|
-
function
|
|
5639
|
+
function ca(e) {
|
|
5527
5640
|
return e.length >= 2 && e.charAt(0) === "\"" && e.charAt(e.length - 1) === "\"" ? o(e.substr(1, e.length - 2)) : i(e);
|
|
5528
5641
|
}
|
|
5529
|
-
var
|
|
5642
|
+
var la = function(e, t) {
|
|
5530
5643
|
let n = {
|
|
5531
5644
|
id: e,
|
|
5532
5645
|
stereotype: "",
|
|
@@ -5540,9 +5653,9 @@ var ta = function(e, t) {
|
|
|
5540
5653
|
let t = o[s++];
|
|
5541
5654
|
if (s >= o.length) throw Error(`Parsing error: constraint. ID ${e}: Expecting value for ${t}`);
|
|
5542
5655
|
if (t === "stereotype") n.stereotype = a(o[s++]);
|
|
5543
|
-
else if (t === "name") n.name =
|
|
5544
|
-
else if (t === "check") n.check =
|
|
5545
|
-
else if (t === "violation_meaning") n.violationMeaning =
|
|
5656
|
+
else if (t === "name") n.name = ca(o[s++]);
|
|
5657
|
+
else if (t === "check") n.check = ca(o[s++]);
|
|
5658
|
+
else if (t === "violation_meaning") n.violationMeaning = ca(o[s++]);
|
|
5546
5659
|
else if (t === "on_violation") n.onViolation = a(o[s++]);
|
|
5547
5660
|
else if (t === "source") n.source = I(i(o[s++]));
|
|
5548
5661
|
else if (t === "ref") {
|
|
@@ -5554,10 +5667,10 @@ var ta = function(e, t) {
|
|
|
5554
5667
|
} else s = y(o, s, t);
|
|
5555
5668
|
}
|
|
5556
5669
|
return (t) => (t.constraints[e] = n, t);
|
|
5557
|
-
},
|
|
5670
|
+
}, ua = function(e) {
|
|
5558
5671
|
let t = "constraint " + e.id + " {\n";
|
|
5559
5672
|
return e.stereotype && (t += " stereotype " + e.stereotype + "\n"), e.name && (t += " name \"" + s(e.name) + "\"\n"), e.check && (t += " check \"" + s(e.check) + "\"\n"), e.violationMeaning && (t += " violation_meaning \"" + s(e.violationMeaning) + "\"\n"), t += " on_violation " + (e.onViolation || "invalid") + "\n", e.source && (e.source.doc || e.source.clause) && (t += " source { doc \"" + s(e.source.doc) + "\" clause \"" + s(e.source.clause) + "\"" + (e.source.fragment ? " fragment \"" + s(e.source.fragment) + "\"" : "") + " }\n"), t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
5560
|
-
},
|
|
5673
|
+
}, da = ["open", "resolved"], fa = function(e, t) {
|
|
5561
5674
|
let i = {
|
|
5562
5675
|
id: e,
|
|
5563
5676
|
status: "",
|
|
@@ -5572,7 +5685,7 @@ var ta = function(e, t) {
|
|
|
5572
5685
|
if (s >= o.length) throw Error(`Parsing error: discrepancy_record. ID ${e}: Expecting value for ${t}`);
|
|
5573
5686
|
if (t === "status") {
|
|
5574
5687
|
let t = a(o[s++]);
|
|
5575
|
-
if (!
|
|
5688
|
+
if (!da.includes(t)) throw Error(`Parsing error: discrepancy_record. ID ${e}: Unknown status ${t} (valid: ${da.join(", ")})`);
|
|
5576
5689
|
i.status = t;
|
|
5577
5690
|
} else if (t === "summary") i.summary = a(o[s++]);
|
|
5578
5691
|
else if (t === "sources") i.sources = n(a(o[s++])).map(a).filter((e) => e.length > 0);
|
|
@@ -5583,13 +5696,13 @@ var ta = function(e, t) {
|
|
|
5583
5696
|
} else t === "governing" ? i.governing = a(o[s++]) : t === "rationale" ? i.rationale = a(o[s++]) : s++;
|
|
5584
5697
|
}
|
|
5585
5698
|
return (t) => (t.discrepancyRecords[e] = i, t);
|
|
5586
|
-
},
|
|
5699
|
+
}, pa = function(e) {
|
|
5587
5700
|
let t = "discrepancy_record " + e.id + " {\n";
|
|
5588
5701
|
return e.status && (t += " status " + e.status + "\n"), e.summary && (t += " summary \"" + s(e.summary) + "\"\n"), t += " sources { " + e.sources.map((e) => "\"" + s(e) + "\"").join(" ") + " }\n", e.resolution && (t += " resolution " + e.resolution + "\n"), e.governing && (t += " governing \"" + s(e.governing) + "\"\n"), e.rationale && (t += " rationale \"" + s(e.rationale) + "\"\n"), t += "}\n", t;
|
|
5589
5702
|
};
|
|
5590
5703
|
//#endregion
|
|
5591
5704
|
//#region src/ser-des/config/testPointSet.ts
|
|
5592
|
-
function
|
|
5705
|
+
function ma(e) {
|
|
5593
5706
|
let t = {}, r = n(e), o = 0;
|
|
5594
5707
|
for (; o < r.length;) {
|
|
5595
5708
|
let e = P(r[o++]);
|
|
@@ -5609,7 +5722,7 @@ function oa(e) {
|
|
|
5609
5722
|
}
|
|
5610
5723
|
return t;
|
|
5611
5724
|
}
|
|
5612
|
-
function
|
|
5725
|
+
function ha(e) {
|
|
5613
5726
|
let t = [], r = n(e), o = 0;
|
|
5614
5727
|
for (; o < r.length;) {
|
|
5615
5728
|
if (r[o++] !== "point") {
|
|
@@ -5634,7 +5747,7 @@ function sa(e) {
|
|
|
5634
5747
|
}
|
|
5635
5748
|
return t;
|
|
5636
5749
|
}
|
|
5637
|
-
var
|
|
5750
|
+
var ga = function(e, t) {
|
|
5638
5751
|
let n = {
|
|
5639
5752
|
id: e,
|
|
5640
5753
|
description: "",
|
|
@@ -5652,16 +5765,16 @@ var ca = function(e, t) {
|
|
|
5652
5765
|
let e = C(t, r, a, i);
|
|
5653
5766
|
T(n, e) || (n.refs ??= []).push(e);
|
|
5654
5767
|
} else if (e === "corresponds") (n.correspondences ??= []).push(O(t, r, a));
|
|
5655
|
-
else if (e === "cardinality") n.cardinality =
|
|
5768
|
+
else if (e === "cardinality") n.cardinality = ma(i(t()));
|
|
5656
5769
|
else if (e === "repetitions_per_point") n.repetitionsPerPoint = Number(a(t()));
|
|
5657
|
-
else if (e === "points") n.points =
|
|
5770
|
+
else if (e === "points") n.points = ha(i(t()));
|
|
5658
5771
|
else return !1;
|
|
5659
5772
|
return !0;
|
|
5660
5773
|
}, {
|
|
5661
5774
|
construct: "test_point_set",
|
|
5662
5775
|
id: e
|
|
5663
5776
|
}), (t) => (t.testPointSets[e] = n, t);
|
|
5664
|
-
},
|
|
5777
|
+
}, _a = function(e) {
|
|
5665
5778
|
let t = "test_point_set " + e.id + " {\n";
|
|
5666
5779
|
e.description && (t += " description \"" + s(e.description) + "\"\n");
|
|
5667
5780
|
let n = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source && (e.source.doc || e.source.clause) ? [e.source] : [];
|
|
@@ -5685,7 +5798,7 @@ var ca = function(e, t) {
|
|
|
5685
5798
|
t += " }\n";
|
|
5686
5799
|
}
|
|
5687
5800
|
return t += "}\n", t;
|
|
5688
|
-
},
|
|
5801
|
+
}, va = (e, t) => {
|
|
5689
5802
|
let n = {
|
|
5690
5803
|
id: e,
|
|
5691
5804
|
title: "",
|
|
@@ -5704,7 +5817,7 @@ var ca = function(e, t) {
|
|
|
5704
5817
|
construct: "common_test_condition",
|
|
5705
5818
|
id: e
|
|
5706
5819
|
}), (t) => (t.commonTestConditions[e] = n, t);
|
|
5707
|
-
},
|
|
5820
|
+
}, ya = function(e) {
|
|
5708
5821
|
let t = "common_test_condition " + e.id + " {\n";
|
|
5709
5822
|
return e.title && (t += " title \"" + s(e.title) + "\"\n"), e.reference && (t += " reference \"" + s(e.reference) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.source && (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
5710
5823
|
};
|
|
@@ -5713,7 +5826,7 @@ var ca = function(e, t) {
|
|
|
5713
5826
|
function H(e) {
|
|
5714
5827
|
return n(a(e)).map(P).map(a).filter((e) => e.length > 0);
|
|
5715
5828
|
}
|
|
5716
|
-
function
|
|
5829
|
+
function ba(e) {
|
|
5717
5830
|
let t = {
|
|
5718
5831
|
verdict: "",
|
|
5719
5832
|
op: "",
|
|
@@ -5727,7 +5840,7 @@ function fa(e) {
|
|
|
5727
5840
|
}
|
|
5728
5841
|
return t;
|
|
5729
5842
|
}
|
|
5730
|
-
function
|
|
5843
|
+
function xa(e) {
|
|
5731
5844
|
let t = {
|
|
5732
5845
|
expression: "",
|
|
5733
5846
|
uses: [],
|
|
@@ -5758,11 +5871,11 @@ function pa(e) {
|
|
|
5758
5871
|
t === "kind" ? e.kind = a(s[c++]) : t === "unit" ? e.unit = a(s[c++]) : i(s[c++]);
|
|
5759
5872
|
}
|
|
5760
5873
|
t.quantity = e;
|
|
5761
|
-
} else e === "accepts" ? t.accepts =
|
|
5874
|
+
} else e === "accepts" ? t.accepts = ba(i(r[o++])) : e === "acceptance" ? t.acceptance = Yr(i(r[o++])) : e === "source_discrepancy" ? t.sourceDiscrepancy = A(i(r[o++])) : o = y(r, o, e);
|
|
5762
5875
|
}
|
|
5763
5876
|
return t;
|
|
5764
5877
|
}
|
|
5765
|
-
function
|
|
5878
|
+
function Sa(e) {
|
|
5766
5879
|
let t = [], r = n(e), o = 0;
|
|
5767
5880
|
for (; o < r.length;) {
|
|
5768
5881
|
if (r[o++] !== "subject") {
|
|
@@ -5786,7 +5899,7 @@ function ma(e) {
|
|
|
5786
5899
|
}
|
|
5787
5900
|
return t;
|
|
5788
5901
|
}
|
|
5789
|
-
function
|
|
5902
|
+
function Ca(e) {
|
|
5790
5903
|
let t = [], r = n(e), o = 0;
|
|
5791
5904
|
for (; o < r.length;) {
|
|
5792
5905
|
if (r[o++] !== "param") {
|
|
@@ -5829,7 +5942,7 @@ function ha(e) {
|
|
|
5829
5942
|
}
|
|
5830
5943
|
return t;
|
|
5831
5944
|
}
|
|
5832
|
-
var
|
|
5945
|
+
var wa = function(e, t) {
|
|
5833
5946
|
let o = {
|
|
5834
5947
|
id: e,
|
|
5835
5948
|
name: "",
|
|
@@ -5856,9 +5969,9 @@ var ga = function(e, t) {
|
|
|
5856
5969
|
else if (e === "statement") o.statement = a(s[c++]);
|
|
5857
5970
|
else if (e === "guidance") o.guidance = a(s[c++]);
|
|
5858
5971
|
else if (e === "binds_to") o.bindsTo = H(s[c++]);
|
|
5859
|
-
else if (e === "subjects") o.subjects =
|
|
5860
|
-
else if (e === "parameters") o.parameters =
|
|
5861
|
-
else if (e === "limit") o.limit =
|
|
5972
|
+
else if (e === "subjects") o.subjects = Sa(i(s[c++]));
|
|
5973
|
+
else if (e === "parameters") o.parameters = Ca(i(s[c++]));
|
|
5974
|
+
else if (e === "limit") o.limit = xa(i(s[c++]));
|
|
5862
5975
|
else if (e === "applicability") o.applicability = L(i(s[c++]));
|
|
5863
5976
|
else if (e === "channel") o.channel = a(s[c++]);
|
|
5864
5977
|
else if (e === "report_row") o.reportRow = a(s[c++]);
|
|
@@ -5886,7 +5999,7 @@ var ga = function(e, t) {
|
|
|
5886
5999
|
}
|
|
5887
6000
|
return (t) => (t.requirements[e] = o, t);
|
|
5888
6001
|
};
|
|
5889
|
-
function
|
|
6002
|
+
function Ta(e) {
|
|
5890
6003
|
let t = " limit {\n";
|
|
5891
6004
|
if (e.expression && (t += " expression \"" + s(e.expression) + "\"\n"), e.uses.length > 0 && (t += " uses { " + e.uses.join(" ") + " }\n"), e.modality && (t += " modality " + e.modality + "\n"), e.relativeTo && (t += " relative_to " + e.relativeTo + "\n"), e.notes && (t += " notes \"" + s(e.notes) + "\"\n"), e.quantity) {
|
|
5892
6005
|
let n = " quantity {";
|
|
@@ -5898,7 +6011,7 @@ function _a(e) {
|
|
|
5898
6011
|
}
|
|
5899
6012
|
return e.acceptance && (t += Xr(e.acceptance, " ") + "\n"), e.sourceDiscrepancy && (t += j(e.sourceDiscrepancy, " ") + "\n"), t += " }\n", t;
|
|
5900
6013
|
}
|
|
5901
|
-
var
|
|
6014
|
+
var Ea = function(e) {
|
|
5902
6015
|
let t = "requirement " + e.id + " {\n";
|
|
5903
6016
|
if (e.name && (t += " name \"" + s(e.name) + "\"\n"), e.statement && (t += " statement \"" + s(e.statement) + "\"\n"), e.guidance && (t += " guidance \"" + s(e.guidance) + "\"\n"), e.bindsTo.length > 0 && (t += " binds_to { " + e.bindsTo.join(" ") + " }\n"), e.subjects.length > 0) {
|
|
5904
6017
|
t += " subjects { ";
|
|
@@ -5913,7 +6026,7 @@ var va = function(e) {
|
|
|
5913
6026
|
}
|
|
5914
6027
|
t += " }\n";
|
|
5915
6028
|
}
|
|
5916
|
-
if (e.limit && (t +=
|
|
6029
|
+
if (e.limit && (t += Ta(e.limit)), e.applicability.length > 0 && (t += " applicability {\n " + R(e.applicability).trim() + "\n }\n"), e.channel && (t += " channel " + e.channel + "\n"), e.reportRow && (t += " report_row " + e.reportRow + "\n"), e.obligation && (t += " obligation " + e.obligation + "\n"), e.acceptanceCriteria && (t += " acceptance_criteria {\n " + e.acceptanceCriteria + "\n }\n"), e.verificationMethod) {
|
|
5917
6030
|
let n = " verification { method " + e.verificationMethod;
|
|
5918
6031
|
e.verificationDescription && (n += " description \"" + s(e.verificationDescription) + "\""), t += n + " }\n";
|
|
5919
6032
|
}
|
|
@@ -5921,7 +6034,7 @@ var va = function(e) {
|
|
|
5921
6034
|
for (let n of e.sourceRefs ?? (e.source && (e.source.doc || e.source.clause) ? [e.source] : [])) t += E(n, " ", s);
|
|
5922
6035
|
for (let n of e.refs ?? []) t += " ref " + n.predicate + " \"" + s(n.target) + "\"" + (n.note ? " { note \"" + s(n.note) + "\" }" : "") + "\n";
|
|
5923
6036
|
return t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
5924
|
-
},
|
|
6037
|
+
}, Da = function(e, t) {
|
|
5925
6038
|
let n = {
|
|
5926
6039
|
id: e,
|
|
5927
6040
|
name: "",
|
|
@@ -5936,43 +6049,43 @@ var va = function(e) {
|
|
|
5936
6049
|
e === "name" ? n.name = a(o[s++]) : e === "title" ? n.title = a(o[s++]) : e === "description" ? n.description = a(o[s++]) : e === "subject" ? n.subject = a(o[s++]) : e === "guidance" ? n.guidance = a(o[s++]) : e === "applicability" ? n.applicability = L(i(o[s++])) : e === "dependencies" ? n.dependencies = H(o[s++]) : e === "reference" ? n.referenceIds = H(o[s++]) : s = y(o, s, e);
|
|
5937
6050
|
}
|
|
5938
6051
|
return (t) => (t.requirementClasses[e] = n, t);
|
|
5939
|
-
},
|
|
6052
|
+
}, Oa = function(e) {
|
|
5940
6053
|
let t = "requirement_class " + e.id + " {\n";
|
|
5941
6054
|
return e.name && (t += " name \"" + s(e.name) + "\"\n"), e.subject && (t += " subject \"" + s(e.subject) + "\"\n"), e.guidance && (t += " guidance \"" + s(e.guidance) + "\"\n"), e.applicability && e.applicability.length > 0 && (t += " applicability {\n " + R(e.applicability).trim() + "\n }\n"), e.dependencies.length > 0 && (t += " dependencies { " + e.dependencies.join(" ") + " }\n"), e.referenceIds.length > 0 && (t += " reference { " + e.referenceIds.join(" ") + " }\n"), t += "}\n", t;
|
|
5942
|
-
},
|
|
6055
|
+
}, ka = {
|
|
5943
6056
|
keyword: "requirement",
|
|
5944
6057
|
field: "requirements",
|
|
5945
6058
|
takesID: !0,
|
|
5946
|
-
parse:
|
|
5947
|
-
dump:
|
|
5948
|
-
},
|
|
6059
|
+
parse: wa,
|
|
6060
|
+
dump: Ea
|
|
6061
|
+
}, Aa = {
|
|
5949
6062
|
keyword: "requirement_class",
|
|
5950
6063
|
field: "requirementClasses",
|
|
5951
6064
|
takesID: !0,
|
|
5952
|
-
parse:
|
|
5953
|
-
dump:
|
|
6065
|
+
parse: Da,
|
|
6066
|
+
dump: Oa
|
|
5954
6067
|
};
|
|
5955
6068
|
//#endregion
|
|
5956
6069
|
//#region src/ser-des/config/packageManifest.ts
|
|
5957
6070
|
function U(e) {
|
|
5958
6071
|
return n(a(e)).map(a).filter((e) => e.length > 0);
|
|
5959
6072
|
}
|
|
5960
|
-
var
|
|
6073
|
+
var ja = [
|
|
5961
6074
|
"core",
|
|
5962
6075
|
"module",
|
|
5963
6076
|
"rec",
|
|
5964
6077
|
"product_reference",
|
|
5965
6078
|
"certification_program"
|
|
5966
|
-
],
|
|
6079
|
+
], Ma = [
|
|
5967
6080
|
"current",
|
|
5968
6081
|
"preview",
|
|
5969
6082
|
"superseded",
|
|
5970
6083
|
"withdrawn"
|
|
5971
6084
|
];
|
|
5972
|
-
function
|
|
6085
|
+
function Na(e) {
|
|
5973
6086
|
return e.startsWith("{") ? U(e) : [a(e)];
|
|
5974
6087
|
}
|
|
5975
|
-
var
|
|
6088
|
+
var Pa = function(e) {
|
|
5976
6089
|
let t = {
|
|
5977
6090
|
id: "",
|
|
5978
6091
|
title: "",
|
|
@@ -6009,7 +6122,7 @@ var Ea = function(e) {
|
|
|
6009
6122
|
t.uses = e, Object.keys(n).length > 0 && (t.usePins = n);
|
|
6010
6123
|
} else if (e === "kind") {
|
|
6011
6124
|
let e = a(r[o++]);
|
|
6012
|
-
if (!
|
|
6125
|
+
if (!ja.includes(e)) throw Error(`Parsing error: package: Expected kind ${ja.join("|")}, got "${e}"`);
|
|
6013
6126
|
t.kind = e;
|
|
6014
6127
|
} else if (e === "manufacturer") t.manufacturer = a(r[o++]);
|
|
6015
6128
|
else if (e === "product") t.product = a(r[o++]);
|
|
@@ -6021,12 +6134,14 @@ var Ea = function(e) {
|
|
|
6021
6134
|
let e = D(r, o, a);
|
|
6022
6135
|
(t.correspondences ??= []).push(e.corr), o = e.next;
|
|
6023
6136
|
} else if (e === "scheme_type" || e === "schemeType") t.schemeType = a(r[o++]);
|
|
6137
|
+
else if (e === "license_key" || e === "licenseKey") t.licenseKey !== void 0 && (t.licenseKeyDuplicates ??= []).push(t.licenseKey), t.licenseKey = a(r[o++]);
|
|
6138
|
+
else if (e === "license_holder" || e === "licenseHolder") t.licenseHolder = a(r[o++]);
|
|
6024
6139
|
else if (e === "provides") t.provides = U(r[o++]);
|
|
6025
6140
|
else if (e === "requires") t.requires = U(r[o++]);
|
|
6026
6141
|
else if (e === "waives") t.waives = U(r[o++]);
|
|
6027
|
-
else if (e === "supersedes") t.supersedes =
|
|
6028
|
-
else if (e === "replaces") t.replaces =
|
|
6029
|
-
else if (e === "superseded_by") t.supersededBy =
|
|
6142
|
+
else if (e === "supersedes") t.supersedes = Na(r[o++]);
|
|
6143
|
+
else if (e === "replaces") t.replaces = Na(r[o++]);
|
|
6144
|
+
else if (e === "superseded_by") t.supersededBy = Na(r[o++]);
|
|
6030
6145
|
else if (e === "validity") {
|
|
6031
6146
|
let e = n(i(r[o++])), s = { from: "" }, c = 0;
|
|
6032
6147
|
for (; c < e.length;) {
|
|
@@ -6037,7 +6152,7 @@ var Ea = function(e) {
|
|
|
6037
6152
|
t.validity = s;
|
|
6038
6153
|
} else if (e === "status") {
|
|
6039
6154
|
let e = a(r[o++]);
|
|
6040
|
-
if (!
|
|
6155
|
+
if (!Ma.includes(e)) throw Error(`Parsing error: package: Expected status ${Ma.join("|")}, got "${e}"`);
|
|
6041
6156
|
t.status = e;
|
|
6042
6157
|
} else if (e === "default_spelling" || e === "defaultSpelling") t.defaultSpelling = a(r[o++]);
|
|
6043
6158
|
else if (e === "spellings") t.spellings = U(r[o++]);
|
|
@@ -6057,13 +6172,13 @@ var Ea = function(e) {
|
|
|
6057
6172
|
}
|
|
6058
6173
|
return (e) => (e.packageManifest = t, e);
|
|
6059
6174
|
};
|
|
6060
|
-
function
|
|
6175
|
+
function Fa(e) {
|
|
6061
6176
|
let t = "package {\n";
|
|
6062
6177
|
e.id && (t += " id " + e.id + "\n"), e.kind && (t += " kind " + e.kind + "\n"), e.manufacturer && (t += " manufacturer \"" + e.manufacturer.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.product && (t += " product \"" + e.product.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.mapsTo && e.mapsTo.length > 0 && (t += " maps_to { " + e.mapsTo.join(" ") + " }\n");
|
|
6063
6178
|
for (let n of e.refs ?? []) t += " ref " + n.predicate + " \"" + n.target.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"" + (n.note ? " { note \"" + n.note.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\" }" : "") + "\n";
|
|
6064
|
-
return t += k(e.correspondences, " ", s, N), e.schemeType && (t += " scheme_type " + e.schemeType + "\n"), e.title && (t += " title \"" + e.title.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.version && (t += " version \"" + e.version + "\"\n"), e.editions.length > 0 && (t += " editions { " + e.editions.join(" ") + " }\n"), e.baseUrn && (t += " baseUrn \"" + e.baseUrn + "\"\n"), e.extends && (t += " extends " + e.extends + "\n"), e.uses && e.uses.length > 0 && (t += " uses { " + e.uses.map((t) => e.usePins?.[t] ? `${t}@${e.usePins[t]}` : t).join(" ") + " }\n"), e.provides && e.provides.length > 0 && (t += " provides { " + e.provides.join(" ") + " }\n"), e.requires && e.requires.length > 0 && (t += " requires { " + e.requires.join(" ") + " }\n"), e.waives && e.waives.length > 0 && (t += " waives { " + e.waives.join(" ") + " }\n"), e.supersedes && e.supersedes.length > 0 && (t += " supersedes { " + e.supersedes.join(" ") + " }\n"), e.replaces && e.replaces.length > 0 && (t += " replaces { " + e.replaces.join(" ") + " }\n"), e.supersededBy && e.supersededBy.length > 0 && (t += " superseded_by { " + e.supersededBy.join(" ") + " }\n"), e.validity && e.validity.from && (t += " validity { from " + e.validity.from + (e.validity.to ? " to " + e.validity.to : "") + " }\n"), e.status && (t += " status " + e.status + "\n"), e.defaultSpelling && (t += " default_spelling " + e.defaultSpelling + "\n"), e.spellings && e.spellings.length > 0 && (t += " spellings { " + e.spellings.join(" ") + " }\n"), e.description && (t += " description \"" + e.description.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.source && (t += " source { collection \"" + e.source.collection + "\" parts { " + e.source.parts.join(" ") + " } }\n"), t += "}\n", t;
|
|
6179
|
+
return t += k(e.correspondences, " ", s, N), e.schemeType && (t += " scheme_type " + e.schemeType + "\n"), e.licenseKey && (t += " license_key \"" + e.licenseKey.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.licenseHolder && (t += " license_holder \"" + e.licenseHolder.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.title && (t += " title \"" + e.title.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.version && (t += " version \"" + e.version + "\"\n"), e.editions.length > 0 && (t += " editions { " + e.editions.join(" ") + " }\n"), e.baseUrn && (t += " baseUrn \"" + e.baseUrn + "\"\n"), e.extends && (t += " extends " + e.extends + "\n"), e.uses && e.uses.length > 0 && (t += " uses { " + e.uses.map((t) => e.usePins?.[t] ? `${t}@${e.usePins[t]}` : t).join(" ") + " }\n"), e.provides && e.provides.length > 0 && (t += " provides { " + e.provides.join(" ") + " }\n"), e.requires && e.requires.length > 0 && (t += " requires { " + e.requires.join(" ") + " }\n"), e.waives && e.waives.length > 0 && (t += " waives { " + e.waives.join(" ") + " }\n"), e.supersedes && e.supersedes.length > 0 && (t += " supersedes { " + e.supersedes.join(" ") + " }\n"), e.replaces && e.replaces.length > 0 && (t += " replaces { " + e.replaces.join(" ") + " }\n"), e.supersededBy && e.supersededBy.length > 0 && (t += " superseded_by { " + e.supersededBy.join(" ") + " }\n"), e.validity && e.validity.from && (t += " validity { from " + e.validity.from + (e.validity.to ? " to " + e.validity.to : "") + " }\n"), e.status && (t += " status " + e.status + "\n"), e.defaultSpelling && (t += " default_spelling " + e.defaultSpelling + "\n"), e.spellings && e.spellings.length > 0 && (t += " spellings { " + e.spellings.join(" ") + " }\n"), e.description && (t += " description \"" + e.description.replace(/\\/g, "\\\\").replace(/"/g, "\\\"") + "\"\n"), e.source && (t += " source { collection \"" + e.source.collection + "\" parts { " + e.source.parts.join(" ") + " } }\n"), t += "}\n", t;
|
|
6065
6180
|
}
|
|
6066
|
-
var
|
|
6181
|
+
var Ia = {
|
|
6067
6182
|
keyword: "conformance_class",
|
|
6068
6183
|
field: "conformanceClasses",
|
|
6069
6184
|
takesID: !0,
|
|
@@ -6096,28 +6211,28 @@ var Oa = {
|
|
|
6096
6211
|
}
|
|
6097
6212
|
return e.dependencies.length > 0 && (t += " dependencies { " + e.dependencies.join(" ") + " }\n"), e.referenceIds.length > 0 && (t += " reference { " + e.referenceIds.join(" ") + " }\n"), t += "}\n", t;
|
|
6098
6213
|
}
|
|
6099
|
-
},
|
|
6214
|
+
}, La = [
|
|
6100
6215
|
"query",
|
|
6101
6216
|
"subscribe",
|
|
6102
6217
|
"invoke"
|
|
6103
|
-
],
|
|
6218
|
+
], Ra = [
|
|
6104
6219
|
"public",
|
|
6105
6220
|
"registered",
|
|
6106
6221
|
"authority"
|
|
6107
|
-
],
|
|
6222
|
+
], za = /* @__PURE__ */ new Set([
|
|
6108
6223
|
"kind",
|
|
6109
6224
|
"serves",
|
|
6110
6225
|
"does",
|
|
6111
6226
|
"payload"
|
|
6112
6227
|
]);
|
|
6113
|
-
function
|
|
6228
|
+
function Ba(e, t) {
|
|
6114
6229
|
let r = e[t] ?? "";
|
|
6115
6230
|
if (r.startsWith("{")) return {
|
|
6116
6231
|
names: n(i(r)).flatMap((e) => e.split(",")).map((e) => a(e.trim())).filter((e) => e.length > 0),
|
|
6117
6232
|
next: t + 1
|
|
6118
6233
|
};
|
|
6119
6234
|
let o = [], s = t;
|
|
6120
|
-
for (; s < e.length && !
|
|
6235
|
+
for (; s < e.length && !za.has(e[s]) && !e[s].startsWith("{");) {
|
|
6121
6236
|
for (let t of e[s].split(",")) {
|
|
6122
6237
|
let e = a(t.trim());
|
|
6123
6238
|
e && o.push(e);
|
|
@@ -6129,7 +6244,7 @@ function Ma(e, t) {
|
|
|
6129
6244
|
next: s
|
|
6130
6245
|
};
|
|
6131
6246
|
}
|
|
6132
|
-
function
|
|
6247
|
+
function Va(e, t) {
|
|
6133
6248
|
let r = {
|
|
6134
6249
|
name: e,
|
|
6135
6250
|
kind: "",
|
|
@@ -6142,10 +6257,10 @@ function Na(e, t) {
|
|
|
6142
6257
|
if (s > o.length) break;
|
|
6143
6258
|
if (e === "kind") r.kind = a(o[s++] ?? "");
|
|
6144
6259
|
else if (e === "serves") {
|
|
6145
|
-
let e =
|
|
6260
|
+
let e = Ba(o, s);
|
|
6146
6261
|
r.serves = e.names, s = e.next;
|
|
6147
6262
|
} else if (e === "does") {
|
|
6148
|
-
let e =
|
|
6263
|
+
let e = Ba(o, s);
|
|
6149
6264
|
r.does = e.names, s = e.next;
|
|
6150
6265
|
} else if (e === "payload") {
|
|
6151
6266
|
let e = n(i(o[s++] ?? "")), t = {
|
|
@@ -6163,7 +6278,7 @@ function Na(e, t) {
|
|
|
6163
6278
|
}
|
|
6164
6279
|
return r;
|
|
6165
6280
|
}
|
|
6166
|
-
function
|
|
6281
|
+
function Ha(e) {
|
|
6167
6282
|
let t = {}, r = n(e), o = 0;
|
|
6168
6283
|
for (; o < r.length;) {
|
|
6169
6284
|
let e = P(r[o++]);
|
|
@@ -6175,7 +6290,7 @@ function Pa(e) {
|
|
|
6175
6290
|
}
|
|
6176
6291
|
return t;
|
|
6177
6292
|
}
|
|
6178
|
-
function
|
|
6293
|
+
function Ua(e, t) {
|
|
6179
6294
|
let r = {
|
|
6180
6295
|
id: e,
|
|
6181
6296
|
operations: [],
|
|
@@ -6187,19 +6302,19 @@ function Fa(e, t) {
|
|
|
6187
6302
|
if (s > o.length) break;
|
|
6188
6303
|
if (e === "operation") {
|
|
6189
6304
|
let e = P(o[s++] ?? ""), t = s < o.length ? i(o[s++]) : "";
|
|
6190
|
-
e && r.operations.push(
|
|
6191
|
-
} else e === "access" ? r.access =
|
|
6305
|
+
e && r.operations.push(Va(e, t));
|
|
6306
|
+
} else e === "access" ? r.access = Ha(i(o[s++] ?? "")) : e === "profile" ? r.profile = a(o[s++] ?? "") : i(o[s++] ?? "");
|
|
6192
6307
|
}
|
|
6193
6308
|
return r;
|
|
6194
6309
|
}
|
|
6195
|
-
function
|
|
6310
|
+
function Wa(e, t) {
|
|
6196
6311
|
let n = t + "operation " + N(e.name) + " {";
|
|
6197
6312
|
return e.kind && (n += " kind " + N(e.kind)), e.serves.length > 0 && (n += " serves { " + e.serves.map(N).join(" ") + " }"), e.does.length > 0 && (n += " does { " + e.does.map(N).join(" ") + " }"), e.payload && (n += " payload { quantity_kind " + N(e.payload.quantityKind) + " unit " + N(e.payload.unit) + " timestamp " + (e.payload.timestamp ? "true" : "false") + " }"), n + " }\n";
|
|
6198
6313
|
}
|
|
6199
|
-
function
|
|
6314
|
+
function Ga(e, t) {
|
|
6200
6315
|
let n = t + "endpoint " + N(e.id) + " {\n";
|
|
6201
|
-
for (let r of e.operations) n +=
|
|
6202
|
-
let r =
|
|
6316
|
+
for (let r of e.operations) n += Wa(r, t + " ");
|
|
6317
|
+
let r = Ra.filter((t) => (e.access[t] ?? []).length > 0), i = Object.keys(e.access).filter((e) => !Ra.includes(e));
|
|
6203
6318
|
if (r.length + i.length > 0) {
|
|
6204
6319
|
n += t + " access {";
|
|
6205
6320
|
for (let t of [...r, ...i]) n += " " + t + " { " + (e.access[t] ?? []).map(N).join(" ") + " }";
|
|
@@ -6207,7 +6322,7 @@ function La(e, t) {
|
|
|
6207
6322
|
}
|
|
6208
6323
|
return e.profile && (n += t + " profile " + N(e.profile) + "\n"), n + t + "}\n";
|
|
6209
6324
|
}
|
|
6210
|
-
function
|
|
6325
|
+
function Ka(e, t) {
|
|
6211
6326
|
let r = {
|
|
6212
6327
|
aspect: "",
|
|
6213
6328
|
via: "",
|
|
@@ -6226,11 +6341,11 @@ function Ra(e, t) {
|
|
|
6226
6341
|
next: t
|
|
6227
6342
|
};
|
|
6228
6343
|
}
|
|
6229
|
-
function
|
|
6344
|
+
function qa(e, t) {
|
|
6230
6345
|
let n = t + "serve " + N(e.aspect) + " via " + N(e.via);
|
|
6231
6346
|
return e.freshWithin && (n += " { fresh_within " + N(e.freshWithin) + " }"), n + "\n";
|
|
6232
6347
|
}
|
|
6233
|
-
var
|
|
6348
|
+
var Ja = {
|
|
6234
6349
|
keyword: "connector_profile",
|
|
6235
6350
|
field: "connectorProfiles",
|
|
6236
6351
|
takesID: !0,
|
|
@@ -6255,7 +6370,7 @@ var Ba = {
|
|
|
6255
6370
|
};
|
|
6256
6371
|
//#endregion
|
|
6257
6372
|
//#region src/ser-des/config/composition.ts
|
|
6258
|
-
function
|
|
6373
|
+
function Ya(e, t) {
|
|
6259
6374
|
let r = {
|
|
6260
6375
|
id: e,
|
|
6261
6376
|
product: "",
|
|
@@ -6275,7 +6390,7 @@ function Va(e, t) {
|
|
|
6275
6390
|
}
|
|
6276
6391
|
return r;
|
|
6277
6392
|
}
|
|
6278
|
-
function
|
|
6393
|
+
function Xa(e) {
|
|
6279
6394
|
let t = [];
|
|
6280
6395
|
for (let n of e.split("\n")) {
|
|
6281
6396
|
let e = n.trim();
|
|
@@ -6298,7 +6413,7 @@ function Ha(e) {
|
|
|
6298
6413
|
}
|
|
6299
6414
|
return t;
|
|
6300
6415
|
}
|
|
6301
|
-
function
|
|
6416
|
+
function Za(e) {
|
|
6302
6417
|
let t = {
|
|
6303
6418
|
components: [],
|
|
6304
6419
|
decomposition: []
|
|
@@ -6307,8 +6422,8 @@ function Ua(e) {
|
|
|
6307
6422
|
let e = n[a++];
|
|
6308
6423
|
if (e === "component") {
|
|
6309
6424
|
let e = n[a++] ?? "", r = a < n.length ? i(n[a++]) : "";
|
|
6310
|
-
e && t.components.push(
|
|
6311
|
-
} else if (e === "decomposition") t.decomposition =
|
|
6425
|
+
e && t.components.push(Ya(e, r));
|
|
6426
|
+
} else if (e === "decomposition") t.decomposition = Xa(i(n[a++] ?? ""));
|
|
6312
6427
|
else if (e === "revision") {
|
|
6313
6428
|
let e = Number(n[a++] ?? "");
|
|
6314
6429
|
Number.isFinite(e) && (t.revision = e);
|
|
@@ -6316,13 +6431,13 @@ function Ua(e) {
|
|
|
6316
6431
|
}
|
|
6317
6432
|
return t;
|
|
6318
6433
|
}
|
|
6319
|
-
function
|
|
6434
|
+
function Qa(e, t) {
|
|
6320
6435
|
let n = t + "component " + N(e.id) + " {\n";
|
|
6321
6436
|
return n += t + " product " + N(e.product) + "\n", n += t + " endpoint " + N(e.endpoint) + "\n", n += t + " serial " + s(e.serial) + "\n", n += t + " certificate " + (e.certificate === null ? "null" : s(e.certificate)) + "\n", n + t + "}\n";
|
|
6322
6437
|
}
|
|
6323
|
-
function
|
|
6438
|
+
function $a(e, t) {
|
|
6324
6439
|
let n = t + "composed_of {\n";
|
|
6325
|
-
for (let r of e.components) n +=
|
|
6440
|
+
for (let r of e.components) n += Qa(r, t + " ");
|
|
6326
6441
|
if (e.decomposition.length > 0) {
|
|
6327
6442
|
n += t + " decomposition {\n";
|
|
6328
6443
|
for (let r of e.decomposition) n += t + " " + N(r.register) + " -> " + (r.component === "composite" ? "rule " + N(r.rule ?? "") : N(r.component) + "." + N(r.componentRegister ?? "")) + "\n";
|
|
@@ -6346,7 +6461,7 @@ function K(e, t, n) {
|
|
|
6346
6461
|
function q(e) {
|
|
6347
6462
|
return n(a(e)).map(a).filter((e) => e.length > 0);
|
|
6348
6463
|
}
|
|
6349
|
-
var
|
|
6464
|
+
var eo = function(e, t) {
|
|
6350
6465
|
let o = {
|
|
6351
6466
|
id: e,
|
|
6352
6467
|
extends: "",
|
|
@@ -6369,9 +6484,9 @@ var Ka = function(e, t) {
|
|
|
6369
6484
|
if (c >= s.length) break;
|
|
6370
6485
|
if (e === "extends") o.extends = a(s[c++]);
|
|
6371
6486
|
else if (e === "measurand_kind") o.measurandKind = a(s[c++]);
|
|
6372
|
-
else if (e === "measurand") o.measurand =
|
|
6373
|
-
else if (e === "component") o.components.push(
|
|
6374
|
-
else if (e === "structure") o.structure.push(
|
|
6487
|
+
else if (e === "measurand") o.measurand = to(i(s[c++]));
|
|
6488
|
+
else if (e === "component") o.components.push(no(a(s[c++]), i(s[c++])));
|
|
6489
|
+
else if (e === "structure") o.structure.push(ro(a(s[c++]), i(s[c++])));
|
|
6375
6490
|
else if (e === "definition") o.definition = a(s[c++]);
|
|
6376
6491
|
else if (e === "note") o.note = a(s[c++]);
|
|
6377
6492
|
else if (e === "source") {
|
|
@@ -6388,7 +6503,7 @@ var Ka = function(e, t) {
|
|
|
6388
6503
|
e === "name" ? r.name = a(l[u++]) : e === "definition" ? r.definition = a(l[u++]) : e === "note" ? r.note = a(l[u++]) : e === "source" ? r.source = I(i(l[u++])) : i(l[u++]);
|
|
6389
6504
|
}
|
|
6390
6505
|
o.variants.push(r);
|
|
6391
|
-
} else if (e === "dimension") o.dimensions.push(
|
|
6506
|
+
} else if (e === "dimension") o.dimensions.push(io(a(s[c++]), i(s[c++])));
|
|
6392
6507
|
else if (e === "per_channel") o.perChannel = a(s[c++]);
|
|
6393
6508
|
else if (e === "family_criteria") o.familyCriteria = q(s[c++]);
|
|
6394
6509
|
else if (e === "family") {
|
|
@@ -6415,7 +6530,7 @@ var Ka = function(e, t) {
|
|
|
6415
6530
|
if (t >= e.length) break;
|
|
6416
6531
|
n === "dimensions" ? o.familyDefaultDimensions = G(e[t++]) : n === "parameters" ? o.familyDefaultParameters = G(e[t++]) : i(e[t++]);
|
|
6417
6532
|
}
|
|
6418
|
-
} else if (e === "model_group") o.modelGroup =
|
|
6533
|
+
} else if (e === "model_group") o.modelGroup = so(i(s[c++]));
|
|
6419
6534
|
else if (e === "reference") o.referenceIds = q(s[c++]);
|
|
6420
6535
|
else if (e === "ref") {
|
|
6421
6536
|
let e = S(s, c, a, i);
|
|
@@ -6427,7 +6542,7 @@ var Ka = function(e, t) {
|
|
|
6427
6542
|
}
|
|
6428
6543
|
return (t) => (t.instruments[e] = o, t);
|
|
6429
6544
|
};
|
|
6430
|
-
function
|
|
6545
|
+
function to(e) {
|
|
6431
6546
|
let t = {
|
|
6432
6547
|
kind: "",
|
|
6433
6548
|
description: "",
|
|
@@ -6454,7 +6569,7 @@ function qa(e) {
|
|
|
6454
6569
|
}
|
|
6455
6570
|
return t;
|
|
6456
6571
|
}
|
|
6457
|
-
function
|
|
6572
|
+
function no(e, t) {
|
|
6458
6573
|
let r = {
|
|
6459
6574
|
id: e,
|
|
6460
6575
|
classId: "",
|
|
@@ -6468,7 +6583,7 @@ function Ja(e, t) {
|
|
|
6468
6583
|
}
|
|
6469
6584
|
return r;
|
|
6470
6585
|
}
|
|
6471
|
-
function
|
|
6586
|
+
function ro(e, t) {
|
|
6472
6587
|
let r = {
|
|
6473
6588
|
id: e,
|
|
6474
6589
|
predicate: "",
|
|
@@ -6496,7 +6611,7 @@ function Ya(e, t) {
|
|
|
6496
6611
|
}
|
|
6497
6612
|
return r;
|
|
6498
6613
|
}
|
|
6499
|
-
function
|
|
6614
|
+
function io(e, t) {
|
|
6500
6615
|
let r = {
|
|
6501
6616
|
id: e,
|
|
6502
6617
|
label: "",
|
|
@@ -6519,7 +6634,7 @@ function Xa(e, t) {
|
|
|
6519
6634
|
} else if (t === "label_separator") r.labelSeparator = a(o[s++]);
|
|
6520
6635
|
else if (t === "description") r.description = a(o[s++]);
|
|
6521
6636
|
else if (t === "reference" || t === "source") r.source = I(i(o[s++]));
|
|
6522
|
-
else if (t === "values") r.values =
|
|
6637
|
+
else if (t === "values") r.values = ao(i(o[s++]));
|
|
6523
6638
|
else if (t === "values_of") r.valuesOf = a(o[s++]);
|
|
6524
6639
|
else if (t === "ref") {
|
|
6525
6640
|
let e = S(o, s, a, i);
|
|
@@ -6528,7 +6643,7 @@ function Xa(e, t) {
|
|
|
6528
6643
|
}
|
|
6529
6644
|
return r;
|
|
6530
6645
|
}
|
|
6531
|
-
function
|
|
6646
|
+
function ao(e) {
|
|
6532
6647
|
let t = [], r = n(e), o = 0;
|
|
6533
6648
|
for (; o < r.length;) {
|
|
6534
6649
|
let e = P(r[o++]);
|
|
@@ -6571,7 +6686,7 @@ function Za(e) {
|
|
|
6571
6686
|
}
|
|
6572
6687
|
return t;
|
|
6573
6688
|
}
|
|
6574
|
-
function
|
|
6689
|
+
function oo(e, t) {
|
|
6575
6690
|
let n = t + " ", r = t + " ", i = t + "dimension " + e.id + " {\n";
|
|
6576
6691
|
if (e.label && (i += n + "label \"" + s(e.label) + "\"\n"), e.scope && (i += n + "scope " + e.scope + "\n"), e.cardinality && (i += n + "cardinality " + e.cardinality + "\n"), e.labelSeparator && (i += n + "label_separator \"" + s(e.labelSeparator) + "\"\n"), e.description && (i += n + "description \"" + s(e.description) + "\"\n"), i += W("reference", e.source, n), e.valuesOf && (i += n + "values_of " + e.valuesOf + "\n"), e.values.length > 0) {
|
|
6577
6692
|
i += n + "values {\n";
|
|
@@ -6595,7 +6710,7 @@ function Qa(e, t) {
|
|
|
6595
6710
|
}
|
|
6596
6711
|
return i += w(e.refs, n, s), i += t + "}\n", i;
|
|
6597
6712
|
}
|
|
6598
|
-
function
|
|
6713
|
+
function so(e) {
|
|
6599
6714
|
let t = {
|
|
6600
6715
|
definition: "",
|
|
6601
6716
|
identicalCharacteristics: [],
|
|
@@ -6622,7 +6737,7 @@ function $a(e) {
|
|
|
6622
6737
|
}
|
|
6623
6738
|
return t;
|
|
6624
6739
|
}
|
|
6625
|
-
var
|
|
6740
|
+
var co = function(e) {
|
|
6626
6741
|
let t = "instrument " + e.id + " {\n";
|
|
6627
6742
|
if (e.extends && (t += " extends " + e.extends + "\n"), e.perChannel && (t += " per_channel " + e.perChannel + "\n"), e.measurandKind && (t += " measurand_kind " + e.measurandKind + "\n"), e.measurand) {
|
|
6628
6743
|
let n = e.measurand;
|
|
@@ -6645,7 +6760,7 @@ var eo = function(e) {
|
|
|
6645
6760
|
let e = " variant " + n.id + " { ";
|
|
6646
6761
|
n.name && (e += "name \"" + s(n.name) + "\" "), e += "definition \"" + s(n.definition) + "\" ", n.note && (e += "note \"" + s(n.note) + "\" "), n.source && (n.source.doc || n.source.clause) && (e += "source { doc \"" + s(n.source.doc) + "\" clause \"" + s(n.source.clause) + "\" } "), t += e + "}\n";
|
|
6647
6762
|
}
|
|
6648
|
-
for (let n of e.dimensions) t +=
|
|
6763
|
+
for (let n of e.dimensions) t += oo(n, " ");
|
|
6649
6764
|
if ((e.familyMetamodelClass || e.familyDefinition || e.familyNote || e.familySource && (e.familySource.doc || e.familySource.clause)) && (t += " family {\n", e.familyMetamodelClass && (t += " metamodel_class " + e.familyMetamodelClass + "\n"), e.familyDefinition && (t += " definition \"" + s(e.familyDefinition) + "\"\n"), e.familyNote && (t += " note \"" + s(e.familyNote) + "\"\n"), e.familySource && (e.familySource.doc || e.familySource.clause) && (t += E(e.familySource, " ", s)), t += " }\n"), e.familyCriteria.length > 0) {
|
|
6650
6765
|
t += " family_criteria {\n";
|
|
6651
6766
|
for (let n of e.familyCriteria) t += " \"" + s(n) + "\"\n";
|
|
@@ -6661,7 +6776,7 @@ var eo = function(e) {
|
|
|
6661
6776
|
for (let e of n) t += E(e, " ", s);
|
|
6662
6777
|
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += K("reference", e.referenceIds, " "), t += "}\n", t;
|
|
6663
6778
|
};
|
|
6664
|
-
function
|
|
6779
|
+
function lo(e) {
|
|
6665
6780
|
let t = {
|
|
6666
6781
|
key: "",
|
|
6667
6782
|
value: "",
|
|
@@ -6693,13 +6808,13 @@ function to(e) {
|
|
|
6693
6808
|
}
|
|
6694
6809
|
return t;
|
|
6695
6810
|
}
|
|
6696
|
-
function
|
|
6811
|
+
function uo(e) {
|
|
6697
6812
|
let t = " pair_list {\n";
|
|
6698
6813
|
t += " key " + N(e.key) + "\n", t += " value " + N(e.value) + "\n", e.keyDimension && (t += " key_dimension " + N(e.keyDimension) + "\n");
|
|
6699
6814
|
for (let n of e.components) t += " component " + N(n.id) + " {\n", n.name && (t += " name \"" + s(n.name) + "\"\n"), n.source && (n.source.doc || n.source.clause) && (t += " source {\n", n.source.doc && (t += " doc \"" + s(n.source.doc) + "\"\n"), n.source.clause && (t += " clause \"" + s(n.source.clause) + "\"\n"), t += " }\n"), t += " }\n";
|
|
6700
6815
|
return t += " }\n", t;
|
|
6701
6816
|
}
|
|
6702
|
-
var
|
|
6817
|
+
var fo = function(e, t) {
|
|
6703
6818
|
let n = {
|
|
6704
6819
|
id: e,
|
|
6705
6820
|
symbol: "",
|
|
@@ -6730,7 +6845,7 @@ var ro = function(e, t) {
|
|
|
6730
6845
|
} else if (e === "quantity_kind") n.quantityKind = a(o[s++]);
|
|
6731
6846
|
else if (e === "unit") n.unit = a(o[s++]);
|
|
6732
6847
|
else if (e === "value_type") n.valueType = a(o[s++]);
|
|
6733
|
-
else if (e === "pair_list") n.pairList =
|
|
6848
|
+
else if (e === "pair_list") n.pairList = lo(i(o[s++]));
|
|
6734
6849
|
else if (e === "origin") n.origin = a(o[s++]);
|
|
6735
6850
|
else if (e === "scope") n.scope = a(o[s++]);
|
|
6736
6851
|
else if (e === "category") n.category = a(o[s++]);
|
|
@@ -6749,14 +6864,14 @@ var ro = function(e, t) {
|
|
|
6749
6864
|
} else s = y(o, s, e);
|
|
6750
6865
|
}
|
|
6751
6866
|
return (t) => (t.attributeDefinitions[e] = n, t);
|
|
6752
|
-
},
|
|
6867
|
+
}, po = function(e) {
|
|
6753
6868
|
let t = "attribute_definition " + e.id + " {\n";
|
|
6754
6869
|
e.symbol && (t += " symbol \"" + s(e.symbol) + "\"\n"), e.name && (t += " name \"" + s(e.name) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n");
|
|
6755
6870
|
let n = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source ? [e.source] : [];
|
|
6756
6871
|
for (let e of n) t += E(e, " ", s);
|
|
6757
6872
|
for (let n of e.referenceIds) t += " ref cites \"" + s(n) + "\"\n";
|
|
6758
|
-
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), e.quantityKind && (t += " quantity_kind " + e.quantityKind + "\n"), e.unit && (t += " unit \"" + s(e.unit) + "\"\n"), e.valueType && (t += " value_type " + e.valueType + "\n"), e.pairList && (t +=
|
|
6759
|
-
},
|
|
6873
|
+
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), e.quantityKind && (t += " quantity_kind " + e.quantityKind + "\n"), e.unit && (t += " unit \"" + s(e.unit) + "\"\n"), e.valueType && (t += " value_type " + e.valueType + "\n"), e.pairList && (t += uo(e.pairList)), e.origin && (t += " origin " + e.origin + "\n"), e.scope && (t += " scope " + e.scope + "\n"), e.category && (t += " category " + e.category + "\n"), e.isDimension !== null && e.isDimension !== void 0 && (t += " is_dimension " + (e.isDimension ? "true" : "false") + "\n"), e.enumRef && (t += " enum " + e.enumRef + "\n"), e.enumValues && e.enumValues.length > 0 && (t += " enum_values { " + e.enumValues.map(N).join(" ") + " }\n"), e.irdi && (t += " irdi \"" + s(e.irdi) + "\"\n"), e.derived && (t += " derived \"" + s(e.derived) + "\"\n"), e.note && (t += " note \"" + s(e.note) + "\"\n"), t += "}\n", t;
|
|
6874
|
+
}, mo = function(e, t) {
|
|
6760
6875
|
let n = {
|
|
6761
6876
|
id: e,
|
|
6762
6877
|
label: "",
|
|
@@ -6790,10 +6905,10 @@ var ro = function(e, t) {
|
|
|
6790
6905
|
} else s = y(o, s, e);
|
|
6791
6906
|
}
|
|
6792
6907
|
return (t) => (t.capabilities[e] = n, t);
|
|
6793
|
-
},
|
|
6908
|
+
}, ho = function(e) {
|
|
6794
6909
|
let t = "capability " + e.id + " {\n";
|
|
6795
6910
|
return e.label && (t += " label \"" + s(e.label) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.abstract && (t += " abstract true\n"), t += K("extends", e.extends, " "), t += K("requires", e.requires, " "), t += K("has_parameters", e.hasParameters, " "), t += K("satisfies_requirements", e.satisfiesRequirements, " "), t += K("verified_by_tests", e.verifiedByTests, " "), t += K("reference", e.referenceIds, " "), t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
6796
|
-
},
|
|
6911
|
+
}, go = function(e, t) {
|
|
6797
6912
|
let n = {
|
|
6798
6913
|
id: e,
|
|
6799
6914
|
kind: "",
|
|
@@ -6822,13 +6937,13 @@ var ro = function(e, t) {
|
|
|
6822
6937
|
} else s = y(o, s, e);
|
|
6823
6938
|
}
|
|
6824
6939
|
return (t) => (t.behaviors[e] = n, t);
|
|
6825
|
-
},
|
|
6940
|
+
}, _o = function(e) {
|
|
6826
6941
|
let t = "behavior " + e.id + " {\n";
|
|
6827
6942
|
e.kind && (t += " kind " + e.kind + "\n"), e.stimulus && (t += " stimulus " + e.stimulus + "\n"), e.response && (t += " response \"" + s(e.response) + "\"\n");
|
|
6828
6943
|
let n = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source ? [e.source] : [];
|
|
6829
6944
|
for (let e of n) t += E(e, " ", s);
|
|
6830
6945
|
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += K("verified_by", e.verifiedBy, " "), t += "}\n", t;
|
|
6831
|
-
},
|
|
6946
|
+
}, vo = function(e, t) {
|
|
6832
6947
|
let n = {
|
|
6833
6948
|
id: e,
|
|
6834
6949
|
role: "",
|
|
@@ -6843,7 +6958,7 @@ var ro = function(e, t) {
|
|
|
6843
6958
|
if (e === "role") n.role = a(o[s++]);
|
|
6844
6959
|
else if (e === "subject") n.subject = a(o[s++]);
|
|
6845
6960
|
else if (e === "description") n.description = a(o[s++]);
|
|
6846
|
-
else if (e === "entries") n.entries =
|
|
6961
|
+
else if (e === "entries") n.entries = yo(i(o[s++]));
|
|
6847
6962
|
else if (e === "source") {
|
|
6848
6963
|
let e = I(i(o[s++]));
|
|
6849
6964
|
n.sources.push(e), n.source ||= e;
|
|
@@ -6860,7 +6975,7 @@ var ro = function(e, t) {
|
|
|
6860
6975
|
}
|
|
6861
6976
|
return (t) => (t.conditionSets[e] = n, t);
|
|
6862
6977
|
};
|
|
6863
|
-
function
|
|
6978
|
+
function yo(e) {
|
|
6864
6979
|
let t = [], r = n(e), o = 0;
|
|
6865
6980
|
for (; o < r.length;) {
|
|
6866
6981
|
let e = P(r[o++]);
|
|
@@ -6883,7 +6998,7 @@ function uo(e) {
|
|
|
6883
6998
|
}
|
|
6884
6999
|
return t;
|
|
6885
7000
|
}
|
|
6886
|
-
var
|
|
7001
|
+
var bo = function(e) {
|
|
6887
7002
|
let t = "condition_set " + e.id + " {\n";
|
|
6888
7003
|
if (e.role && (t += " role " + e.role + "\n"), e.subject && (t += " subject " + e.subject + "\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.entries.length > 0) {
|
|
6889
7004
|
t += " entries {\n";
|
|
@@ -6897,7 +7012,7 @@ var fo = function(e) {
|
|
|
6897
7012
|
for (let e of n) t += E(e, " ", s);
|
|
6898
7013
|
return t += K("reference", e.referenceIds, " "), t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
6899
7014
|
};
|
|
6900
|
-
function
|
|
7015
|
+
function xo(e) {
|
|
6901
7016
|
let t = {}, r = n(e), i = 0;
|
|
6902
7017
|
for (; i < r.length;) {
|
|
6903
7018
|
let e = P(r[i++]);
|
|
@@ -6906,7 +7021,7 @@ function po(e) {
|
|
|
6906
7021
|
}
|
|
6907
7022
|
return t;
|
|
6908
7023
|
}
|
|
6909
|
-
function
|
|
7024
|
+
function So(e) {
|
|
6910
7025
|
let t = {}, r = n(e), i = 0;
|
|
6911
7026
|
for (; i < r.length;) {
|
|
6912
7027
|
let e = P(r[i++]);
|
|
@@ -6918,10 +7033,10 @@ function mo(e) {
|
|
|
6918
7033
|
}
|
|
6919
7034
|
return t;
|
|
6920
7035
|
}
|
|
6921
|
-
function
|
|
7036
|
+
function Co(e) {
|
|
6922
7037
|
return n(e).map(a).filter((e) => e.length > 0);
|
|
6923
7038
|
}
|
|
6924
|
-
function
|
|
7039
|
+
function wo(e) {
|
|
6925
7040
|
let t = {}, r = n(e), o = 0;
|
|
6926
7041
|
for (; o < r.length;) {
|
|
6927
7042
|
let e = P(r[o++]);
|
|
@@ -6933,13 +7048,13 @@ function go(e) {
|
|
|
6933
7048
|
}
|
|
6934
7049
|
return t;
|
|
6935
7050
|
}
|
|
6936
|
-
function
|
|
7051
|
+
function To(e) {
|
|
6937
7052
|
let t = {}, r = n(e), o = 0;
|
|
6938
7053
|
for (; o < r.length;) {
|
|
6939
7054
|
let e = P(r[o++]);
|
|
6940
7055
|
if (!e) break;
|
|
6941
7056
|
if (o < r.length && r[o].startsWith("{")) {
|
|
6942
|
-
t[e] =
|
|
7057
|
+
t[e] = Eo(i(r[o++]));
|
|
6943
7058
|
continue;
|
|
6944
7059
|
}
|
|
6945
7060
|
let n = "", s = "", c = !1;
|
|
@@ -6955,7 +7070,7 @@ function _o(e) {
|
|
|
6955
7070
|
}
|
|
6956
7071
|
return t;
|
|
6957
7072
|
}
|
|
6958
|
-
function
|
|
7073
|
+
function Eo(e) {
|
|
6959
7074
|
let t = {
|
|
6960
7075
|
symbol: "",
|
|
6961
7076
|
derivation: ""
|
|
@@ -6971,18 +7086,18 @@ function vo(e) {
|
|
|
6971
7086
|
}
|
|
6972
7087
|
return t;
|
|
6973
7088
|
}
|
|
6974
|
-
var
|
|
6975
|
-
function
|
|
7089
|
+
var Do = /* @__PURE__ */ new Set(["state", "behavior"]);
|
|
7090
|
+
function Oo(e, t, n) {
|
|
6976
7091
|
return e === "endpoint" ? (n < t.length && !t[n].startsWith("{") && n++, n < t.length && t[n].startsWith("{") && n++, n) : e === "serve" ? (n < t.length && n++, t[n] === "via" && (n += 2), n < t.length && t[n].startsWith("{") && n++, n) : n;
|
|
6977
7092
|
}
|
|
6978
|
-
function
|
|
7093
|
+
function ko(e, t, n, r, i) {
|
|
6979
7094
|
let a = P(n);
|
|
6980
7095
|
return e.misplacedAspects.push({
|
|
6981
7096
|
family: t,
|
|
6982
7097
|
aspect: a
|
|
6983
|
-
}), i < r.length && r[i].startsWith("{") ||
|
|
7098
|
+
}), i < r.length && r[i].startsWith("{") || Do.has(a) ? i++ : i = Oo(a, r, i), i;
|
|
6984
7099
|
}
|
|
6985
|
-
function
|
|
7100
|
+
function Ao(e, t) {
|
|
6986
7101
|
let r = e[t] ?? "";
|
|
6987
7102
|
if (r === "symbolic") return {
|
|
6988
7103
|
level: {
|
|
@@ -7011,7 +7126,7 @@ function So(e, t) {
|
|
|
7011
7126
|
next: t + 1
|
|
7012
7127
|
};
|
|
7013
7128
|
}
|
|
7014
|
-
function
|
|
7129
|
+
function jo(e) {
|
|
7015
7130
|
let t = [], r = n(e), o = 0;
|
|
7016
7131
|
for (; o < r.length;) {
|
|
7017
7132
|
let e = r[o++];
|
|
@@ -7029,12 +7144,12 @@ function Co(e) {
|
|
|
7029
7144
|
});
|
|
7030
7145
|
continue;
|
|
7031
7146
|
}
|
|
7032
|
-
t.push(
|
|
7147
|
+
t.push(Po(P(e), i(r[o++])));
|
|
7033
7148
|
}
|
|
7034
7149
|
return t;
|
|
7035
7150
|
}
|
|
7036
|
-
var
|
|
7037
|
-
function
|
|
7151
|
+
var Mo = ["mandatory", "optional"];
|
|
7152
|
+
function No(e, t) {
|
|
7038
7153
|
let r = {
|
|
7039
7154
|
attribute: "",
|
|
7040
7155
|
attributes: [],
|
|
@@ -7053,13 +7168,13 @@ function To(e, t) {
|
|
|
7053
7168
|
else if (t === "label") r.label = a(o[s++]);
|
|
7054
7169
|
else if (t === "obligation") {
|
|
7055
7170
|
let t = a(o[s++]);
|
|
7056
|
-
if (!
|
|
7171
|
+
if (!Mo.includes(t)) throw Error(`Parsing error: promise. ID ${e}: Unknown certificate obligation "${t}" (valid: ${Mo.join(", ")})`);
|
|
7057
7172
|
r.obligation = t;
|
|
7058
7173
|
} else i(o[s++]);
|
|
7059
7174
|
}
|
|
7060
7175
|
return r;
|
|
7061
7176
|
}
|
|
7062
|
-
function
|
|
7177
|
+
function Po(e, t) {
|
|
7063
7178
|
let r = {
|
|
7064
7179
|
id: e,
|
|
7065
7180
|
target: "",
|
|
@@ -7075,62 +7190,62 @@ function Eo(e, t) {
|
|
|
7075
7190
|
if (s >= o.length) break;
|
|
7076
7191
|
if (e === "target") r.target = a(o[s++]);
|
|
7077
7192
|
else if (e === "level") {
|
|
7078
|
-
let e =
|
|
7193
|
+
let e = Ao(o, s);
|
|
7079
7194
|
r.level = e.level, s = e.next;
|
|
7080
7195
|
} else if (e === "conditions") {
|
|
7081
7196
|
let e = M(o, s);
|
|
7082
7197
|
r.conditions = a(e.text), s = e.next;
|
|
7083
|
-
} else e === "statement" ? r.statement = a(o[s++]) : e === "verified_by" ? r.verifiedBy = G(o[s++]) : e === "source" ? r.source = I(i(o[s++])) : e === "certificate" ? r.certificate =
|
|
7198
|
+
} else e === "statement" ? r.statement = a(o[s++]) : e === "verified_by" ? r.verifiedBy = G(o[s++]) : e === "source" ? r.source = I(i(o[s++])) : e === "certificate" ? r.certificate = No(r.id, i(o[s++])) : i(o[s++]);
|
|
7084
7199
|
}
|
|
7085
7200
|
return r;
|
|
7086
7201
|
}
|
|
7087
|
-
function
|
|
7202
|
+
function Fo(e) {
|
|
7088
7203
|
return e.id === "" && !e.target && !e.level && !e.conditions && e.verifiedBy.length === 0 && !e.source && !e.certificate;
|
|
7089
7204
|
}
|
|
7090
|
-
function
|
|
7205
|
+
function Io(e, t) {
|
|
7091
7206
|
let r = n(e), a = 0;
|
|
7092
7207
|
for (; a < r.length;) {
|
|
7093
7208
|
let e = r[a++];
|
|
7094
7209
|
if (a >= r.length) break;
|
|
7095
|
-
if (e === "metadata") t.is.metadata =
|
|
7096
|
-
else if (e === "provenance") t.is.provenance =
|
|
7097
|
-
else if (e === "structure") t.is.structure =
|
|
7098
|
-
else if (e === "design_parameters") t.is.designParameters =
|
|
7099
|
-
else if (e === "designed_conditions") t.is.designedConditions =
|
|
7100
|
-
else if (e === "promises") t.is.promises =
|
|
7101
|
-
else if (e === "artifacts") t.is.artifacts =
|
|
7210
|
+
if (e === "metadata") t.is.metadata = xo(i(r[a++]));
|
|
7211
|
+
else if (e === "provenance") t.is.provenance = xo(i(r[a++]));
|
|
7212
|
+
else if (e === "structure") t.is.structure = Co(i(r[a++]));
|
|
7213
|
+
else if (e === "design_parameters") t.is.designParameters = So(i(r[a++]));
|
|
7214
|
+
else if (e === "designed_conditions") t.is.designedConditions = xo(i(r[a++]));
|
|
7215
|
+
else if (e === "promises") t.is.promises = jo(i(r[a++]));
|
|
7216
|
+
else if (e === "artifacts") t.is.artifacts = Co(i(r[a++]));
|
|
7102
7217
|
else if (e === "endpoint") {
|
|
7103
7218
|
let e = P(r[a++] ?? ""), n = a < r.length ? i(r[a++]) : "";
|
|
7104
|
-
e && t.is.endpoints.push(
|
|
7105
|
-
} else e === "composed_of" ? t.is.composedOf =
|
|
7219
|
+
e && t.is.endpoints.push(Ua(e, n));
|
|
7220
|
+
} else e === "composed_of" ? t.is.composedOf = Za(i(r[a++] ?? "")) : a = ko(t, "is", e, r, a);
|
|
7106
7221
|
}
|
|
7107
7222
|
}
|
|
7108
|
-
function
|
|
7223
|
+
function Lo(e, t) {
|
|
7109
7224
|
let r = n(e), o = 0;
|
|
7110
7225
|
for (; o < r.length;) {
|
|
7111
7226
|
let e = r[o++];
|
|
7112
7227
|
if (o >= r.length) break;
|
|
7113
|
-
if (e === "attributes") t.has.attributes =
|
|
7114
|
-
else if (e === "dimensions") t.has.dimensions =
|
|
7228
|
+
if (e === "attributes") t.has.attributes = So(i(r[o++]));
|
|
7229
|
+
else if (e === "dimensions") t.has.dimensions = wo(i(r[o++]));
|
|
7115
7230
|
else if (e === "state") t.has.state = a(r[o++]);
|
|
7116
|
-
else if (e === "characteristics") t.has.characteristics =
|
|
7117
|
-
else if (e === "environmental_context") t.has.environmentalContext =
|
|
7118
|
-
else if (e === "artifact_instances") t.has.artifactInstances =
|
|
7231
|
+
else if (e === "characteristics") t.has.characteristics = To(i(r[o++]));
|
|
7232
|
+
else if (e === "environmental_context") t.has.environmentalContext = Co(i(r[o++]));
|
|
7233
|
+
else if (e === "artifact_instances") t.has.artifactInstances = Co(i(r[o++]));
|
|
7119
7234
|
else if (e === "serve") {
|
|
7120
|
-
let e =
|
|
7235
|
+
let e = Ka(r, o);
|
|
7121
7236
|
t.has.serves.push(e.binding), o = e.next;
|
|
7122
|
-
} else o =
|
|
7237
|
+
} else o = ko(t, "has", e, r, o);
|
|
7123
7238
|
}
|
|
7124
7239
|
}
|
|
7125
|
-
function
|
|
7240
|
+
function Ro(e, t) {
|
|
7126
7241
|
let r = n(e), i = 0;
|
|
7127
7242
|
for (; i < r.length;) {
|
|
7128
7243
|
let e = r[i++];
|
|
7129
7244
|
if (i >= r.length) break;
|
|
7130
|
-
e === "behavior" ? t.does.behaviors.push(a(r[i++])) : i =
|
|
7245
|
+
e === "behavior" ? t.does.behaviors.push(a(r[i++])) : i = ko(t, "does", e, r, i);
|
|
7131
7246
|
}
|
|
7132
7247
|
}
|
|
7133
|
-
var
|
|
7248
|
+
var zo = function(e, t) {
|
|
7134
7249
|
let n = {
|
|
7135
7250
|
id: e,
|
|
7136
7251
|
extends: "",
|
|
@@ -7160,11 +7275,11 @@ var jo = function(e, t) {
|
|
|
7160
7275
|
for (; s < o.length;) {
|
|
7161
7276
|
let e = o[s++];
|
|
7162
7277
|
if (s >= o.length) break;
|
|
7163
|
-
e === "extends" ? n.extends = a(o[s++]) : e === "is" ?
|
|
7278
|
+
e === "extends" ? n.extends = a(o[s++]) : e === "is" ? Io(i(o[s++]), n) : e === "has" ? Lo(i(o[s++]), n) : e === "does" ? Ro(i(o[s++]), n) : e === "reference" ? n.referenceIds = q(o[s++]) : s = y(o, s, e);
|
|
7164
7279
|
}
|
|
7165
7280
|
return (t) => (t.subjects[e] = n, t);
|
|
7166
7281
|
};
|
|
7167
|
-
function
|
|
7282
|
+
function Bo(e, t) {
|
|
7168
7283
|
return {
|
|
7169
7284
|
id: t.id,
|
|
7170
7285
|
extends: "",
|
|
@@ -7214,34 +7329,34 @@ function Mo(e, t) {
|
|
|
7214
7329
|
misplacedAspects: t.misplacedAspects
|
|
7215
7330
|
};
|
|
7216
7331
|
}
|
|
7217
|
-
function
|
|
7332
|
+
function Vo(e, t) {
|
|
7218
7333
|
let n = (t, r) => {
|
|
7219
7334
|
let i = t.extends;
|
|
7220
7335
|
if (!i || r.has(i)) return t;
|
|
7221
7336
|
let a = e.subjects[i];
|
|
7222
|
-
return a ? (r.add(i),
|
|
7337
|
+
return a ? (r.add(i), Bo(n(a, r), t)) : t;
|
|
7223
7338
|
};
|
|
7224
7339
|
return n(t, /* @__PURE__ */ new Set([t.id]));
|
|
7225
7340
|
}
|
|
7226
|
-
function
|
|
7341
|
+
function Ho(e, t) {
|
|
7227
7342
|
let n = Object.keys(t);
|
|
7228
7343
|
return n.length === 0 ? "" : " " + e + " { " + n.map((e) => e + " " + N(t[e])).join(" ") + " }\n";
|
|
7229
7344
|
}
|
|
7230
|
-
function
|
|
7345
|
+
function Uo(e, t) {
|
|
7231
7346
|
let n = Object.keys(t);
|
|
7232
7347
|
return n.length === 0 ? "" : " " + e + " { " + n.map((e) => e + " :" + (t[e] ? " " + N(t[e]) : "")).join(" ") + " }\n";
|
|
7233
7348
|
}
|
|
7234
|
-
function
|
|
7349
|
+
function Wo(e, t) {
|
|
7235
7350
|
return t.length === 0 ? "" : " " + e + " { " + t.map(N).join(" ") + " }\n";
|
|
7236
7351
|
}
|
|
7237
|
-
function
|
|
7352
|
+
function Go(e) {
|
|
7238
7353
|
let t = Object.keys(e);
|
|
7239
7354
|
return t.length === 0 ? "" : " dimensions { " + t.map((t) => t + " in { " + e[t].join(", ") + " }").join(" ") + " }\n";
|
|
7240
7355
|
}
|
|
7241
|
-
function
|
|
7356
|
+
function Ko(e) {
|
|
7242
7357
|
return /^ocl\{[\s\S]*\}$/.test(e) ? e : N(e);
|
|
7243
7358
|
}
|
|
7244
|
-
function
|
|
7359
|
+
function qo(e) {
|
|
7245
7360
|
if (e.kind === "symbolic") return "symbolic " + N(e.symbolic ?? "");
|
|
7246
7361
|
if (e.kind === "range") {
|
|
7247
7362
|
let t = "";
|
|
@@ -7249,112 +7364,112 @@ function zo(e) {
|
|
|
7249
7364
|
}
|
|
7250
7365
|
return xe(e.quantity ?? { value: "" });
|
|
7251
7366
|
}
|
|
7252
|
-
function
|
|
7367
|
+
function Jo(e, t) {
|
|
7253
7368
|
let n = t + " ", r = t + "certificate {\n";
|
|
7254
7369
|
return e.attribute && (r += n + "attribute " + N(e.attribute) + "\n"), e.attributes.length > 0 && (r += n + "attributes { " + e.attributes.map(N).join(" ") + " }\n"), e.dimension && (r += n + "dimension " + N(e.dimension) + "\n"), e.type && (r += n + "type " + N(e.type) + "\n"), e.label && (r += n + "label \"" + s(e.label) + "\"\n"), e.obligation && (r += n + "obligation " + N(e.obligation) + "\n"), r += t + "}\n", r;
|
|
7255
7370
|
}
|
|
7256
|
-
function
|
|
7371
|
+
function Yo(e, t, n = "") {
|
|
7257
7372
|
let r = t + " ", i = t + n + N(e.id) + " {\n";
|
|
7258
|
-
return e.target && (i += r + "target " + N(e.target) + "\n"), e.level && (i += r + "level " +
|
|
7373
|
+
return e.target && (i += r + "target " + N(e.target) + "\n"), e.level && (i += r + "level " + qo(e.level) + "\n"), e.conditions && (i += r + "conditions " + Ko(e.conditions) + "\n"), e.statement && (i += r + "statement \"" + s(e.statement) + "\"\n"), i += K("verified_by", e.verifiedBy, r), i += W("source", e.source ?? null, r), e.certificate && (i += Jo(e.certificate, r)), i += t + "}\n", i;
|
|
7259
7374
|
}
|
|
7260
|
-
function
|
|
7375
|
+
function Xo(e) {
|
|
7261
7376
|
if (e.length === 0) return "";
|
|
7262
|
-
if (e.every(
|
|
7377
|
+
if (e.every(Fo)) return " promises { " + e.map((e) => N(e.statement)).join(" ") + " }\n";
|
|
7263
7378
|
let t = " promises {\n";
|
|
7264
7379
|
for (let n of e) {
|
|
7265
|
-
if (
|
|
7380
|
+
if (Fo(n)) {
|
|
7266
7381
|
t += " " + N(n.statement) + "\n";
|
|
7267
7382
|
continue;
|
|
7268
7383
|
}
|
|
7269
|
-
t +=
|
|
7384
|
+
t += Yo(n, " ");
|
|
7270
7385
|
}
|
|
7271
7386
|
return t += " }\n", t;
|
|
7272
7387
|
}
|
|
7273
|
-
function
|
|
7388
|
+
function Zo(e) {
|
|
7274
7389
|
let t = Object.keys(e);
|
|
7275
7390
|
if (t.length === 0) return "";
|
|
7276
7391
|
let n = " characteristics {\n";
|
|
7277
7392
|
for (let r of t) {
|
|
7278
7393
|
let t = e[r];
|
|
7279
7394
|
if (t.behavior || t.quantityKind || t.unit || t.source && (t.source.doc || t.source.clause)) {
|
|
7280
|
-
n += " " + r + " {\n", t.symbol && (n += " symbol \"" + s(t.symbol) + "\"\n"), t.derivation && (n += " derivation " +
|
|
7395
|
+
n += " " + r + " {\n", t.symbol && (n += " symbol \"" + s(t.symbol) + "\"\n"), t.derivation && (n += " derivation " + Ko(t.derivation) + "\n"), t.behavior && (n += " behavior " + N(t.behavior) + "\n"), t.quantityKind && (n += " quantity_kind " + N(t.quantityKind) + "\n"), t.unit && (n += " unit \"" + s(t.unit) + "\"\n"), n += W("source", t.source ?? null, " "), n += " }\n";
|
|
7281
7396
|
continue;
|
|
7282
7397
|
}
|
|
7283
|
-
n += " " + r + (t.symbol ? " " + t.symbol : ""), t.derivation && (n += " = " +
|
|
7398
|
+
n += " " + r + (t.symbol ? " " + t.symbol : ""), t.derivation && (n += " = " + Ko(t.derivation)), n += "\n";
|
|
7284
7399
|
}
|
|
7285
7400
|
return n += " }\n", n;
|
|
7286
7401
|
}
|
|
7287
|
-
function
|
|
7402
|
+
function Qo(e) {
|
|
7288
7403
|
let t = "";
|
|
7289
|
-
for (let n of e) t +=
|
|
7404
|
+
for (let n of e) t += Ga(n, " ");
|
|
7290
7405
|
return t;
|
|
7291
7406
|
}
|
|
7292
|
-
function
|
|
7407
|
+
function $o(e) {
|
|
7293
7408
|
let t = "";
|
|
7294
|
-
for (let n of e) t +=
|
|
7409
|
+
for (let n of e) t += qa(n, " ");
|
|
7295
7410
|
return t;
|
|
7296
7411
|
}
|
|
7297
|
-
var
|
|
7412
|
+
var es = function(e) {
|
|
7298
7413
|
let t = "subject " + e.id + " {\n";
|
|
7299
7414
|
e.extends && (t += " extends " + e.extends + "\n");
|
|
7300
|
-
let n =
|
|
7415
|
+
let n = Ho("metadata", e.is.metadata) + Ho("provenance", e.is.provenance) + Wo("structure", e.is.structure) + Uo("design_parameters", e.is.designParameters) + Ho("designed_conditions", e.is.designedConditions) + Xo(e.is.promises) + Wo("artifacts", e.is.artifacts) + Qo(e.is.endpoints) + (e.is.composedOf ? $a(e.is.composedOf, " ") : "");
|
|
7301
7416
|
n && (t += " is {\n" + n + " }\n");
|
|
7302
|
-
let r =
|
|
7417
|
+
let r = Uo("attributes", e.has.attributes) + Go(e.has.dimensions) + (e.has.state ? " state " + N(e.has.state) + "\n" : "") + Zo(e.has.characteristics) + Wo("environmental_context", e.has.environmentalContext) + Wo("artifact_instances", e.has.artifactInstances) + $o(e.has.serves);
|
|
7303
7418
|
r && (t += " has {\n" + r + " }\n");
|
|
7304
7419
|
let i = "";
|
|
7305
7420
|
for (let t of e.does.behaviors) i += " behavior " + N(t) + "\n";
|
|
7306
7421
|
return i && (t += " does {\n" + i + " }\n"), t += K("reference", e.referenceIds, " "), t += "}\n", t;
|
|
7307
|
-
},
|
|
7422
|
+
}, ts = {
|
|
7308
7423
|
keyword: "instrument",
|
|
7309
7424
|
field: "instruments",
|
|
7310
7425
|
takesID: !0,
|
|
7311
|
-
parse:
|
|
7312
|
-
dump:
|
|
7313
|
-
},
|
|
7426
|
+
parse: eo,
|
|
7427
|
+
dump: co
|
|
7428
|
+
}, ns = {
|
|
7314
7429
|
keyword: "attribute_definition",
|
|
7315
7430
|
field: "attributeDefinitions",
|
|
7316
7431
|
takesID: !0,
|
|
7317
|
-
parse:
|
|
7318
|
-
dump:
|
|
7319
|
-
},
|
|
7432
|
+
parse: fo,
|
|
7433
|
+
dump: po
|
|
7434
|
+
}, rs = {
|
|
7320
7435
|
keyword: "capability",
|
|
7321
7436
|
field: "capabilities",
|
|
7322
7437
|
takesID: !0,
|
|
7323
|
-
parse:
|
|
7324
|
-
dump:
|
|
7325
|
-
},
|
|
7438
|
+
parse: mo,
|
|
7439
|
+
dump: ho
|
|
7440
|
+
}, is = {
|
|
7326
7441
|
keyword: "behavior",
|
|
7327
7442
|
field: "behaviors",
|
|
7328
7443
|
takesID: !0,
|
|
7329
|
-
parse:
|
|
7330
|
-
dump:
|
|
7331
|
-
},
|
|
7444
|
+
parse: go,
|
|
7445
|
+
dump: _o
|
|
7446
|
+
}, as = {
|
|
7332
7447
|
keyword: "condition_set",
|
|
7333
7448
|
field: "conditionSets",
|
|
7334
7449
|
takesID: !0,
|
|
7335
|
-
parse:
|
|
7336
|
-
dump:
|
|
7337
|
-
},
|
|
7450
|
+
parse: vo,
|
|
7451
|
+
dump: bo
|
|
7452
|
+
}, os = {
|
|
7338
7453
|
keyword: "subject",
|
|
7339
7454
|
field: "subjects",
|
|
7340
7455
|
takesID: !0,
|
|
7341
|
-
parse:
|
|
7342
|
-
resolve:
|
|
7343
|
-
dump:
|
|
7456
|
+
parse: zo,
|
|
7457
|
+
resolve: Vo,
|
|
7458
|
+
dump: es
|
|
7344
7459
|
};
|
|
7345
7460
|
//#endregion
|
|
7346
7461
|
//#region src/ser-des/config/instance.ts
|
|
7347
|
-
function
|
|
7462
|
+
function ss(e) {
|
|
7348
7463
|
return !e.startsWith("\"") && e.endsWith(":") && e.length > 1;
|
|
7349
7464
|
}
|
|
7350
|
-
function
|
|
7465
|
+
function cs(e) {
|
|
7351
7466
|
let t = {}, r = n(e), o = 0;
|
|
7352
7467
|
for (; o < r.length;) {
|
|
7353
7468
|
let e = P(r[o++]);
|
|
7354
7469
|
if (!e) break;
|
|
7355
7470
|
r[o] === ":" && o++;
|
|
7356
7471
|
let n = [];
|
|
7357
|
-
for (; o < r.length && r[o + 1] !== ":" &&
|
|
7472
|
+
for (; o < r.length && r[o + 1] !== ":" && !ss(r[o]);) n.push(r[o++]);
|
|
7358
7473
|
if (n.length === 0) {
|
|
7359
7474
|
t[e] = { value: "" };
|
|
7360
7475
|
continue;
|
|
@@ -7372,7 +7487,7 @@ function es(e) {
|
|
|
7372
7487
|
}
|
|
7373
7488
|
return t;
|
|
7374
7489
|
}
|
|
7375
|
-
function
|
|
7490
|
+
function ls(e) {
|
|
7376
7491
|
let t = {}, r = n(e), i = 0;
|
|
7377
7492
|
for (; i < r.length;) {
|
|
7378
7493
|
let e = P(r[i++]);
|
|
@@ -7381,18 +7496,18 @@ function ts(e) {
|
|
|
7381
7496
|
}
|
|
7382
7497
|
return t;
|
|
7383
7498
|
}
|
|
7384
|
-
function
|
|
7499
|
+
function us(e) {
|
|
7385
7500
|
return n(a(e)).map(a).filter((e) => e.length > 0);
|
|
7386
7501
|
}
|
|
7387
|
-
function
|
|
7502
|
+
function ds(e, t) {
|
|
7388
7503
|
let r = n(e), a = 0;
|
|
7389
7504
|
for (; a < r.length;) {
|
|
7390
7505
|
let e = r[a++];
|
|
7391
7506
|
if (a >= r.length) break;
|
|
7392
|
-
e === "attributes" ? t.has.attributes =
|
|
7507
|
+
e === "attributes" ? t.has.attributes = cs(i(r[a++])) : e === "dimensions" ? t.has.dimensions = ls(i(r[a++])) : e === "test_context" ? t.has.testContext = cs(i(r[a++])) : i(r[a++]);
|
|
7393
7508
|
}
|
|
7394
7509
|
}
|
|
7395
|
-
var
|
|
7510
|
+
var fs = function(e, t) {
|
|
7396
7511
|
let n = {
|
|
7397
7512
|
id: e,
|
|
7398
7513
|
of: "",
|
|
@@ -7411,39 +7526,39 @@ var is = function(e, t) {
|
|
|
7411
7526
|
for (; s < o.length;) {
|
|
7412
7527
|
let e = o[s++];
|
|
7413
7528
|
if (s >= o.length) break;
|
|
7414
|
-
e === "of" ? n.of = a(o[s++]) : e === "level" ? n.level = a(o[s++]) : e === "model" ? n.model = a(o[s++]) : e === "group" ? n.group = a(o[s++]) : e === "family" ? n.family = a(o[s++]) : e === "definition_versions" ? n.definitionVersions =
|
|
7529
|
+
e === "of" ? n.of = a(o[s++]) : e === "level" ? n.level = a(o[s++]) : e === "model" ? n.model = a(o[s++]) : e === "group" ? n.group = a(o[s++]) : e === "family" ? n.family = a(o[s++]) : e === "definition_versions" ? n.definitionVersions = ls(i(o[s++])) : e === "has" ? ds(i(o[s++]), n) : e === "reference" ? n.referenceIds = us(o[s++]) : i(o[s++]);
|
|
7415
7530
|
}
|
|
7416
7531
|
return (t) => (t.instances[e] = n, t);
|
|
7417
7532
|
};
|
|
7418
|
-
function
|
|
7533
|
+
function ps(e, t) {
|
|
7419
7534
|
let n = Object.keys(t);
|
|
7420
7535
|
return n.length === 0 ? "" : " " + e + " { " + n.map((e) => e + " : " + be(t[e])).join(" ") + " }\n";
|
|
7421
7536
|
}
|
|
7422
|
-
function
|
|
7537
|
+
function ms(e, t) {
|
|
7423
7538
|
let n = Object.keys(t);
|
|
7424
7539
|
return n.length === 0 ? "" : " " + e + " { " + n.map((e) => e + " : " + N(t[e])).join(" ") + " }\n";
|
|
7425
7540
|
}
|
|
7426
|
-
var
|
|
7541
|
+
var hs = {
|
|
7427
7542
|
keyword: "instance",
|
|
7428
7543
|
field: "instances",
|
|
7429
7544
|
takesID: !0,
|
|
7430
|
-
parse:
|
|
7545
|
+
parse: fs,
|
|
7431
7546
|
dump: function(e) {
|
|
7432
7547
|
let t = "instance " + e.id + " {\n";
|
|
7433
7548
|
e.of && (t += " of " + e.of + "\n"), e.level && (t += " level " + e.level + "\n"), e.model && (t += " model " + e.model + "\n"), e.group && (t += " group " + e.group + "\n"), e.family && (t += " family " + e.family + "\n");
|
|
7434
7549
|
let n = Object.keys(e.definitionVersions);
|
|
7435
7550
|
n.length > 0 && (t += " definition_versions { " + n.map((t) => t + " : " + N(e.definitionVersions[t])).join(" ") + " }\n");
|
|
7436
|
-
let r =
|
|
7551
|
+
let r = ps("attributes", e.has.attributes) + ms("dimensions", e.has.dimensions) + ps("test_context", e.has.testContext);
|
|
7437
7552
|
return r && (t += " has {\n" + r + " }\n"), e.referenceIds.length > 0 && (t += " reference { " + e.referenceIds.join(" ") + " }\n"), t += "}\n", t;
|
|
7438
7553
|
}
|
|
7439
|
-
},
|
|
7554
|
+
}, gs = [
|
|
7440
7555
|
"string",
|
|
7441
7556
|
"designation",
|
|
7442
7557
|
"serial",
|
|
7443
7558
|
"year",
|
|
7444
7559
|
"mark",
|
|
7445
7560
|
"map"
|
|
7446
|
-
],
|
|
7561
|
+
], _s = ["marked-on-instrument", "accompanying-document"], vs = (e, t) => {
|
|
7447
7562
|
let r = {
|
|
7448
7563
|
id: e,
|
|
7449
7564
|
label: "",
|
|
@@ -7458,11 +7573,11 @@ var ss = {
|
|
|
7458
7573
|
if (t === "label") r.label = a(o());
|
|
7459
7574
|
else if (t === "type") {
|
|
7460
7575
|
let t = a(o());
|
|
7461
|
-
if (!
|
|
7576
|
+
if (!gs.includes(t)) throw Error(`Parsing error: identity_slot. ID ${e}: Unknown identity slot type "${t}" (valid: ${gs.join(", ")})`);
|
|
7462
7577
|
r.type = t;
|
|
7463
7578
|
} else if (t === "presentation") {
|
|
7464
7579
|
let t = n(a(o())).map(P).map(a).filter((e) => e.length > 0);
|
|
7465
|
-
for (let n of t) if (!
|
|
7580
|
+
for (let n of t) if (!_s.includes(n)) throw Error(`Parsing error: identity_slot. ID ${e}: Unknown presentation channel "${n}" (valid: ${_s.join(", ")})`);
|
|
7466
7581
|
r.presentation = t;
|
|
7467
7582
|
} else if (t === "optional") r.optional = o() === "true";
|
|
7468
7583
|
else if (t === "definition") r.definition = a(o());
|
|
@@ -7474,10 +7589,10 @@ var ss = {
|
|
|
7474
7589
|
construct: "identity_slot",
|
|
7475
7590
|
id: e
|
|
7476
7591
|
}), (t) => (t.identitySlots[e] = r, t);
|
|
7477
|
-
},
|
|
7592
|
+
}, ys = function(e) {
|
|
7478
7593
|
let t = "identity_slot " + e.id + " {\n";
|
|
7479
7594
|
return e.label && (t += " label \"" + s(e.label) + "\"\n"), e.type && (t += " type " + N(e.type) + "\n"), e.presentation.length > 0 && (t += " presentation { " + e.presentation.map(N).join(" ") + " }\n"), e.optional && (t += " optional true\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.metamodelClass && (t += " metamodel_class " + N(e.metamodelClass) + "\n"), e.source && (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
7480
|
-
},
|
|
7595
|
+
}, bs = [
|
|
7481
7596
|
"marking",
|
|
7482
7597
|
"inscription",
|
|
7483
7598
|
"sealing",
|
|
@@ -7489,7 +7604,7 @@ var ss = {
|
|
|
7489
7604
|
"construction",
|
|
7490
7605
|
"documentation",
|
|
7491
7606
|
"other"
|
|
7492
|
-
],
|
|
7607
|
+
], xs = (e, t) => {
|
|
7493
7608
|
let r = {
|
|
7494
7609
|
id: e,
|
|
7495
7610
|
label: "",
|
|
@@ -7506,7 +7621,7 @@ var ss = {
|
|
|
7506
7621
|
if (t === "label") r.label = a(o());
|
|
7507
7622
|
else if (t === "kind") {
|
|
7508
7623
|
let t = a(o());
|
|
7509
|
-
if (!
|
|
7624
|
+
if (!bs.includes(t)) throw Error(`Parsing error: aspect. ID ${e}: Unknown aspect kind "${t}" (valid: ${bs.join(", ")})`);
|
|
7510
7625
|
r.kind = t;
|
|
7511
7626
|
} else if (t === "definition") r.definition = a(o());
|
|
7512
7627
|
else if (t === "metamodel_class") r.metamodelClass = a(o());
|
|
@@ -7521,10 +7636,10 @@ var ss = {
|
|
|
7521
7636
|
construct: "aspect",
|
|
7522
7637
|
id: e
|
|
7523
7638
|
}), (t) => (t.aspects[e] = r, t);
|
|
7524
|
-
},
|
|
7639
|
+
}, Ss = function(e) {
|
|
7525
7640
|
let t = "aspect " + e.id + " {\n";
|
|
7526
7641
|
return e.label && (t += " label \"" + s(e.label) + "\"\n"), e.kind && (t += " kind " + N(e.kind) + "\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.metamodelClass && (t += " metamodel_class " + N(e.metamodelClass) + "\n"), e.termRef && (t += " term_ref " + N(e.termRef) + "\n"), e.component && (t += " component " + N(e.component) + "\n"), e.attribute && (t += " attribute " + N(e.attribute) + "\n"), e.contains.length > 0 && (t += " contains { " + e.contains.map(N).join(" ") + " }\n"), e.source && (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
7527
|
-
},
|
|
7642
|
+
}, Cs = (e, t) => {
|
|
7528
7643
|
let n = {
|
|
7529
7644
|
id: e,
|
|
7530
7645
|
promises: []
|
|
@@ -7532,22 +7647,22 @@ var ss = {
|
|
|
7532
7647
|
return v(t, (e, t) => {
|
|
7533
7648
|
if (e === "promise") {
|
|
7534
7649
|
let e = a(P(t()));
|
|
7535
|
-
n.promises.push(
|
|
7650
|
+
n.promises.push(Po(e, i(t())));
|
|
7536
7651
|
} else return !1;
|
|
7537
7652
|
return !0;
|
|
7538
7653
|
}, {
|
|
7539
7654
|
construct: "promise_set",
|
|
7540
7655
|
id: e
|
|
7541
7656
|
}), (t) => (t.promiseSets[e] = n, t);
|
|
7542
|
-
},
|
|
7657
|
+
}, ws = function(e) {
|
|
7543
7658
|
let t = "promise_set " + N(e.id) + " {\n";
|
|
7544
|
-
for (let n of e.promises) t +=
|
|
7659
|
+
for (let n of e.promises) t += Yo(n, " ", "promise ");
|
|
7545
7660
|
return t += "}\n", t;
|
|
7546
|
-
},
|
|
7661
|
+
}, Ts = [
|
|
7547
7662
|
"shall",
|
|
7548
7663
|
"should",
|
|
7549
7664
|
"may"
|
|
7550
|
-
],
|
|
7665
|
+
], Es = (e, t) => {
|
|
7551
7666
|
let n = {
|
|
7552
7667
|
id: e,
|
|
7553
7668
|
declarationForm: "",
|
|
@@ -7568,7 +7683,7 @@ var ss = {
|
|
|
7568
7683
|
else if (n === "description") t.description = a(r());
|
|
7569
7684
|
else if (n === "obligation") {
|
|
7570
7685
|
let n = a(r());
|
|
7571
|
-
if (!
|
|
7686
|
+
if (!Ts.includes(n)) throw Error(`Parsing error: application_declaration. ID ${e}: Unknown obligation "${n}" (valid: ${Ts.join(", ")})`);
|
|
7572
7687
|
t.obligation = n;
|
|
7573
7688
|
} else if (n === "source") t.source = I(i(r()));
|
|
7574
7689
|
else return !1;
|
|
@@ -7583,12 +7698,12 @@ var ss = {
|
|
|
7583
7698
|
construct: "application_declaration",
|
|
7584
7699
|
id: e
|
|
7585
7700
|
}), (t) => (t.applicationDeclarations[e] = n, t);
|
|
7586
|
-
},
|
|
7701
|
+
}, Ds = function(e) {
|
|
7587
7702
|
let t = "application_declaration " + N(e.id) + " {\n";
|
|
7588
7703
|
e.declarationForm && (t += " declaration_form " + N(e.declarationForm) + "\n");
|
|
7589
7704
|
for (let n of e.documents) t += " document " + N(n.id) + " {\n", n.name && (t += " name \"" + s(n.name) + "\"\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), n.obligation && (t += " obligation " + N(n.obligation) + "\n"), n.source && (n.source.doc || n.source.clause) && (t += " source {\n", n.source.doc && (t += " doc \"" + s(n.source.doc) + "\"\n"), n.source.clause && (t += " clause \"" + s(n.source.clause) + "\"\n"), t += " }\n"), t += " }\n";
|
|
7590
7705
|
return t += "}\n", t;
|
|
7591
|
-
},
|
|
7706
|
+
}, Os = (e, t) => {
|
|
7592
7707
|
let n = {
|
|
7593
7708
|
id: e,
|
|
7594
7709
|
fields: []
|
|
@@ -7615,28 +7730,28 @@ var ss = {
|
|
|
7615
7730
|
construct: "calculation_context",
|
|
7616
7731
|
id: e
|
|
7617
7732
|
}), (t) => (t.calculationContexts[e] = n, t);
|
|
7618
|
-
},
|
|
7733
|
+
}, ks = function(e) {
|
|
7619
7734
|
let t = "calculation_context " + N(e.id) + " {\n";
|
|
7620
7735
|
for (let n of e.fields) {
|
|
7621
7736
|
let e = " field " + N(n.id) + " { source " + N(n.source);
|
|
7622
7737
|
n.expression && (e += " expression \"" + s(n.expression) + "\""), t += e + " }\n";
|
|
7623
7738
|
}
|
|
7624
7739
|
return t += "}\n", t;
|
|
7625
|
-
},
|
|
7740
|
+
}, As = [
|
|
7626
7741
|
"integer",
|
|
7627
7742
|
"number",
|
|
7628
7743
|
"string",
|
|
7629
7744
|
"text",
|
|
7630
7745
|
"boolean",
|
|
7631
7746
|
"date"
|
|
7632
|
-
],
|
|
7747
|
+
], js = [
|
|
7633
7748
|
"MUST",
|
|
7634
7749
|
"SHALL",
|
|
7635
7750
|
"RECOMMEND",
|
|
7636
7751
|
"SHOULD",
|
|
7637
7752
|
"MAY",
|
|
7638
7753
|
"OPTIONAL"
|
|
7639
|
-
],
|
|
7754
|
+
], Ms = (e, t) => {
|
|
7640
7755
|
let n = {
|
|
7641
7756
|
id: e,
|
|
7642
7757
|
label: "",
|
|
@@ -7659,14 +7774,14 @@ var ss = {
|
|
|
7659
7774
|
if (n === "label") t.label = a(r());
|
|
7660
7775
|
else if (n === "type") {
|
|
7661
7776
|
let n = a(r());
|
|
7662
|
-
if (!
|
|
7777
|
+
if (!As.includes(n)) throw Error(`Parsing error: evaluation_dimensions. ID ${e}: Unknown field type "${n}" (valid: ${As.join(", ")})`);
|
|
7663
7778
|
t.type = n;
|
|
7664
7779
|
} else if (n === "enum") t.enumRef = a(r());
|
|
7665
7780
|
else if (n === "required") t.required = r() === "true";
|
|
7666
7781
|
else if (n === "editable") t.editable = r() === "true";
|
|
7667
7782
|
else if (n === "setting") {
|
|
7668
7783
|
let n = a(r());
|
|
7669
|
-
if (!
|
|
7784
|
+
if (!js.includes(n)) throw Error(`Parsing error: evaluation_dimensions. ID ${e}: Unknown setting "${n}" (valid: ${js.join(", ")})`);
|
|
7670
7785
|
t.setting = n;
|
|
7671
7786
|
} else if (n === "multiple") t.multiple = r() === "true";
|
|
7672
7787
|
else return !1;
|
|
@@ -7681,12 +7796,12 @@ var ss = {
|
|
|
7681
7796
|
construct: "evaluation_dimensions",
|
|
7682
7797
|
id: e
|
|
7683
7798
|
}), (t) => (t.evaluationDimensions[e] = n, t);
|
|
7684
|
-
},
|
|
7799
|
+
}, Ns = function(e) {
|
|
7685
7800
|
let t = "evaluation_dimensions " + N(e.id) + " {\n";
|
|
7686
7801
|
e.label && (t += " label \"" + s(e.label) + "\"\n");
|
|
7687
7802
|
for (let n of e.fields) t += " field " + N(n.id) + " {\n", n.label && (t += " label \"" + s(n.label) + "\"\n"), n.type && (t += " type " + N(n.type) + "\n"), n.enumRef && (t += " enum " + N(n.enumRef) + "\n"), t += " required " + (n.required ? "true" : "false") + "\n", t += " editable " + (n.editable ? "true" : "false") + "\n", n.setting && (t += " setting " + N(n.setting) + "\n"), n.multiple && (t += " multiple true\n"), t += " }\n";
|
|
7688
7803
|
return t += "}\n", t;
|
|
7689
|
-
},
|
|
7804
|
+
}, Ps = (e, t) => {
|
|
7690
7805
|
let r = {
|
|
7691
7806
|
id: e,
|
|
7692
7807
|
dimensions: {},
|
|
@@ -7706,17 +7821,17 @@ var ss = {
|
|
|
7706
7821
|
construct: "evaluation_profile",
|
|
7707
7822
|
id: e
|
|
7708
7823
|
}), (t) => (t.evaluationProfiles[e] = r, t);
|
|
7709
|
-
},
|
|
7824
|
+
}, Fs = function(e) {
|
|
7710
7825
|
let t = "evaluation_profile " + N(e.id) + " {\n", n = Object.keys(e.dimensions);
|
|
7711
7826
|
return n.length > 0 && (t += " dimensions { " + n.map((t) => {
|
|
7712
7827
|
let n = e.dimensions[t];
|
|
7713
7828
|
return Array.isArray(n) ? N(t) + " { " + n.map(N).join(" ") + " }" : N(t) + " " + N(n);
|
|
7714
7829
|
}).join(" ") + " }\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), t += "}\n", t;
|
|
7715
|
-
},
|
|
7716
|
-
function
|
|
7830
|
+
}, Is = ["mandatory", "optional"];
|
|
7831
|
+
function Ls(e) {
|
|
7717
7832
|
return n(a(e)).map(P).map(a).filter((e) => e.length > 0);
|
|
7718
7833
|
}
|
|
7719
|
-
var
|
|
7834
|
+
var Rs = (e, t) => {
|
|
7720
7835
|
let n = {
|
|
7721
7836
|
id: e,
|
|
7722
7837
|
numberFormat: "",
|
|
@@ -7754,11 +7869,11 @@ var As = (e, t) => {
|
|
|
7754
7869
|
if (n === "type") t.type = a(r());
|
|
7755
7870
|
else if (n === "label") t.label = a(r());
|
|
7756
7871
|
else if (n === "attribute") t.attribute = a(r());
|
|
7757
|
-
else if (n === "attributes") t.attributes =
|
|
7872
|
+
else if (n === "attributes") t.attributes = Ls(r());
|
|
7758
7873
|
else if (n === "dimension") t.dimension = a(r());
|
|
7759
7874
|
else if (n === "obligation") {
|
|
7760
7875
|
let n = a(r());
|
|
7761
|
-
if (!
|
|
7876
|
+
if (!Is.includes(n)) throw Error(`Parsing error: certificate_template. ID ${e}: Unknown obligation "${n}" (valid: ${Is.join(", ")})`);
|
|
7762
7877
|
t.obligation = n;
|
|
7763
7878
|
} else return !1;
|
|
7764
7879
|
return !0;
|
|
@@ -7792,7 +7907,7 @@ var As = (e, t) => {
|
|
|
7792
7907
|
construct: "certificate_template",
|
|
7793
7908
|
id: e
|
|
7794
7909
|
}), (t) => (t.certificateTemplates[e] = n, t);
|
|
7795
|
-
},
|
|
7910
|
+
}, zs = function(e) {
|
|
7796
7911
|
let t = "certificate_template " + N(e.id) + " {\n";
|
|
7797
7912
|
e.numberFormat && (t += " number_format \"" + s(e.numberFormat) + "\"\n"), e.dimensionLabels && (t += " dimension_labels {\n", t += " pattern \"" + s(e.dimensionLabels.pattern) + "\"\n", e.dimensionLabels.separator && (t += " separator \"" + s(e.dimensionLabels.separator) + "\"\n"), t += " }\n");
|
|
7798
7913
|
for (let n of e.characteristics) t += " characteristic " + N(n.id) + " {\n", n.type && (t += " type " + N(n.type) + "\n"), n.label && (t += " label \"" + s(n.label) + "\"\n"), n.attribute && (t += " attribute " + N(n.attribute) + "\n"), n.attributes.length > 0 && (t += " attributes { " + n.attributes.map(N).join(" ") + " }\n"), n.dimension && (t += " dimension " + N(n.dimension) + "\n"), n.obligation && (t += " obligation " + n.obligation + "\n"), t += " }\n";
|
|
@@ -7804,16 +7919,16 @@ var As = (e, t) => {
|
|
|
7804
7919
|
};
|
|
7805
7920
|
//#endregion
|
|
7806
7921
|
//#region src/ser-des/config/artifact.ts
|
|
7807
|
-
function
|
|
7922
|
+
function Bs(e) {
|
|
7808
7923
|
return n(a(e)).map(P).map(a).filter((e) => e.length > 0);
|
|
7809
7924
|
}
|
|
7810
|
-
function
|
|
7925
|
+
function Vs(e, t, n) {
|
|
7811
7926
|
return t.length === 0 ? "" : `${n}${e} { ${t.join(" ")} }\n`;
|
|
7812
7927
|
}
|
|
7813
|
-
function
|
|
7928
|
+
function Hs(e) {
|
|
7814
7929
|
return n(a(e)).map(a).filter((e) => e.length > 0);
|
|
7815
7930
|
}
|
|
7816
|
-
function
|
|
7931
|
+
function Us(e) {
|
|
7817
7932
|
let t = [], r = n(e), i = 0;
|
|
7818
7933
|
for (; i < r.length;) {
|
|
7819
7934
|
let e = P(r[i++]);
|
|
@@ -7833,7 +7948,7 @@ function Fs(e) {
|
|
|
7833
7948
|
}
|
|
7834
7949
|
return t;
|
|
7835
7950
|
}
|
|
7836
|
-
function
|
|
7951
|
+
function Ws(e) {
|
|
7837
7952
|
let t = [], r = n(e), o = 0;
|
|
7838
7953
|
for (; o < r.length;) {
|
|
7839
7954
|
let e = P(r[o++]);
|
|
@@ -7848,14 +7963,14 @@ function Is(e) {
|
|
|
7848
7963
|
for (; t < e.length;) {
|
|
7849
7964
|
let n = e[t++];
|
|
7850
7965
|
if (t >= e.length) break;
|
|
7851
|
-
n === "kinds" ? s.kinds =
|
|
7966
|
+
n === "kinds" ? s.kinds = Bs(e[t++]) : n === "role" ? s.role = a(e[t++]) : i(e[t++]);
|
|
7852
7967
|
}
|
|
7853
7968
|
}
|
|
7854
7969
|
t.push(s);
|
|
7855
7970
|
}
|
|
7856
7971
|
return t;
|
|
7857
7972
|
}
|
|
7858
|
-
function
|
|
7973
|
+
function Gs(e) {
|
|
7859
7974
|
let t = {
|
|
7860
7975
|
fields: [],
|
|
7861
7976
|
structure: "",
|
|
@@ -7864,11 +7979,11 @@ function Ls(e) {
|
|
|
7864
7979
|
for (; o < r.length;) {
|
|
7865
7980
|
let e = r[o++];
|
|
7866
7981
|
if (o >= r.length) break;
|
|
7867
|
-
e === "fields" ? t.fields =
|
|
7982
|
+
e === "fields" ? t.fields = Us(i(r[o++])) : e === "structure" ? t.structure = a(r[o++]) : e === "media" ? t.media = Ws(i(r[o++])) : o = y(r, o, e);
|
|
7868
7983
|
}
|
|
7869
7984
|
return t;
|
|
7870
7985
|
}
|
|
7871
|
-
var
|
|
7986
|
+
var Ks = function(e, t) {
|
|
7872
7987
|
let n = {
|
|
7873
7988
|
id: e,
|
|
7874
7989
|
name: "",
|
|
@@ -7888,7 +8003,7 @@ var Rs = function(e, t) {
|
|
|
7888
8003
|
if (s >= o.length) break;
|
|
7889
8004
|
if (e === "name") n.name = a(o[s++]);
|
|
7890
8005
|
else if (e === "description") n.description = a(o[s++]);
|
|
7891
|
-
else if (e === "content_contract") n.contentContract =
|
|
8006
|
+
else if (e === "content_contract") n.contentContract = Gs(i(o[s++]));
|
|
7892
8007
|
else if (e === "produced_when") {
|
|
7893
8008
|
let e = a(o[s++] ?? "");
|
|
7894
8009
|
n.producedWhen = e === "per_interval" ? {
|
|
@@ -7902,7 +8017,7 @@ var Rs = function(e, t) {
|
|
|
7902
8017
|
else if (e === "source") {
|
|
7903
8018
|
let e = I(i(o[s++]));
|
|
7904
8019
|
(n.sourceRefs ??= []).push(e), n.source ||= e;
|
|
7905
|
-
} else if (e === "reference") n.referenceIds =
|
|
8020
|
+
} else if (e === "reference") n.referenceIds = Hs(o[s++]);
|
|
7906
8021
|
else if (e === "ref") {
|
|
7907
8022
|
let e = S(o, s, a, i);
|
|
7908
8023
|
T(n, e.ref) || (n.refs ??= []).push(e.ref), s = e.next;
|
|
@@ -7913,10 +8028,10 @@ var Rs = function(e, t) {
|
|
|
7913
8028
|
}
|
|
7914
8029
|
return (t) => (t.artifactDefinitions[e] = n, t);
|
|
7915
8030
|
};
|
|
7916
|
-
function
|
|
8031
|
+
function qs(e) {
|
|
7917
8032
|
return e.kind === "per_interval" ? `per_interval ${N(e.interval ?? "")}` : e.kind === "on_event" ? `on_event ${N(e.event ?? "")}` : e.kind;
|
|
7918
8033
|
}
|
|
7919
|
-
var
|
|
8034
|
+
var Js = function(e) {
|
|
7920
8035
|
let t = "artifact_definition " + e.id + " {\n";
|
|
7921
8036
|
e.name && (t += " name \"" + s(e.name) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n");
|
|
7922
8037
|
let n = e.contentContract;
|
|
@@ -7936,11 +8051,11 @@ var Bs = function(e) {
|
|
|
7936
8051
|
}
|
|
7937
8052
|
t += " }\n";
|
|
7938
8053
|
}
|
|
7939
|
-
e.producedWhen.kind && (t += " produced_when " +
|
|
8054
|
+
e.producedWhen.kind && (t += " produced_when " + qs(e.producedWhen) + "\n"), e.retention && (t += " retention \"" + s(e.retention) + "\"\n");
|
|
7940
8055
|
let r = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source ? [e.source] : [];
|
|
7941
8056
|
for (let e of r) t += E(e, " ", s);
|
|
7942
|
-
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t +=
|
|
7943
|
-
},
|
|
8057
|
+
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += Vs("reference", e.referenceIds, " "), t += "}\n", t;
|
|
8058
|
+
}, Ys = function(e, t) {
|
|
7944
8059
|
let n = {
|
|
7945
8060
|
id: e,
|
|
7946
8061
|
of: "",
|
|
@@ -7953,34 +8068,34 @@ var Bs = function(e) {
|
|
|
7953
8068
|
for (; s < o.length;) {
|
|
7954
8069
|
let e = o[s++];
|
|
7955
8070
|
if (s >= o.length) break;
|
|
7956
|
-
e === "of" ? n.of = a(o[s++]) : e === "produced_at" ? n.producedAt = a(o[s++]) : e === "by" ? n.by = a(o[s++]) : e === "content" ? n.content =
|
|
8071
|
+
e === "of" ? n.of = a(o[s++]) : e === "produced_at" ? n.producedAt = a(o[s++]) : e === "by" ? n.by = a(o[s++]) : e === "content" ? n.content = cs(i(o[s++])) : e === "links" ? n.links = Bs(o[s++]) : e === "reference" ? n.referenceIds = Hs(o[s++]) : s = y(o, s, e);
|
|
7957
8072
|
}
|
|
7958
8073
|
return (t) => (t.artifactInstances[e] = n, t);
|
|
7959
|
-
},
|
|
8074
|
+
}, Xs = function(e) {
|
|
7960
8075
|
let t = "artifact_instance " + e.id + " {\n";
|
|
7961
8076
|
e.of && (t += " of " + e.of + "\n"), e.producedAt && (t += " produced_at " + N(e.producedAt) + "\n"), e.by && (t += " by " + N(e.by) + "\n");
|
|
7962
8077
|
let n = Object.keys(e.content);
|
|
7963
|
-
return n.length > 0 && (t += " content { " + n.map((t) => t + " : " + be(e.content[t])).join(" ") + " }\n"), t +=
|
|
7964
|
-
},
|
|
8078
|
+
return n.length > 0 && (t += " content { " + n.map((t) => t + " : " + be(e.content[t])).join(" ") + " }\n"), t += Vs("links", e.links, " "), t += Vs("reference", e.referenceIds, " "), t += "}\n", t;
|
|
8079
|
+
}, Zs = {
|
|
7965
8080
|
keyword: "artifact_definition",
|
|
7966
8081
|
field: "artifactDefinitions",
|
|
7967
8082
|
takesID: !0,
|
|
7968
|
-
parse:
|
|
7969
|
-
dump:
|
|
7970
|
-
},
|
|
8083
|
+
parse: Ks,
|
|
8084
|
+
dump: Js
|
|
8085
|
+
}, Qs = {
|
|
7971
8086
|
keyword: "artifact_instance",
|
|
7972
8087
|
field: "artifactInstances",
|
|
7973
8088
|
takesID: !0,
|
|
7974
|
-
parse:
|
|
7975
|
-
dump:
|
|
7976
|
-
},
|
|
7977
|
-
function
|
|
8089
|
+
parse: Ys,
|
|
8090
|
+
dump: Xs
|
|
8091
|
+
}, $s = F;
|
|
8092
|
+
function ec(e, t) {
|
|
7978
8093
|
let n = e[t] ?? "";
|
|
7979
8094
|
if (n.startsWith("{")) return {
|
|
7980
8095
|
selector: {
|
|
7981
8096
|
kind: "refs",
|
|
7982
8097
|
expression: "",
|
|
7983
|
-
refs:
|
|
8098
|
+
refs: $s(n)
|
|
7984
8099
|
},
|
|
7985
8100
|
next: t + 1
|
|
7986
8101
|
};
|
|
@@ -8005,7 +8120,7 @@ function Ks(e, t) {
|
|
|
8005
8120
|
next: t + 1
|
|
8006
8121
|
};
|
|
8007
8122
|
}
|
|
8008
|
-
function
|
|
8123
|
+
function tc(e) {
|
|
8009
8124
|
let t = [], n = se(e), r = 0;
|
|
8010
8125
|
for (; r < n.length;) {
|
|
8011
8126
|
let e = n[r++];
|
|
@@ -8037,7 +8152,7 @@ function qs(e) {
|
|
|
8037
8152
|
}
|
|
8038
8153
|
return t;
|
|
8039
8154
|
}
|
|
8040
|
-
function
|
|
8155
|
+
function nc(e) {
|
|
8041
8156
|
let t = {
|
|
8042
8157
|
requirements: {
|
|
8043
8158
|
kind: "",
|
|
@@ -8053,13 +8168,13 @@ function Js(e) {
|
|
|
8053
8168
|
for (; r < n.length;) {
|
|
8054
8169
|
let e = n[r++];
|
|
8055
8170
|
if (e === "requirements" || e === "promises") {
|
|
8056
|
-
let i =
|
|
8171
|
+
let i = ec(n, r);
|
|
8057
8172
|
t[e] = i.selector, r = i.next;
|
|
8058
8173
|
}
|
|
8059
8174
|
}
|
|
8060
8175
|
return t;
|
|
8061
8176
|
}
|
|
8062
|
-
function
|
|
8177
|
+
function rc(e) {
|
|
8063
8178
|
let t = [], n = se(e), r = 0;
|
|
8064
8179
|
for (; r < n.length;) {
|
|
8065
8180
|
let e = n[r++];
|
|
@@ -8073,7 +8188,7 @@ function Ys(e) {
|
|
|
8073
8188
|
}
|
|
8074
8189
|
return t;
|
|
8075
8190
|
}
|
|
8076
|
-
function
|
|
8191
|
+
function ic(e) {
|
|
8077
8192
|
let t = [], n = se(e), r = 0;
|
|
8078
8193
|
for (; r < n.length;) {
|
|
8079
8194
|
let e = n[r++];
|
|
@@ -8087,7 +8202,7 @@ function Xs(e) {
|
|
|
8087
8202
|
}
|
|
8088
8203
|
return t;
|
|
8089
8204
|
}
|
|
8090
|
-
function
|
|
8205
|
+
function ac(e) {
|
|
8091
8206
|
let t = [], n = r(e), o = 0;
|
|
8092
8207
|
for (; o < n.length;) {
|
|
8093
8208
|
if (n[o++] !== "on") continue;
|
|
@@ -8095,7 +8210,7 @@ function Zs(e) {
|
|
|
8095
8210
|
if (o < n.length && n[o].startsWith("{")) {
|
|
8096
8211
|
t.push({
|
|
8097
8212
|
outcome: e,
|
|
8098
|
-
actions:
|
|
8213
|
+
actions: ic(i(n[o++]))
|
|
8099
8214
|
});
|
|
8100
8215
|
continue;
|
|
8101
8216
|
}
|
|
@@ -8117,7 +8232,7 @@ function Zs(e) {
|
|
|
8117
8232
|
}
|
|
8118
8233
|
return t;
|
|
8119
8234
|
}
|
|
8120
|
-
var
|
|
8235
|
+
var oc = function(e, t) {
|
|
8121
8236
|
let n = {
|
|
8122
8237
|
id: e,
|
|
8123
8238
|
over: [],
|
|
@@ -8139,12 +8254,12 @@ var Qs = function(e, t) {
|
|
|
8139
8254
|
referenceIds: []
|
|
8140
8255
|
};
|
|
8141
8256
|
return v(t, (e, t) => {
|
|
8142
|
-
if (e === "over") n.over =
|
|
8143
|
-
else if (e === "triggers") n.triggers =
|
|
8144
|
-
else if (e === "evaluate") n.evaluate =
|
|
8145
|
-
else if (e === "emit") n.emit =
|
|
8146
|
-
else if (e === "escalate") n.escalate =
|
|
8147
|
-
else if (e === "reference") n.referenceIds =
|
|
8257
|
+
if (e === "over") n.over = $s(t());
|
|
8258
|
+
else if (e === "triggers") n.triggers = tc(i(t()));
|
|
8259
|
+
else if (e === "evaluate") n.evaluate = nc(i(t()));
|
|
8260
|
+
else if (e === "emit") n.emit = rc(i(t()));
|
|
8261
|
+
else if (e === "escalate") n.escalate = ac(i(t()));
|
|
8262
|
+
else if (e === "reference") n.referenceIds = $s(t());
|
|
8148
8263
|
else return !1;
|
|
8149
8264
|
return !0;
|
|
8150
8265
|
}, {
|
|
@@ -8152,46 +8267,46 @@ var Qs = function(e, t) {
|
|
|
8152
8267
|
id: e
|
|
8153
8268
|
}), (t) => (t.monitors[e] = n, t);
|
|
8154
8269
|
};
|
|
8155
|
-
function
|
|
8270
|
+
function sc(e) {
|
|
8156
8271
|
return e.kind === "timer" ? "every " + N(e.every) : e.kind === "signal" ? "on signal " + N(e.signal) : e.kind === "change" ? "on change " + N(e.aspect) : "on " + N(e.kind);
|
|
8157
8272
|
}
|
|
8158
|
-
function
|
|
8273
|
+
function cc(e) {
|
|
8159
8274
|
return e.kind === "applicable_to" ? "applicable_to(" + e.expression + ")" : e.kind === "refs" ? "{ " + e.refs.map(N).join(" ") + " }" : N(e.kind);
|
|
8160
8275
|
}
|
|
8161
|
-
function
|
|
8276
|
+
function lc(e) {
|
|
8162
8277
|
let t = e.actions.map((e) => e.action === "notify" ? "notify " + N(e.role) : N(e.action)).join(" ");
|
|
8163
8278
|
return "on " + N(e.outcome) + " { " + t + " }";
|
|
8164
8279
|
}
|
|
8165
|
-
var
|
|
8280
|
+
var uc = {
|
|
8166
8281
|
keyword: "monitor",
|
|
8167
8282
|
field: "monitors",
|
|
8168
8283
|
takesID: !0,
|
|
8169
|
-
parse:
|
|
8284
|
+
parse: oc,
|
|
8170
8285
|
dump: function(e) {
|
|
8171
8286
|
let t = "monitor " + e.id + " {\n";
|
|
8172
|
-
e.over.length > 0 && (t += " over { " + e.over.map(N).join(" ") + " }\n"), e.triggers.length > 0 && (t += " triggers { " + e.triggers.map(
|
|
8287
|
+
e.over.length > 0 && (t += " over { " + e.over.map(N).join(" ") + " }\n"), e.triggers.length > 0 && (t += " triggers { " + e.triggers.map(sc).join(" ") + " }\n");
|
|
8173
8288
|
let n = e.evaluate.requirements, r = e.evaluate.promises;
|
|
8174
|
-
return (n.kind || r.kind) && (t += " evaluate {", n.kind && (t += " requirements " +
|
|
8289
|
+
return (n.kind || r.kind) && (t += " evaluate {", n.kind && (t += " requirements " + cc(n)), r.kind && (t += " promises " + cc(r)), t += " }\n"), e.emit.length > 0 && (t += " emit { " + e.emit.map((e) => e.stream + " -> " + N(e.target)).join(" ") + " }\n"), e.escalate.length > 0 && (t += " escalate { " + e.escalate.map(lc).join(" ") + " }\n"), e.referenceIds.length > 0 && (t += " reference { " + e.referenceIds.map(N).join(" ") + " }\n"), t += "}\n", t;
|
|
8175
8290
|
}
|
|
8176
|
-
},
|
|
8291
|
+
}, dc = [
|
|
8177
8292
|
"identity",
|
|
8178
8293
|
"composition",
|
|
8179
8294
|
"promises_as_verified",
|
|
8180
8295
|
"live_compliance_status",
|
|
8181
8296
|
"artifacts",
|
|
8182
8297
|
"sustainability"
|
|
8183
|
-
],
|
|
8298
|
+
], fc = [
|
|
8184
8299
|
"public",
|
|
8185
8300
|
"restricted",
|
|
8186
8301
|
"authority"
|
|
8187
|
-
],
|
|
8302
|
+
], pc = [
|
|
8188
8303
|
"model",
|
|
8189
8304
|
"batch",
|
|
8190
8305
|
"item"
|
|
8191
8306
|
];
|
|
8192
8307
|
//#endregion
|
|
8193
8308
|
//#region src/ser-des/config/passport.ts
|
|
8194
|
-
function
|
|
8309
|
+
function mc(e, t) {
|
|
8195
8310
|
return F(t).map((t) => {
|
|
8196
8311
|
let n = t.indexOf(".");
|
|
8197
8312
|
return n === -1 ? {
|
|
@@ -8205,7 +8320,7 @@ function oc(e, t) {
|
|
|
8205
8320
|
};
|
|
8206
8321
|
});
|
|
8207
8322
|
}
|
|
8208
|
-
var
|
|
8323
|
+
var hc = function(e, t) {
|
|
8209
8324
|
let n = {
|
|
8210
8325
|
id: e,
|
|
8211
8326
|
upi: {
|
|
@@ -8244,8 +8359,8 @@ var sc = function(e, t) {
|
|
|
8244
8359
|
} else if (t === "reference") n.referenceIds = F(r());
|
|
8245
8360
|
else {
|
|
8246
8361
|
let i = r();
|
|
8247
|
-
if (
|
|
8248
|
-
else if (i.startsWith("{")) throw Error(`Parsing error: passport. ID ${e}: unknown access class "${t}" — access classes are ${
|
|
8362
|
+
if (fc.includes(t)) n.entries.push(...mc(t, i));
|
|
8363
|
+
else if (i.startsWith("{")) throw Error(`Parsing error: passport. ID ${e}: unknown access class "${t}" — access classes are ${fc.join(" | ")} (fail-closed: an unknown access class is never served)`);
|
|
8249
8364
|
}
|
|
8250
8365
|
return !0;
|
|
8251
8366
|
}, {
|
|
@@ -8253,26 +8368,26 @@ var sc = function(e, t) {
|
|
|
8253
8368
|
id: e
|
|
8254
8369
|
}), (t) => (t.passports[e] = n, t);
|
|
8255
8370
|
};
|
|
8256
|
-
function
|
|
8371
|
+
function gc(e) {
|
|
8257
8372
|
return N(e.ref === "" ? e.contentClass : e.contentClass + "." + e.ref);
|
|
8258
8373
|
}
|
|
8259
|
-
var
|
|
8374
|
+
var _c = {
|
|
8260
8375
|
keyword: "passport",
|
|
8261
8376
|
field: "passports",
|
|
8262
8377
|
takesID: !0,
|
|
8263
|
-
parse:
|
|
8378
|
+
parse: hc,
|
|
8264
8379
|
dump: function(e) {
|
|
8265
8380
|
let t = "passport " + e.id + " {\n";
|
|
8266
8381
|
(e.upi.pattern !== "" || e.upi.level !== "") && (t += " upi {", e.upi.pattern !== "" && (t += " pattern " + N(e.upi.pattern)), e.upi.level !== "" && (t += " level " + N(e.upi.level)), t += " }\n");
|
|
8267
8382
|
for (let n of e.carriers) t += " carrier { kind " + N(n.kind) + " payload " + N(n.payload) + " }\n";
|
|
8268
|
-
let n = [...
|
|
8383
|
+
let n = [...fc, ...[...new Set(e.entries.map((e) => e.access))].filter((e) => !fc.includes(e))];
|
|
8269
8384
|
for (let r of n) {
|
|
8270
8385
|
let n = e.entries.filter((e) => e.access === r);
|
|
8271
|
-
n.length > 0 && (t += " " + r + " { " + n.map(
|
|
8386
|
+
n.length > 0 && (t += " " + r + " { " + n.map(gc).join(" ") + " }\n");
|
|
8272
8387
|
}
|
|
8273
8388
|
return e.referenceIds.length > 0 && (t += " reference { " + e.referenceIds.map(N).join(" ") + " }\n"), t += "}\n", t;
|
|
8274
8389
|
}
|
|
8275
|
-
},
|
|
8390
|
+
}, vc = {
|
|
8276
8391
|
keyword: "invariant",
|
|
8277
8392
|
field: "invariants",
|
|
8278
8393
|
takesID: !0,
|
|
@@ -8312,7 +8427,7 @@ var lc = {
|
|
|
8312
8427
|
};
|
|
8313
8428
|
//#endregion
|
|
8314
8429
|
//#region src/ser-des/config/testSequence.ts
|
|
8315
|
-
function
|
|
8430
|
+
function yc(e, t, n) {
|
|
8316
8431
|
v(e, (e, n) => {
|
|
8317
8432
|
if (e === "test") t.test = a(n());
|
|
8318
8433
|
else if (e === "phase") t.phase = a(n());
|
|
@@ -8325,7 +8440,7 @@ function dc(e, t, n) {
|
|
|
8325
8440
|
id: n
|
|
8326
8441
|
});
|
|
8327
8442
|
}
|
|
8328
|
-
var
|
|
8443
|
+
var bc = {
|
|
8329
8444
|
keyword: "test_sequence",
|
|
8330
8445
|
field: "testSequences",
|
|
8331
8446
|
takesID: !0,
|
|
@@ -8359,7 +8474,7 @@ var fc = {
|
|
|
8359
8474
|
role: "",
|
|
8360
8475
|
dependsOn: null
|
|
8361
8476
|
}, r = o[s++];
|
|
8362
|
-
r.startsWith("{") || (t.order = Number(a(r)), r = s < o.length && o[s].startsWith("{") ? o[s++] : ""), r.startsWith("{") &&
|
|
8477
|
+
r.startsWith("{") || (t.order = Number(a(r)), r = s < o.length && o[s].startsWith("{") ? o[s++] : ""), r.startsWith("{") && yc(i(r), t, e), n.steps.push(t);
|
|
8363
8478
|
} else s++;
|
|
8364
8479
|
}
|
|
8365
8480
|
return (t) => (t.testSequences[e] = n, t);
|
|
@@ -8373,7 +8488,7 @@ var fc = {
|
|
|
8373
8488
|
for (let n of e.sourceRefs) t += E(n, " ", s);
|
|
8374
8489
|
return t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
8375
8490
|
}
|
|
8376
|
-
},
|
|
8491
|
+
}, xc = {
|
|
8377
8492
|
keyword: "formulas_used",
|
|
8378
8493
|
field: "formulasUsed",
|
|
8379
8494
|
takesID: !0,
|
|
@@ -8408,7 +8523,7 @@ var fc = {
|
|
|
8408
8523
|
for (let n of e.sourceRefs) t += E(n, " ", s);
|
|
8409
8524
|
return t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
8410
8525
|
}
|
|
8411
|
-
},
|
|
8526
|
+
}, Sc = function(e, t) {
|
|
8412
8527
|
let n = {
|
|
8413
8528
|
id: e,
|
|
8414
8529
|
entries: []
|
|
@@ -8437,14 +8552,14 @@ var fc = {
|
|
|
8437
8552
|
let r = t.texts[e];
|
|
8438
8553
|
return r ? r.entries.push(...n.entries) : t.texts[e] = n, t;
|
|
8439
8554
|
};
|
|
8440
|
-
},
|
|
8555
|
+
}, Cc = function(e) {
|
|
8441
8556
|
let t = "text " + e.id + " {\n";
|
|
8442
8557
|
for (let n of e.entries) t += " spell " + n.spelling + (n.via ? " via " + n.via : "") + " \"" + s(n.value) + "\"\n";
|
|
8443
8558
|
return t += "}\n", t;
|
|
8444
8559
|
};
|
|
8445
8560
|
//#endregion
|
|
8446
8561
|
//#region src/ser-des/config/quantityRegister.ts
|
|
8447
|
-
function
|
|
8562
|
+
function wc(e) {
|
|
8448
8563
|
let t = {}, r = n(e);
|
|
8449
8564
|
for (let e = 0; e + 1 < r.length; e += 2) {
|
|
8450
8565
|
let n = P(r[e]), i = Number(r[e + 1]);
|
|
@@ -8452,11 +8567,11 @@ function gc(e) {
|
|
|
8452
8567
|
}
|
|
8453
8568
|
return t;
|
|
8454
8569
|
}
|
|
8455
|
-
function
|
|
8570
|
+
function Tc(e, t) {
|
|
8456
8571
|
let n = Number(a(e));
|
|
8457
8572
|
return Number.isNaN(n) ? t : n;
|
|
8458
8573
|
}
|
|
8459
|
-
function
|
|
8574
|
+
function Ec(e, t) {
|
|
8460
8575
|
let r = {
|
|
8461
8576
|
id: e,
|
|
8462
8577
|
dimensions: {},
|
|
@@ -8466,7 +8581,7 @@ function vc(e, t) {
|
|
|
8466
8581
|
for (; s < o.length;) {
|
|
8467
8582
|
let e = o[s++];
|
|
8468
8583
|
if (s >= o.length) break;
|
|
8469
|
-
if (e === "dimensions") r.dimensions =
|
|
8584
|
+
if (e === "dimensions") r.dimensions = wc(i(o[s++]));
|
|
8470
8585
|
else if (e === "si_unit") r.siUnit = a(o[s++]);
|
|
8471
8586
|
else if (e === "description") r.description = a(o[s++]);
|
|
8472
8587
|
else if (e === "corresponds") {
|
|
@@ -8476,7 +8591,7 @@ function vc(e, t) {
|
|
|
8476
8591
|
}
|
|
8477
8592
|
return r;
|
|
8478
8593
|
}
|
|
8479
|
-
function
|
|
8594
|
+
function Dc(e, t) {
|
|
8480
8595
|
let r = {
|
|
8481
8596
|
id: e,
|
|
8482
8597
|
symbol: "",
|
|
@@ -8492,8 +8607,8 @@ function yc(e, t) {
|
|
|
8492
8607
|
if (e === "symbol") r.symbol = a(o[s++]);
|
|
8493
8608
|
else if (e === "label") r.label = a(o[s++]);
|
|
8494
8609
|
else if (e === "kind") r.kind = a(o[s++]);
|
|
8495
|
-
else if (e === "factor") r.factorToSI =
|
|
8496
|
-
else if (e === "offset") r.offsetToSI =
|
|
8610
|
+
else if (e === "factor") r.factorToSI = Tc(o[s++], 1);
|
|
8611
|
+
else if (e === "offset") r.offsetToSI = Tc(o[s++], 0);
|
|
8497
8612
|
else if (e === "definition") r.definition = a(o[s++]);
|
|
8498
8613
|
else if (e === "corresponds") {
|
|
8499
8614
|
let { corr: e, next: t } = D(o, s, a);
|
|
@@ -8502,7 +8617,7 @@ function yc(e, t) {
|
|
|
8502
8617
|
}
|
|
8503
8618
|
return r;
|
|
8504
8619
|
}
|
|
8505
|
-
var
|
|
8620
|
+
var Oc = function(e, t) {
|
|
8506
8621
|
let o = {
|
|
8507
8622
|
id: e,
|
|
8508
8623
|
kinds: [],
|
|
@@ -8512,11 +8627,11 @@ var bc = function(e, t) {
|
|
|
8512
8627
|
for (; c < s.length;) {
|
|
8513
8628
|
let e = s[c++];
|
|
8514
8629
|
if (c >= s.length) break;
|
|
8515
|
-
e === "kind" ? o.kinds.push(
|
|
8630
|
+
e === "kind" ? o.kinds.push(Ec(P(s[c++]), i(s[c++]))) : e === "unit" ? o.units.push(Dc(P(s[c++]), i(s[c++]))) : e === "reference" ? o.referenceIds = n(a(s[c++])).map(a).filter((e) => e.length > 0) : i(s[c++]);
|
|
8516
8631
|
}
|
|
8517
8632
|
return (t) => (t.quantityRegisters[e] = o, t);
|
|
8518
8633
|
};
|
|
8519
|
-
function
|
|
8634
|
+
function kc(e) {
|
|
8520
8635
|
let t = "";
|
|
8521
8636
|
for (let n of e ?? []) if (t += " corresponds " + N(n.scheme) + " \"" + s(n.concept) + "\"", n.projections.length > 0) {
|
|
8522
8637
|
t += " {";
|
|
@@ -8529,28 +8644,28 @@ function xc(e) {
|
|
|
8529
8644
|
}
|
|
8530
8645
|
return t;
|
|
8531
8646
|
}
|
|
8532
|
-
function
|
|
8647
|
+
function Ac(e) {
|
|
8533
8648
|
let t = Object.keys(e);
|
|
8534
8649
|
return t.length === 0 ? "" : " dimensions { " + t.map((t) => t + " " + e[t]).join(" ") + " }";
|
|
8535
8650
|
}
|
|
8536
|
-
var
|
|
8651
|
+
var jc = {
|
|
8537
8652
|
keyword: "quantity_register",
|
|
8538
8653
|
field: "quantityRegisters",
|
|
8539
8654
|
takesID: !0,
|
|
8540
|
-
parse:
|
|
8655
|
+
parse: Oc,
|
|
8541
8656
|
dump: function(e) {
|
|
8542
8657
|
let t = "quantity_register " + e.id + " {\n";
|
|
8543
8658
|
for (let n of e.kinds) {
|
|
8544
|
-
let e = " kind " + n.id + " {" +
|
|
8545
|
-
n.siUnit && (e += " si_unit \"" + s(n.siUnit) + "\""), n.description && (e += " description \"" + s(n.description) + "\""), e +=
|
|
8659
|
+
let e = " kind " + n.id + " {" + Ac(n.dimensions);
|
|
8660
|
+
n.siUnit && (e += " si_unit \"" + s(n.siUnit) + "\""), n.description && (e += " description \"" + s(n.description) + "\""), e += kc(n.correspondences), t += e + " }\n";
|
|
8546
8661
|
}
|
|
8547
8662
|
for (let n of e.units) {
|
|
8548
8663
|
let e = " unit " + N(n.id) + " {";
|
|
8549
|
-
n.symbol && (e += " symbol \"" + s(n.symbol) + "\""), n.label && (e += " label \"" + s(n.label) + "\""), n.kind && (e += " kind " + n.kind), n.factorToSI !== 1 && (e += " factor " + n.factorToSI), n.offsetToSI !== 0 && (e += " offset " + n.offsetToSI), n.definition && (e += " definition \"" + s(n.definition) + "\""), e +=
|
|
8664
|
+
n.symbol && (e += " symbol \"" + s(n.symbol) + "\""), n.label && (e += " label \"" + s(n.label) + "\""), n.kind && (e += " kind " + n.kind), n.factorToSI !== 1 && (e += " factor " + n.factorToSI), n.offsetToSI !== 0 && (e += " offset " + n.offsetToSI), n.definition && (e += " definition \"" + s(n.definition) + "\""), e += kc(n.correspondences), t += e + " }\n";
|
|
8550
8665
|
}
|
|
8551
8666
|
return e.referenceIds.length > 0 && (t += " reference { " + e.referenceIds.join(" ") + " }\n"), t += "}\n", t;
|
|
8552
8667
|
}
|
|
8553
|
-
},
|
|
8668
|
+
}, Mc = {
|
|
8554
8669
|
keyword: "dual",
|
|
8555
8670
|
field: "duals",
|
|
8556
8671
|
takesID: !0,
|
|
@@ -8574,18 +8689,18 @@ var Cc = {
|
|
|
8574
8689
|
};
|
|
8575
8690
|
//#endregion
|
|
8576
8691
|
//#region src/ser-des/config/trustRef.ts
|
|
8577
|
-
function
|
|
8692
|
+
function Nc(e, t, n) {
|
|
8578
8693
|
let r = {
|
|
8579
8694
|
org: n(e()),
|
|
8580
8695
|
kid: ""
|
|
8581
8696
|
};
|
|
8582
8697
|
return t() === "key" && (e(), r.kid = n(e())), r;
|
|
8583
8698
|
}
|
|
8584
|
-
function
|
|
8699
|
+
function Pc(e, t, n) {
|
|
8585
8700
|
let r = `${t}trust_ref ${n(e.org)}`;
|
|
8586
8701
|
return e.kid !== "" && (r += ` key ${n(e.kid)}`), r + "\n";
|
|
8587
8702
|
}
|
|
8588
|
-
var
|
|
8703
|
+
var Fc = {
|
|
8589
8704
|
keyword: "dataspace",
|
|
8590
8705
|
field: "dataspaces",
|
|
8591
8706
|
takesID: !0,
|
|
@@ -8650,7 +8765,7 @@ var Dc = {
|
|
|
8650
8765
|
description: ""
|
|
8651
8766
|
}, o = r();
|
|
8652
8767
|
o && o.startsWith("{") && v(i(t()), (t, n, r) => {
|
|
8653
|
-
if (t === "trust_ref") e.trustRef =
|
|
8768
|
+
if (t === "trust_ref") e.trustRef = Nc(n, r, a);
|
|
8654
8769
|
else if (t === "role") e.role = a(n());
|
|
8655
8770
|
else if (t === "description") e.description = x(n);
|
|
8656
8771
|
else return !1;
|
|
@@ -8680,17 +8795,17 @@ var Dc = {
|
|
|
8680
8795
|
for (let n of e.participantClasses) t += " participant_class " + N(n.id) + " {\n", n.label && (t += " label \"" + s(n.label) + "\"\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), t += " }\n";
|
|
8681
8796
|
for (let n of e.artifactClasses) t += " artifact_class " + N(n.id) + " {\n", n.label && (t += " label \"" + s(n.label) + "\"\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), n.element && (t += " element " + N(n.element) + "\n"), n.policy && (t += " policy " + N(n.policy) + "\n"), t += " }\n";
|
|
8682
8797
|
e.policies.length > 0 && (t += " policies { " + e.policies.map(N).join(" ") + " }\n"), e.defaultPolicy && (t += " default_policy " + N(e.defaultPolicy) + "\n");
|
|
8683
|
-
for (let n of e.trustAnchors) t += " trust_anchor " + N(n.id) + " {\n", n.trustRef && (t +=
|
|
8798
|
+
for (let n of e.trustAnchors) t += " trust_anchor " + N(n.id) + " {\n", n.trustRef && (t += Pc(n.trustRef, " ", N)), n.role && (t += " role " + N(n.role) + "\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), t += " }\n";
|
|
8684
8799
|
e.compatibleWith.length > 0 && (t += " compatible_with { " + e.compatibleWith.map(N).join(" ") + " }\n");
|
|
8685
8800
|
let n = e.sourceRefs && e.sourceRefs.length > 0 ? e.sourceRefs : e.source ? [e.source] : [];
|
|
8686
8801
|
for (let e of n) t += E(e, " ", s);
|
|
8687
8802
|
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
8688
8803
|
}
|
|
8689
|
-
},
|
|
8804
|
+
}, Ic = [
|
|
8690
8805
|
"permission",
|
|
8691
8806
|
"obligation",
|
|
8692
8807
|
"prohibition"
|
|
8693
|
-
],
|
|
8808
|
+
], Lc = {
|
|
8694
8809
|
keyword: "policy",
|
|
8695
8810
|
field: "policies",
|
|
8696
8811
|
takesID: !0,
|
|
@@ -8724,7 +8839,7 @@ var Dc = {
|
|
|
8724
8839
|
t && t.startsWith("{") && v(i(r()), (t, n) => {
|
|
8725
8840
|
if (t === "kind") {
|
|
8726
8841
|
let t = a(n());
|
|
8727
|
-
if (!
|
|
8842
|
+
if (!Ic.includes(t)) throw Error(`Parsing error: policy.rule. ID ${e.id}: unknown rule kind "${t}" — rule kinds are ${Ic.join(" | ")} (fail-closed: a misspelt kind never parses into a rule that says nothing)`);
|
|
8728
8843
|
e.kind = t;
|
|
8729
8844
|
} else if (t === "action") e.action = a(n());
|
|
8730
8845
|
else if (t === "artifact") e.artifact = a(n());
|
|
@@ -8761,18 +8876,18 @@ var Dc = {
|
|
|
8761
8876
|
for (let e of n) t += E(e, " ", s);
|
|
8762
8877
|
return t += w(e.refs, " ", s), t += k(e.correspondences, " ", s, N), t += "}\n", t;
|
|
8763
8878
|
}
|
|
8764
|
-
},
|
|
8879
|
+
}, Rc = {
|
|
8765
8880
|
keyword: "dimension",
|
|
8766
8881
|
field: "dimensions",
|
|
8767
8882
|
takesID: !0,
|
|
8768
8883
|
parse: function(e, t) {
|
|
8769
|
-
let n =
|
|
8884
|
+
let n = io(e, i(t));
|
|
8770
8885
|
return (t) => (t.dimensions[e] = n, t);
|
|
8771
8886
|
},
|
|
8772
8887
|
dump: function(e) {
|
|
8773
|
-
return
|
|
8888
|
+
return oo(e, "");
|
|
8774
8889
|
}
|
|
8775
|
-
},
|
|
8890
|
+
}, zc = (e, t) => {
|
|
8776
8891
|
let n = {
|
|
8777
8892
|
id: e,
|
|
8778
8893
|
label: "",
|
|
@@ -8791,13 +8906,13 @@ var Dc = {
|
|
|
8791
8906
|
construct: "activity_archetype",
|
|
8792
8907
|
id: e
|
|
8793
8908
|
}), (t) => (t.activityArchetypes[e] = n, t);
|
|
8794
|
-
},
|
|
8909
|
+
}, Bc = function(e) {
|
|
8795
8910
|
let t = "activity_archetype " + e.id + " {\n";
|
|
8796
8911
|
return e.label && (t += " label \"" + s(e.label) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.parent && (t += " parent " + N(e.parent) + "\n"), t += "}\n", t;
|
|
8797
8912
|
};
|
|
8798
8913
|
//#endregion
|
|
8799
8914
|
//#region src/ser-des/config/participantKind.ts
|
|
8800
|
-
function
|
|
8915
|
+
function Vc(e) {
|
|
8801
8916
|
let t = {
|
|
8802
8917
|
delegates_to: "",
|
|
8803
8918
|
clause: "",
|
|
@@ -8814,7 +8929,7 @@ function Nc(e) {
|
|
|
8814
8929
|
id: ""
|
|
8815
8930
|
}), t;
|
|
8816
8931
|
}
|
|
8817
|
-
function
|
|
8932
|
+
function Hc(e) {
|
|
8818
8933
|
let t = {
|
|
8819
8934
|
decided_by: "",
|
|
8820
8935
|
on_recommendation_of: "",
|
|
@@ -8833,7 +8948,7 @@ function Pc(e) {
|
|
|
8833
8948
|
id: ""
|
|
8834
8949
|
}), t;
|
|
8835
8950
|
}
|
|
8836
|
-
function
|
|
8951
|
+
function Uc(e, t) {
|
|
8837
8952
|
let n = {
|
|
8838
8953
|
id: e,
|
|
8839
8954
|
label: "",
|
|
@@ -8857,7 +8972,7 @@ function Fc(e, t) {
|
|
|
8857
8972
|
id: e
|
|
8858
8973
|
}), n;
|
|
8859
8974
|
}
|
|
8860
|
-
var
|
|
8975
|
+
var Wc = (e, t) => {
|
|
8861
8976
|
let n = {
|
|
8862
8977
|
id: e,
|
|
8863
8978
|
label: "",
|
|
@@ -8885,8 +9000,8 @@ var Ic = (e, t) => {
|
|
|
8885
9000
|
else if (t === "clause") n.clause = a(r());
|
|
8886
9001
|
else if (t === "definition") n.definition = a(r());
|
|
8887
9002
|
else if (t === "member") n.member = a(r());
|
|
8888
|
-
else if (t === "competence") n.competence =
|
|
8889
|
-
else if (t === "approval") n.approval =
|
|
9003
|
+
else if (t === "competence") n.competence = Vc(i(r()));
|
|
9004
|
+
else if (t === "approval") n.approval = Hc(i(r()));
|
|
8890
9005
|
else if (t === "approved_by") n.approved_by = a(r());
|
|
8891
9006
|
else if (t === "designated_by") n.designated_by = a(r());
|
|
8892
9007
|
else if (t === "declaration") n.declaration = a(r());
|
|
@@ -8896,7 +9011,7 @@ var Ic = (e, t) => {
|
|
|
8896
9011
|
else if (t === "subkind") {
|
|
8897
9012
|
let t = a(r()), s = o();
|
|
8898
9013
|
if (s === void 0 || !s.startsWith("{")) throw Error(`Parsing error: participant_kind. ID ${e}: subkind ${t} is missing its block`);
|
|
8899
|
-
n.subkinds.push(
|
|
9014
|
+
n.subkinds.push(Uc(t, i(r())));
|
|
8900
9015
|
} else if (t === "source") n.source = I(i(r()));
|
|
8901
9016
|
else return !1;
|
|
8902
9017
|
return !0;
|
|
@@ -8905,24 +9020,24 @@ var Ic = (e, t) => {
|
|
|
8905
9020
|
id: e
|
|
8906
9021
|
}), (t) => (t.participantKinds[e] = n, t);
|
|
8907
9022
|
};
|
|
8908
|
-
function
|
|
9023
|
+
function Gc(e) {
|
|
8909
9024
|
let t = " competence {\n";
|
|
8910
9025
|
return e.delegates_to && (t += " delegates_to " + N(e.delegates_to) + "\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.note && (t += " note \"" + s(e.note) + "\"\n"), t += " }\n", t;
|
|
8911
9026
|
}
|
|
8912
|
-
function
|
|
9027
|
+
function Kc(e) {
|
|
8913
9028
|
let t = " approval {\n";
|
|
8914
9029
|
return e.decided_by && (t += " decided_by " + N(e.decided_by) + "\n"), e.on_recommendation_of && (t += " on_recommendation_of " + N(e.on_recommendation_of) + "\n"), e.procedure && (t += " procedure \"" + s(e.procedure) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), t += " }\n", t;
|
|
8915
9030
|
}
|
|
8916
|
-
function
|
|
9031
|
+
function qc(e) {
|
|
8917
9032
|
let t = " subkind " + N(e.id) + " {\n";
|
|
8918
9033
|
return e.label && (t += " label \"" + s(e.label) + "\"\n"), e.term && (t += " term \"" + s(e.term) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.data_flag && (t += " data_flag \"" + s(e.data_flag) + "\"\n"), e.acceptance && (t += " acceptance " + N(e.acceptance) + "\n"), e.acceptance_note && (t += " acceptance_note \"" + s(e.acceptance_note) + "\"\n"), t += " }\n", t;
|
|
8919
9034
|
}
|
|
8920
|
-
var
|
|
9035
|
+
var Jc = function(e) {
|
|
8921
9036
|
let t = "participant_kind " + e.id + " {\n";
|
|
8922
|
-
e.label && (t += " label \"" + s(e.label) + "\"\n"), e.term && (t += " term \"" + s(e.term) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.member && (t += " member " + N(e.member) + "\n"), e.competence && (t +=
|
|
8923
|
-
for (let n of e.subkinds) t +=
|
|
9037
|
+
e.label && (t += " label \"" + s(e.label) + "\"\n"), e.term && (t += " term \"" + s(e.term) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.member && (t += " member " + N(e.member) + "\n"), e.competence && (t += Gc(e.competence)), e.approval && (t += Kc(e.approval)), e.approved_by && (t += " approved_by " + N(e.approved_by) + "\n"), e.designated_by && (t += " designated_by " + N(e.designated_by) + "\n"), e.declaration && (t += " declaration " + N(e.declaration) + "\n"), e.admission && (t += " admission \"" + s(e.admission) + "\"\n"), e.becomes && (t += " becomes " + N(e.becomes) + "\n"), e.procedure && (t += " procedure \"" + s(e.procedure) + "\"\n");
|
|
9038
|
+
for (let n of e.subkinds) t += qc(n);
|
|
8924
9039
|
return (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
8925
|
-
},
|
|
9040
|
+
}, Yc = (e, t) => {
|
|
8926
9041
|
let n = {
|
|
8927
9042
|
id: e,
|
|
8928
9043
|
label: "",
|
|
@@ -8950,13 +9065,13 @@ var Bc = function(e) {
|
|
|
8950
9065
|
construct: "governance_organ",
|
|
8951
9066
|
id: e
|
|
8952
9067
|
}), (t) => (t.governanceOrgans[e] = n, t);
|
|
8953
|
-
},
|
|
9068
|
+
}, Xc = function(e) {
|
|
8954
9069
|
let t = "governance_organ " + e.id + " {\n";
|
|
8955
9070
|
return e.label && (t += " label \"" + s(e.label) + "\"\n"), e.term && (t += " term \"" + s(e.term) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.mandate && (t += " mandate \"" + s(e.mandate) + "\"\n"), e.sub_committee_of && (t += " sub_committee_of " + N(e.sub_committee_of) + "\n"), e.independent_of && (t += " independent_of " + N(e.independent_of) + "\n"), (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
8956
9071
|
};
|
|
8957
9072
|
//#endregion
|
|
8958
9073
|
//#region src/ser-des/config/declaration.ts
|
|
8959
|
-
function
|
|
9074
|
+
function Zc(e, t) {
|
|
8960
9075
|
let n = {
|
|
8961
9076
|
id: e,
|
|
8962
9077
|
clause: "",
|
|
@@ -8972,7 +9087,7 @@ function Uc(e, t) {
|
|
|
8972
9087
|
id: e
|
|
8973
9088
|
}), n;
|
|
8974
9089
|
}
|
|
8975
|
-
var
|
|
9090
|
+
var Qc = (e, t) => {
|
|
8976
9091
|
let n = {
|
|
8977
9092
|
id: e,
|
|
8978
9093
|
label: "",
|
|
@@ -8999,7 +9114,7 @@ var Wc = (e, t) => {
|
|
|
8999
9114
|
else if (t === "content") {
|
|
9000
9115
|
let t = a(r()), s = o();
|
|
9001
9116
|
if (s === void 0 || !s.startsWith("{")) throw Error(`Parsing error: declaration_kind. ID ${e}: content ${t} is missing its block`);
|
|
9002
|
-
n.content.push(
|
|
9117
|
+
n.content.push(Zc(t, i(r())));
|
|
9003
9118
|
} else if (t === "source") n.source = I(i(r()));
|
|
9004
9119
|
else return !1;
|
|
9005
9120
|
return !0;
|
|
@@ -9008,20 +9123,20 @@ var Wc = (e, t) => {
|
|
|
9008
9123
|
id: e
|
|
9009
9124
|
}), (t) => (t.declarationKinds[e] = n, t);
|
|
9010
9125
|
};
|
|
9011
|
-
function
|
|
9126
|
+
function $c(e) {
|
|
9012
9127
|
let t = " content " + N(e.id) + " {\n";
|
|
9013
9128
|
return e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), t += " }\n", t;
|
|
9014
9129
|
}
|
|
9015
|
-
function
|
|
9130
|
+
function el(e) {
|
|
9016
9131
|
let t = " source {\n";
|
|
9017
9132
|
return e.doc && (t += " doc \"" + s(e.doc) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), t += " }\n", t;
|
|
9018
9133
|
}
|
|
9019
|
-
var
|
|
9134
|
+
var tl = function(e) {
|
|
9020
9135
|
let t = "declaration_kind " + e.id + " {\n";
|
|
9021
9136
|
e.label && (t += " label \"" + s(e.label) + "\"\n"), e.holder && (t += " holder " + N(e.holder) + "\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.procedure && (t += " procedure \"" + s(e.procedure) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.scope_model && (t += " scope_model " + N(e.scope_model) + "\n"), e.scheme_a_obligation && (t += " scheme_a_obligation \"" + s(e.scheme_a_obligation) + "\"\n");
|
|
9022
|
-
for (let n of e.content) t +=
|
|
9023
|
-
return (e.source.doc || e.source.clause) && (t +=
|
|
9024
|
-
},
|
|
9137
|
+
for (let n of e.content) t += $c(n);
|
|
9138
|
+
return (e.source.doc || e.source.clause) && (t += el(e.source)), t += "}\n", t;
|
|
9139
|
+
}, nl = (e, t) => {
|
|
9025
9140
|
let n = {
|
|
9026
9141
|
id: e,
|
|
9027
9142
|
description: ""
|
|
@@ -9034,10 +9149,10 @@ var qc = function(e) {
|
|
|
9034
9149
|
construct: "declaration_status",
|
|
9035
9150
|
id: e
|
|
9036
9151
|
}), (t) => (t.declarationStatuses[e] = n, t);
|
|
9037
|
-
},
|
|
9152
|
+
}, rl = function(e) {
|
|
9038
9153
|
let t = "declaration_status " + e.id + " {\n";
|
|
9039
9154
|
return e.description && (t += " description \"" + s(e.description) + "\"\n"), t += "}\n", t;
|
|
9040
|
-
},
|
|
9155
|
+
}, il = (e, t) => {
|
|
9041
9156
|
let n = {
|
|
9042
9157
|
id: e,
|
|
9043
9158
|
clause: "",
|
|
@@ -9067,13 +9182,13 @@ var qc = function(e) {
|
|
|
9067
9182
|
construct: "declaration_gate",
|
|
9068
9183
|
id: e
|
|
9069
9184
|
}), (t) => (t.declarationGates[e] = n, t);
|
|
9070
|
-
},
|
|
9185
|
+
}, al = function(e) {
|
|
9071
9186
|
let t = "declaration_gate " + e.id + " {\n";
|
|
9072
|
-
return e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.statement && (t += " statement \"" + s(e.statement) + "\"\n"), e.holder && (t += " holder " + N(e.holder) + "\n"), e.declaration && (t += " declaration " + N(e.declaration) + "\n"), e.blocks.length > 0 && (t += " blocks { " + e.blocks.map(N).join(" ") + " }\n"), e.blocks_note && (t += " blocks_note \"" + s(e.blocks_note) + "\"\n"), e.scope_checked.length > 0 && (t += " scope_checked { " + e.scope_checked.map(N).join(" ") + " }\n"), (e.source.doc || e.source.clause) && (t +=
|
|
9187
|
+
return e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.statement && (t += " statement \"" + s(e.statement) + "\"\n"), e.holder && (t += " holder " + N(e.holder) + "\n"), e.declaration && (t += " declaration " + N(e.declaration) + "\n"), e.blocks.length > 0 && (t += " blocks { " + e.blocks.map(N).join(" ") + " }\n"), e.blocks_note && (t += " blocks_note \"" + s(e.blocks_note) + "\"\n"), e.scope_checked.length > 0 && (t += " scope_checked { " + e.scope_checked.map(N).join(" ") + " }\n"), (e.source.doc || e.source.clause) && (t += el(e.source)), t += "}\n", t;
|
|
9073
9188
|
};
|
|
9074
9189
|
//#endregion
|
|
9075
9190
|
//#region src/ser-des/config/scheme.ts
|
|
9076
|
-
function
|
|
9191
|
+
function ol(e) {
|
|
9077
9192
|
let t = {
|
|
9078
9193
|
method: "",
|
|
9079
9194
|
clause: "",
|
|
@@ -9092,7 +9207,7 @@ function Qc(e) {
|
|
|
9092
9207
|
id: ""
|
|
9093
9208
|
}), t;
|
|
9094
9209
|
}
|
|
9095
|
-
var
|
|
9210
|
+
var sl = (e, t) => {
|
|
9096
9211
|
let n = {
|
|
9097
9212
|
id: e,
|
|
9098
9213
|
label: "",
|
|
@@ -9110,7 +9225,7 @@ var $c = (e, t) => {
|
|
|
9110
9225
|
else if (e === "term") n.term = a(t());
|
|
9111
9226
|
else if (e === "clause") n.clause = a(t());
|
|
9112
9227
|
else if (e === "definition") n.definition = a(t());
|
|
9113
|
-
else if (e === "demonstration") n.demonstration =
|
|
9228
|
+
else if (e === "demonstration") n.demonstration = ol(i(t()));
|
|
9114
9229
|
else if (e === "source") n.source = I(i(t()));
|
|
9115
9230
|
else return !1;
|
|
9116
9231
|
return !0;
|
|
@@ -9119,19 +9234,19 @@ var $c = (e, t) => {
|
|
|
9119
9234
|
id: e
|
|
9120
9235
|
}), (t) => (t.schemeDefinitions[e] = n, t);
|
|
9121
9236
|
};
|
|
9122
|
-
function
|
|
9237
|
+
function cl(e) {
|
|
9123
9238
|
let t = " source {\n";
|
|
9124
9239
|
return e.doc && (t += " doc \"" + s(e.doc) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), t += " }\n", t;
|
|
9125
9240
|
}
|
|
9126
|
-
var
|
|
9241
|
+
var ll = function(e) {
|
|
9127
9242
|
let t = "scheme_definition " + e.id + " {\n";
|
|
9128
9243
|
if (e.label && (t += " label \"" + s(e.label) + "\"\n"), e.term && (t += " term \"" + s(e.term) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.definition && (t += " definition \"" + s(e.definition) + "\"\n"), e.demonstration) {
|
|
9129
9244
|
let n = e.demonstration;
|
|
9130
9245
|
t += " demonstration {\n", n.method && (t += " method " + N(n.method) + "\n"), n.clause && (t += " clause \"" + s(n.clause) + "\"\n"), n.basis.length > 0 && (t += " basis { " + n.basis.map(N).join(" ") + " }\n"), n.note && (t += " note \"" + s(n.note) + "\"\n"), t += " }\n";
|
|
9131
9246
|
}
|
|
9132
|
-
return (e.source.doc || e.source.clause) && (t +=
|
|
9247
|
+
return (e.source.doc || e.source.clause) && (t += cl(e.source)), t += "}\n", t;
|
|
9133
9248
|
};
|
|
9134
|
-
function
|
|
9249
|
+
function ul(e) {
|
|
9135
9250
|
let t = {
|
|
9136
9251
|
action: "",
|
|
9137
9252
|
automatic: !1,
|
|
@@ -9152,7 +9267,7 @@ function nl(e) {
|
|
|
9152
9267
|
id: ""
|
|
9153
9268
|
}), t;
|
|
9154
9269
|
}
|
|
9155
|
-
function
|
|
9270
|
+
function dl(e) {
|
|
9156
9271
|
let t = {
|
|
9157
9272
|
clause: "",
|
|
9158
9273
|
decided_by: "",
|
|
@@ -9171,7 +9286,7 @@ function rl(e) {
|
|
|
9171
9286
|
id: ""
|
|
9172
9287
|
}), t;
|
|
9173
9288
|
}
|
|
9174
|
-
function
|
|
9289
|
+
function fl(e, t) {
|
|
9175
9290
|
let n = {
|
|
9176
9291
|
id: e,
|
|
9177
9292
|
kind: "",
|
|
@@ -9200,7 +9315,7 @@ function il(e, t) {
|
|
|
9200
9315
|
id: e
|
|
9201
9316
|
}), n;
|
|
9202
9317
|
}
|
|
9203
|
-
var
|
|
9318
|
+
var pl = (e, t) => {
|
|
9204
9319
|
let n = {
|
|
9205
9320
|
id: e,
|
|
9206
9321
|
applies_to: "",
|
|
@@ -9216,7 +9331,7 @@ var al = (e, t) => {
|
|
|
9216
9331
|
return v(t, (t, r, o) => {
|
|
9217
9332
|
if (t === "applies_to") n.applies_to = a(r());
|
|
9218
9333
|
else if (t === "initial") n.initial = a(r());
|
|
9219
|
-
else if (t === "entry") n.entry =
|
|
9334
|
+
else if (t === "entry") n.entry = ul(i(r()));
|
|
9220
9335
|
else if (t === "transition") {
|
|
9221
9336
|
let t = a(r()), s = o();
|
|
9222
9337
|
if (s === void 0 || s !== "->" && s !== "→") throw Error(`Parsing error: scheme_lifecycle. ID ${e}: transition ${t} is missing its '->'`);
|
|
@@ -9225,7 +9340,7 @@ var al = (e, t) => {
|
|
|
9225
9340
|
o() === "action" && (r(), l = a(r()));
|
|
9226
9341
|
let u = o();
|
|
9227
9342
|
if (u === void 0 || !u.startsWith("{")) throw Error(`Parsing error: scheme_lifecycle. ID ${e}: transition ${t} -> ${c} is missing its block`);
|
|
9228
|
-
let d =
|
|
9343
|
+
let d = dl(i(r()));
|
|
9229
9344
|
n.transitions.push({
|
|
9230
9345
|
from: t,
|
|
9231
9346
|
to: c,
|
|
@@ -9235,7 +9350,7 @@ var al = (e, t) => {
|
|
|
9235
9350
|
} else if (t === "trigger") {
|
|
9236
9351
|
let t = a(r()), s = o();
|
|
9237
9352
|
if (s === void 0 || !s.startsWith("{")) throw Error(`Parsing error: scheme_lifecycle. ID ${e}: trigger ${t} is missing its block`);
|
|
9238
|
-
n.triggers.push(
|
|
9353
|
+
n.triggers.push(fl(t, i(r())));
|
|
9239
9354
|
} else if (t === "source") n.source = I(i(r()));
|
|
9240
9355
|
else return !1;
|
|
9241
9356
|
return !0;
|
|
@@ -9243,7 +9358,7 @@ var al = (e, t) => {
|
|
|
9243
9358
|
construct: "scheme_lifecycle",
|
|
9244
9359
|
id: e
|
|
9245
9360
|
}), (t) => (t.schemeLifecycles[e] = n, t);
|
|
9246
|
-
},
|
|
9361
|
+
}, ml = function(e) {
|
|
9247
9362
|
let t = "scheme_lifecycle " + e.id + " {\n";
|
|
9248
9363
|
if (e.applies_to && (t += " applies_to " + N(e.applies_to) + "\n"), e.initial && (t += " initial " + N(e.initial) + "\n"), e.entry) {
|
|
9249
9364
|
let n = e.entry;
|
|
@@ -9257,15 +9372,15 @@ var al = (e, t) => {
|
|
|
9257
9372
|
}
|
|
9258
9373
|
n.clause && (t += " clause \"" + s(n.clause) + "\"\n"), n.deferrable && (t += " deferrable true\n"), n.deferral_note && (t += " deferral_note \"" + s(n.deferral_note) + "\"\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), t += " }\n";
|
|
9259
9374
|
}
|
|
9260
|
-
return (e.source.doc || e.source.clause) && (t +=
|
|
9375
|
+
return (e.source.doc || e.source.clause) && (t += cl(e.source)), t += "}\n", t;
|
|
9261
9376
|
};
|
|
9262
9377
|
//#endregion
|
|
9263
9378
|
//#region src/ser-des/config/frameworkDocument.ts
|
|
9264
|
-
function
|
|
9379
|
+
function hl(e) {
|
|
9265
9380
|
let t = " source {\n";
|
|
9266
9381
|
return e.doc && (t += " doc \"" + s(e.doc) + "\"\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), t += " }\n", t;
|
|
9267
9382
|
}
|
|
9268
|
-
var
|
|
9383
|
+
var gl = (e, t) => {
|
|
9269
9384
|
let n = {
|
|
9270
9385
|
id: e,
|
|
9271
9386
|
rank: 0,
|
|
@@ -9293,10 +9408,10 @@ var cl = (e, t) => {
|
|
|
9293
9408
|
construct: "framework_document",
|
|
9294
9409
|
id: e
|
|
9295
9410
|
}), (t) => (t.frameworkDocuments[e] = n, t);
|
|
9296
|
-
},
|
|
9411
|
+
}, _l = function(e) {
|
|
9297
9412
|
let t = "framework_document " + e.id + " {\n";
|
|
9298
|
-
return e.rank > 0 && (t += " rank " + e.rank + "\n"), e.doc && (t += " doc \"" + s(e.doc) + "\"\n"), e.title && (t += " title \"" + s(e.title) + "\"\n"), e.approved_by && (t += " approved_by " + N(e.approved_by) + "\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.note && (t += " note \"" + s(e.note) + "\"\n"), (e.source.doc || e.source.clause) && (t +=
|
|
9299
|
-
},
|
|
9413
|
+
return e.rank > 0 && (t += " rank " + e.rank + "\n"), e.doc && (t += " doc \"" + s(e.doc) + "\"\n"), e.title && (t += " title \"" + s(e.title) + "\"\n"), e.approved_by && (t += " approved_by " + N(e.approved_by) + "\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.note && (t += " note \"" + s(e.note) + "\"\n"), (e.source.doc || e.source.clause) && (t += hl(e.source)), t += "}\n", t;
|
|
9414
|
+
}, vl = (e, t) => {
|
|
9300
9415
|
let n = {
|
|
9301
9416
|
id: e,
|
|
9302
9417
|
clause: "",
|
|
@@ -9316,11 +9431,11 @@ var cl = (e, t) => {
|
|
|
9316
9431
|
construct: "document_precedence",
|
|
9317
9432
|
id: e
|
|
9318
9433
|
}), (t) => (t.documentPrecedences[e] = n, t);
|
|
9319
|
-
},
|
|
9434
|
+
}, yl = function(e) {
|
|
9320
9435
|
let t = "document_precedence " + e.id + " {\n";
|
|
9321
|
-
return e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.statement && (t += " statement \"" + s(e.statement) + "\"\n"), (e.source.doc || e.source.clause) && (t +=
|
|
9436
|
+
return e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.statement && (t += " statement \"" + s(e.statement) + "\"\n"), (e.source.doc || e.source.clause) && (t += hl(e.source)), t += "}\n", t;
|
|
9322
9437
|
};
|
|
9323
|
-
function
|
|
9438
|
+
function bl(e, t) {
|
|
9324
9439
|
let n = {
|
|
9325
9440
|
id: e,
|
|
9326
9441
|
clause: "",
|
|
@@ -9336,7 +9451,7 @@ function fl(e, t) {
|
|
|
9336
9451
|
id: e
|
|
9337
9452
|
}), n;
|
|
9338
9453
|
}
|
|
9339
|
-
var
|
|
9454
|
+
var xl = (e, t) => {
|
|
9340
9455
|
let n = {
|
|
9341
9456
|
id: e,
|
|
9342
9457
|
clause: "",
|
|
@@ -9354,7 +9469,7 @@ var pl = (e, t) => {
|
|
|
9354
9469
|
else if (t === "condition") {
|
|
9355
9470
|
let t = a(r()), s = o();
|
|
9356
9471
|
if (s === void 0 || !s.startsWith("{")) throw Error(`Parsing error: auto_inclusion. ID ${e}: condition ${t} is missing its block`);
|
|
9357
|
-
n.conditions.push(
|
|
9472
|
+
n.conditions.push(bl(t, i(r())));
|
|
9358
9473
|
} else if (t === "note") n.note = a(r());
|
|
9359
9474
|
else if (t === "source") n.source = I(i(r()));
|
|
9360
9475
|
else return !1;
|
|
@@ -9363,15 +9478,15 @@ var pl = (e, t) => {
|
|
|
9363
9478
|
construct: "auto_inclusion",
|
|
9364
9479
|
id: e
|
|
9365
9480
|
}), (t) => (t.autoInclusions[e] = n, t);
|
|
9366
|
-
},
|
|
9481
|
+
}, Sl = function(e) {
|
|
9367
9482
|
let t = "auto_inclusion " + e.id + " {\n";
|
|
9368
9483
|
e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.statement && (t += " statement \"" + s(e.statement) + "\"\n");
|
|
9369
9484
|
for (let n of e.conditions) t += " condition " + N(n.id) + " {\n", n.clause && (t += " clause \"" + s(n.clause) + "\"\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), t += " }\n";
|
|
9370
|
-
return e.note && (t += " note \"" + s(e.note) + "\"\n"), (e.source.doc || e.source.clause) && (t +=
|
|
9485
|
+
return e.note && (t += " note \"" + s(e.note) + "\"\n"), (e.source.doc || e.source.clause) && (t += hl(e.source)), t += "}\n", t;
|
|
9371
9486
|
};
|
|
9372
9487
|
//#endregion
|
|
9373
9488
|
//#region src/ser-des/config/decisionRule.ts
|
|
9374
|
-
function
|
|
9489
|
+
function Cl(e) {
|
|
9375
9490
|
let t = {
|
|
9376
9491
|
threshold: 0,
|
|
9377
9492
|
base: "",
|
|
@@ -9390,7 +9505,7 @@ function hl(e) {
|
|
|
9390
9505
|
id: ""
|
|
9391
9506
|
}), t;
|
|
9392
9507
|
}
|
|
9393
|
-
function
|
|
9508
|
+
function wl(e) {
|
|
9394
9509
|
let t = {
|
|
9395
9510
|
in_meeting: 0,
|
|
9396
9511
|
by_correspondence: "",
|
|
@@ -9407,7 +9522,7 @@ function gl(e) {
|
|
|
9407
9522
|
id: ""
|
|
9408
9523
|
}), t;
|
|
9409
9524
|
}
|
|
9410
|
-
function
|
|
9525
|
+
function Tl(e) {
|
|
9411
9526
|
let t = {
|
|
9412
9527
|
in_meeting: null,
|
|
9413
9528
|
by_correspondence: null,
|
|
@@ -9417,9 +9532,9 @@ function _l(e) {
|
|
|
9417
9532
|
reason_on_against_or_abstain: !1
|
|
9418
9533
|
};
|
|
9419
9534
|
return v(e, (e, n) => {
|
|
9420
|
-
if (e === "in_meeting") t.in_meeting =
|
|
9421
|
-
else if (e === "by_correspondence") t.by_correspondence =
|
|
9422
|
-
else if (e === "other_proposals") t.other_proposals =
|
|
9535
|
+
if (e === "in_meeting") t.in_meeting = Cl(i(n()));
|
|
9536
|
+
else if (e === "by_correspondence") t.by_correspondence = Cl(i(n()));
|
|
9537
|
+
else if (e === "other_proposals") t.other_proposals = wl(i(n()));
|
|
9423
9538
|
else if (e === "proxies_max") t.proxies_max = parseInt(a(n()), 10) || 0;
|
|
9424
9539
|
else if (e === "abstentions") t.abstentions = a(n());
|
|
9425
9540
|
else if (e === "reason_on_against_or_abstain") t.reason_on_against_or_abstain = n() === "true";
|
|
@@ -9430,7 +9545,7 @@ function _l(e) {
|
|
|
9430
9545
|
id: ""
|
|
9431
9546
|
}), t;
|
|
9432
9547
|
}
|
|
9433
|
-
function
|
|
9548
|
+
function El(e, t) {
|
|
9434
9549
|
let n = {
|
|
9435
9550
|
id: e,
|
|
9436
9551
|
clause: "",
|
|
@@ -9446,10 +9561,10 @@ function vl(e, t) {
|
|
|
9446
9561
|
id: e
|
|
9447
9562
|
}), n;
|
|
9448
9563
|
}
|
|
9449
|
-
function
|
|
9564
|
+
function Dl(e) {
|
|
9450
9565
|
return r(i(e)).filter((e) => e.length > 0);
|
|
9451
9566
|
}
|
|
9452
|
-
var
|
|
9567
|
+
var Ol = (e, t) => {
|
|
9453
9568
|
let n = {
|
|
9454
9569
|
id: e,
|
|
9455
9570
|
organ: "",
|
|
@@ -9478,17 +9593,17 @@ var bl = (e, t) => {
|
|
|
9478
9593
|
else if (t === "description") n.description = a(r());
|
|
9479
9594
|
else if (t === "on_recommendation_of") n.on_recommendation_of = a(r());
|
|
9480
9595
|
else if (t === "independent_of") n.independent_of = a(r());
|
|
9481
|
-
else if (t === "decides") n.decides =
|
|
9482
|
-
else if (t === "voting") n.voting =
|
|
9483
|
-
else if (t === "tasks") n.tasks =
|
|
9484
|
-
else if (t === "scope") n.scope =
|
|
9596
|
+
else if (t === "decides") n.decides = Dl(r());
|
|
9597
|
+
else if (t === "voting") n.voting = Tl(i(r()));
|
|
9598
|
+
else if (t === "tasks") n.tasks = Dl(r());
|
|
9599
|
+
else if (t === "scope") n.scope = Dl(r());
|
|
9485
9600
|
else if (t === "principle") n.principle = a(r());
|
|
9486
9601
|
else if (t === "legacy_kind") {
|
|
9487
9602
|
let t = a(r()), s = o();
|
|
9488
9603
|
if (s === void 0 || !s.startsWith("{")) throw Error(`Parsing error: decision_rule. ID ${e}: legacy_kind ${t} is missing its block`);
|
|
9489
|
-
n.legacy_kinds.push(
|
|
9604
|
+
n.legacy_kinds.push(El(t, i(r())));
|
|
9490
9605
|
} else if (t === "income") n.income = a(r());
|
|
9491
|
-
else if (t === "no_entrance_fees_for") n.no_entrance_fees_for =
|
|
9606
|
+
else if (t === "no_entrance_fees_for") n.no_entrance_fees_for = Dl(r());
|
|
9492
9607
|
else if (t === "source") n.source = I(i(r()));
|
|
9493
9608
|
else return !1;
|
|
9494
9609
|
return !0;
|
|
@@ -9497,27 +9612,27 @@ var bl = (e, t) => {
|
|
|
9497
9612
|
id: e
|
|
9498
9613
|
}), (t) => (t.decisionRules[e] = n, t);
|
|
9499
9614
|
};
|
|
9500
|
-
function
|
|
9615
|
+
function kl(e, t) {
|
|
9501
9616
|
let n = " " + e + " {\n";
|
|
9502
9617
|
return t.threshold > 0 && (n += " threshold " + t.threshold + "\n"), t.base && (n += " base " + N(t.base) + "\n"), t.clause && (n += " clause \"" + s(t.clause) + "\"\n"), t.description && (n += " description \"" + s(t.description) + "\"\n"), n += " }\n", n;
|
|
9503
9618
|
}
|
|
9504
|
-
function
|
|
9619
|
+
function Al(e) {
|
|
9505
9620
|
let t = " voting {\n";
|
|
9506
|
-
if (e.in_meeting && (t +=
|
|
9621
|
+
if (e.in_meeting && (t += kl("in_meeting", e.in_meeting)), e.by_correspondence && (t += kl("by_correspondence", e.by_correspondence)), e.other_proposals) {
|
|
9507
9622
|
let n = e.other_proposals;
|
|
9508
9623
|
t += " other_proposals {\n", n.in_meeting > 0 && (t += " in_meeting " + n.in_meeting + "\n"), n.by_correspondence && (t += " by_correspondence " + N(n.by_correspondence) + "\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), t += " }\n";
|
|
9509
9624
|
}
|
|
9510
9625
|
return e.proxies_max > 0 && (t += " proxies_max " + e.proxies_max + "\n"), e.abstentions && (t += " abstentions " + N(e.abstentions) + "\n"), e.reason_on_against_or_abstain && (t += " reason_on_against_or_abstain true\n"), t += " }\n", t;
|
|
9511
9626
|
}
|
|
9512
|
-
function
|
|
9627
|
+
function jl(e, t, n) {
|
|
9513
9628
|
return n + e + " { " + t.map(N).join(" ") + " }\n";
|
|
9514
9629
|
}
|
|
9515
|
-
var
|
|
9630
|
+
var Ml = function(e) {
|
|
9516
9631
|
let t = "decision_rule " + e.id + " {\n";
|
|
9517
|
-
e.organ && (t += " organ " + N(e.organ) + "\n"), e.kind && (t += " kind " + N(e.kind) + "\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.on_recommendation_of && (t += " on_recommendation_of " + N(e.on_recommendation_of) + "\n"), e.independent_of && (t += " independent_of " + N(e.independent_of) + "\n"), e.decides.length > 0 && (t +=
|
|
9632
|
+
e.organ && (t += " organ " + N(e.organ) + "\n"), e.kind && (t += " kind " + N(e.kind) + "\n"), e.clause && (t += " clause \"" + s(e.clause) + "\"\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.on_recommendation_of && (t += " on_recommendation_of " + N(e.on_recommendation_of) + "\n"), e.independent_of && (t += " independent_of " + N(e.independent_of) + "\n"), e.decides.length > 0 && (t += jl("decides", e.decides, " ")), e.voting && (t += Al(e.voting)), e.tasks.length > 0 && (t += jl("tasks", e.tasks, " ")), e.scope.length > 0 && (t += jl("scope", e.scope, " ")), e.principle && (t += " principle " + N(e.principle) + "\n");
|
|
9518
9633
|
for (let n of e.legacy_kinds) t += " legacy_kind " + N(n.id) + " {\n", n.clause && (t += " clause \"" + s(n.clause) + "\"\n"), n.description && (t += " description \"" + s(n.description) + "\"\n"), t += " }\n";
|
|
9519
|
-
return e.income && (t += " income " + N(e.income) + "\n"), e.no_entrance_fees_for.length > 0 && (t +=
|
|
9520
|
-
},
|
|
9634
|
+
return e.income && (t += " income " + N(e.income) + "\n"), e.no_entrance_fees_for.length > 0 && (t += jl("no_entrance_fees_for", e.no_entrance_fees_for, " ")), (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
9635
|
+
}, Nl = (e, t) => {
|
|
9521
9636
|
let n = {
|
|
9522
9637
|
id: e,
|
|
9523
9638
|
document: "",
|
|
@@ -9550,15 +9665,15 @@ var wl = function(e) {
|
|
|
9550
9665
|
construct: "document_module",
|
|
9551
9666
|
id: e
|
|
9552
9667
|
}), (t) => (t.documentModules[e] = n, t);
|
|
9553
|
-
},
|
|
9668
|
+
}, Pl = function(e) {
|
|
9554
9669
|
let t = "document_module " + e.id + " {\n";
|
|
9555
9670
|
e.document && (t += " document \"" + s(e.document) + "\"\n"), e.title && (t += " title \"" + s(e.title) + "\"\n"), e.edition && (t += " edition \"" + s(e.edition) + "\"\n"), e.year && (t += " year " + e.year + "\n"), e.namespace && (t += " namespace " + N(e.namespace) + "\n");
|
|
9556
9671
|
let n = Et(e.sequence);
|
|
9557
9672
|
n && (t += " " + n + "\n");
|
|
9558
9673
|
for (let n of e.registers) t += Dt(n, " ");
|
|
9559
9674
|
return (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
9560
|
-
},
|
|
9561
|
-
function
|
|
9675
|
+
}, Fl = ["informative"];
|
|
9676
|
+
function Il(e, t) {
|
|
9562
9677
|
let n = {
|
|
9563
9678
|
id: "",
|
|
9564
9679
|
title: "",
|
|
@@ -9574,7 +9689,7 @@ function Ol(e, t) {
|
|
|
9574
9689
|
else if (e === "year") n.year = parseInt(a(r()), 10) || 0;
|
|
9575
9690
|
else if (e === "role") {
|
|
9576
9691
|
let e = a(r());
|
|
9577
|
-
if (!
|
|
9692
|
+
if (!Fl.includes(e)) throw Error(`Parsing error: informative_annex. ID ${t}: Unknown document role "${e}" (valid: ${Fl.join(", ")})`);
|
|
9578
9693
|
n.role = e;
|
|
9579
9694
|
} else if (e === "source") n.source = a(r());
|
|
9580
9695
|
else return !1;
|
|
@@ -9584,7 +9699,7 @@ function Ol(e, t) {
|
|
|
9584
9699
|
id: t
|
|
9585
9700
|
}), n;
|
|
9586
9701
|
}
|
|
9587
|
-
function
|
|
9702
|
+
function Ll(e, t) {
|
|
9588
9703
|
let n = {
|
|
9589
9704
|
id: e,
|
|
9590
9705
|
clause: "",
|
|
@@ -9604,7 +9719,7 @@ function kl(e, t) {
|
|
|
9604
9719
|
id: e
|
|
9605
9720
|
}), n;
|
|
9606
9721
|
}
|
|
9607
|
-
var
|
|
9722
|
+
var Rl = (e, t) => {
|
|
9608
9723
|
let n = {
|
|
9609
9724
|
id: e,
|
|
9610
9725
|
document: {
|
|
@@ -9622,7 +9737,7 @@ var Al = (e, t) => {
|
|
|
9622
9737
|
highlights: []
|
|
9623
9738
|
};
|
|
9624
9739
|
return v(t, (t, r, o) => {
|
|
9625
|
-
if (t === "document") n.document =
|
|
9740
|
+
if (t === "document") n.document = Il(i(r()), e);
|
|
9626
9741
|
else if (t === "applies_to") n.appliesTo = a(r());
|
|
9627
9742
|
else if (t === "applied_by") n.appliedBy = a(r());
|
|
9628
9743
|
else if (t === "scope") n.scope = a(r());
|
|
@@ -9630,19 +9745,19 @@ var Al = (e, t) => {
|
|
|
9630
9745
|
else if (t === "highlight") {
|
|
9631
9746
|
let t = a(r()), s = o();
|
|
9632
9747
|
if (s === void 0 || !s.startsWith("{")) throw Error(`Parsing error: informative_annex. ID ${e}: highlight ${t} is missing its block`);
|
|
9633
|
-
n.highlights.push(
|
|
9748
|
+
n.highlights.push(Ll(t, i(r())));
|
|
9634
9749
|
} else return !1;
|
|
9635
9750
|
return !0;
|
|
9636
9751
|
}, {
|
|
9637
9752
|
construct: "informative_annex",
|
|
9638
9753
|
id: e
|
|
9639
9754
|
}), (t) => (t.informativeAnnexes[e] = n, t);
|
|
9640
|
-
},
|
|
9755
|
+
}, zl = function(e) {
|
|
9641
9756
|
let t = "informative_annex " + e.id + " {\n";
|
|
9642
9757
|
t += " document {\n", e.document.id && (t += " id \"" + s(e.document.id) + "\"\n"), e.document.title && (t += " title \"" + s(e.document.title) + "\"\n"), e.document.edition && (t += " edition " + e.document.edition + "\n"), e.document.year && (t += " year " + e.document.year + "\n"), e.document.role && (t += " role " + N(e.document.role) + "\n"), e.document.source && (t += " source \"" + s(e.document.source) + "\"\n"), t += " }\n", e.appliesTo && (t += " applies_to " + N(e.appliesTo) + "\n"), e.appliedBy && (t += " applied_by \"" + s(e.appliedBy) + "\"\n"), e.scope && (t += " scope \"" + s(e.scope) + "\"\n"), e.numberingCaution && (t += " numbering_caution \"" + s(e.numberingCaution) + "\"\n");
|
|
9643
9758
|
for (let n of e.highlights) t += " highlight " + N(n.id) + " {\n", n.clause && (t += " clause \"" + s(n.clause) + "\"\n"), n.title && (t += " title \"" + s(n.title) + "\"\n"), n.statement && (t += " statement \"" + s(n.statement) + "\"\n"), n.dischargedBy && (t += " discharged_by \"" + s(n.dischargedBy) + "\"\n"), t += " }\n";
|
|
9644
9759
|
return t += "}\n", t;
|
|
9645
|
-
},
|
|
9760
|
+
}, Bl = ["normative", "informative"], Vl = (e, t) => {
|
|
9646
9761
|
let n = {
|
|
9647
9762
|
id: e,
|
|
9648
9763
|
letter: "",
|
|
@@ -9660,7 +9775,7 @@ var Al = (e, t) => {
|
|
|
9660
9775
|
else if (t === "title") n.title = a(r());
|
|
9661
9776
|
else if (t === "obligation") {
|
|
9662
9777
|
let t = a(r());
|
|
9663
|
-
if (!
|
|
9778
|
+
if (!Bl.includes(t)) throw Error(`Parsing error: part_annex. ID ${e}: Unknown obligation "${t}" (valid: ${Bl.join(", ")})`);
|
|
9664
9779
|
n.obligation = t;
|
|
9665
9780
|
} else if (t === "summary") n.summary = a(r());
|
|
9666
9781
|
else if (t === "realization") n.realization = a(r());
|
|
@@ -9671,30 +9786,30 @@ var Al = (e, t) => {
|
|
|
9671
9786
|
construct: "part_annex",
|
|
9672
9787
|
id: e
|
|
9673
9788
|
}), (t) => (t.partAnnexes[e] = n, t);
|
|
9674
|
-
},
|
|
9789
|
+
}, Hl = function(e) {
|
|
9675
9790
|
let t = "part_annex " + e.id + " {\n";
|
|
9676
9791
|
return e.letter && (t += " letter \"" + s(e.letter) + "\"\n"), e.title && (t += " title \"" + s(e.title) + "\"\n"), e.obligation && (t += " obligation " + N(e.obligation) + "\n"), e.summary && (t += " summary \"" + s(e.summary) + "\"\n"), e.realization && (t += " realization \"" + s(e.realization) + "\"\n"), (e.source.doc || e.source.clause) && (t += " source {\n", e.source.doc && (t += " doc \"" + s(e.source.doc) + "\"\n"), e.source.clause && (t += " clause \"" + s(e.source.clause) + "\"\n"), t += " }\n"), t += "}\n", t;
|
|
9677
9792
|
};
|
|
9678
9793
|
//#endregion
|
|
9679
9794
|
//#region src/ser-des/config/storyline.ts
|
|
9680
|
-
function
|
|
9795
|
+
function Ul(e) {
|
|
9681
9796
|
return e.startsWith("{") ? n(i(e)).filter((e) => e.length > 0).map(z) : z(e);
|
|
9682
9797
|
}
|
|
9683
|
-
function
|
|
9798
|
+
function Wl(e) {
|
|
9684
9799
|
let t = {}, r = n(e), i = 0;
|
|
9685
9800
|
for (; i < r.length;) {
|
|
9686
9801
|
let e = r[i++];
|
|
9687
9802
|
if (i >= r.length) break;
|
|
9688
|
-
t[P(e)] =
|
|
9803
|
+
t[P(e)] = Ul(r[i++]);
|
|
9689
9804
|
}
|
|
9690
9805
|
return t;
|
|
9691
9806
|
}
|
|
9692
|
-
function
|
|
9807
|
+
function Gl(e, t) {
|
|
9693
9808
|
let n = "";
|
|
9694
9809
|
for (let [r, i] of Object.entries(e)) n += Array.isArray(i) ? t + r + " { " + i.map(B).join(" ") + " }\n" : t + r + " " + B(i) + "\n";
|
|
9695
9810
|
return n;
|
|
9696
9811
|
}
|
|
9697
|
-
function
|
|
9812
|
+
function Kl(e) {
|
|
9698
9813
|
let t = [], r = n(e), o = 0;
|
|
9699
9814
|
for (; o < r.length;) {
|
|
9700
9815
|
let e = a(r[o++]);
|
|
@@ -9708,14 +9823,14 @@ function Rl(e) {
|
|
|
9708
9823
|
if (l >= c.length || !c[l].startsWith("{")) break;
|
|
9709
9824
|
s.entries.push({
|
|
9710
9825
|
id: e,
|
|
9711
|
-
fields:
|
|
9826
|
+
fields: Wl(i(c[l++]))
|
|
9712
9827
|
});
|
|
9713
9828
|
}
|
|
9714
9829
|
t.push(s);
|
|
9715
9830
|
}
|
|
9716
9831
|
return t;
|
|
9717
9832
|
}
|
|
9718
|
-
var
|
|
9833
|
+
var ql = (e, t) => {
|
|
9719
9834
|
let n = {
|
|
9720
9835
|
id: e,
|
|
9721
9836
|
standard: "",
|
|
@@ -9725,27 +9840,27 @@ var zl = (e, t) => {
|
|
|
9725
9840
|
return v(t, (e, t) => {
|
|
9726
9841
|
if (e === "standard") n.standard = a(t());
|
|
9727
9842
|
else if (e === "description") n.description = a(t());
|
|
9728
|
-
else if (e === "participants") n.participants =
|
|
9843
|
+
else if (e === "participants") n.participants = Kl(i(t()));
|
|
9729
9844
|
else return !1;
|
|
9730
9845
|
return !0;
|
|
9731
9846
|
}, {
|
|
9732
9847
|
construct: "demo_world",
|
|
9733
9848
|
id: e
|
|
9734
9849
|
}), (t) => (t.demoWorlds[e] = n, t);
|
|
9735
|
-
},
|
|
9850
|
+
}, Jl = function(e) {
|
|
9736
9851
|
let t = "demo_world " + e.id + " {\n";
|
|
9737
9852
|
if (e.standard && (t += " standard " + N(e.standard) + "\n"), e.description && (t += " description \"" + s(e.description) + "\"\n"), e.participants.length > 0) {
|
|
9738
9853
|
t += " participants {\n";
|
|
9739
9854
|
for (let n of e.participants) {
|
|
9740
9855
|
t += " " + N(n.id) + " {\n";
|
|
9741
|
-
for (let e of n.entries) t += " " + N(e.id) + " {\n", t +=
|
|
9856
|
+
for (let e of n.entries) t += " " + N(e.id) + " {\n", t += Gl(e.fields, " "), t += " }\n";
|
|
9742
9857
|
t += " }\n";
|
|
9743
9858
|
}
|
|
9744
9859
|
t += " }\n";
|
|
9745
9860
|
}
|
|
9746
9861
|
return t += "}\n", t;
|
|
9747
9862
|
};
|
|
9748
|
-
function
|
|
9863
|
+
function Yl(e) {
|
|
9749
9864
|
let t = [], r = n(e), o = 0;
|
|
9750
9865
|
for (; o < r.length;) {
|
|
9751
9866
|
let e = a(r[o++]);
|
|
@@ -9755,11 +9870,11 @@ function Vl(e) {
|
|
|
9755
9870
|
id: a(r[o++]),
|
|
9756
9871
|
fields: {}
|
|
9757
9872
|
};
|
|
9758
|
-
o < r.length && r[o].startsWith("{") && (n.fields =
|
|
9873
|
+
o < r.length && r[o].startsWith("{") && (n.fields = Wl(i(r[o++]))), t.push(n);
|
|
9759
9874
|
}
|
|
9760
9875
|
return t;
|
|
9761
9876
|
}
|
|
9762
|
-
var
|
|
9877
|
+
var Xl = (e, t) => {
|
|
9763
9878
|
let r = {
|
|
9764
9879
|
id: e,
|
|
9765
9880
|
name: "",
|
|
@@ -9778,7 +9893,7 @@ var Hl = (e, t) => {
|
|
|
9778
9893
|
else if (t === "party") {
|
|
9779
9894
|
let e = n(i(o()));
|
|
9780
9895
|
for (let t = 0; t + 1 < e.length; t += 2) e[t] === "laboratory" ? r.party.laboratory = a(e[t + 1]) : e[t] === "authority" && (r.party.authority = a(e[t + 1]));
|
|
9781
|
-
} else if (t === "subject") r.subject =
|
|
9896
|
+
} else if (t === "subject") r.subject = Yl(i(o()));
|
|
9782
9897
|
else if (t === "record") {
|
|
9783
9898
|
let t = a(o()), n = s();
|
|
9784
9899
|
if (n === void 0 || n.startsWith("{")) throw Error(`Parsing error: storyline. ID ${e}: record ${t} is missing its id and block`);
|
|
@@ -9787,7 +9902,7 @@ var Hl = (e, t) => {
|
|
|
9787
9902
|
r.records.push({
|
|
9788
9903
|
store: t,
|
|
9789
9904
|
id: c,
|
|
9790
|
-
fields:
|
|
9905
|
+
fields: Wl(i(o()))
|
|
9791
9906
|
});
|
|
9792
9907
|
} else if (t === "note") r.notes.push(a(o()));
|
|
9793
9908
|
else return !1;
|
|
@@ -9796,14 +9911,14 @@ var Hl = (e, t) => {
|
|
|
9796
9911
|
construct: "storyline",
|
|
9797
9912
|
id: e
|
|
9798
9913
|
}), (t) => (t.storylines[e] = r, t);
|
|
9799
|
-
},
|
|
9914
|
+
}, Zl = function(e) {
|
|
9800
9915
|
let t = "storyline " + e.id + " {\n";
|
|
9801
9916
|
if (e.name && (t += " name \"" + s(e.name) + "\"\n"), e.idPrefix && (t += " id_prefix " + N(e.idPrefix) + "\n"), (e.party.laboratory || e.party.authority) && (t += " party {", e.party.laboratory && (t += " laboratory " + N(e.party.laboratory)), e.party.authority && (t += " authority " + N(e.party.authority)), t += " }\n"), e.subject.length > 0) {
|
|
9802
9917
|
t += " subject {\n";
|
|
9803
|
-
for (let n of e.subject) t += " " + N(n.kind) + " " + N(n.id) + " {\n", t +=
|
|
9918
|
+
for (let n of e.subject) t += " " + N(n.kind) + " " + N(n.id) + " {\n", t += Gl(n.fields, " "), t += " }\n";
|
|
9804
9919
|
t += " }\n";
|
|
9805
9920
|
}
|
|
9806
|
-
for (let n of e.records) t += " record " + N(n.store) + " " + N(n.id) + " {\n", t +=
|
|
9921
|
+
for (let n of e.records) t += " record " + N(n.store) + " " + N(n.id) + " {\n", t += Gl(n.fields, " "), t += " }\n";
|
|
9807
9922
|
for (let n of e.notes) t += " note \"" + s(n) + "\"\n";
|
|
9808
9923
|
return t += "}\n", t;
|
|
9809
9924
|
};
|
|
@@ -9812,7 +9927,7 @@ var Hl = (e, t) => {
|
|
|
9812
9927
|
function J(e) {
|
|
9813
9928
|
return e;
|
|
9814
9929
|
}
|
|
9815
|
-
var
|
|
9930
|
+
var Ql = [
|
|
9816
9931
|
J({
|
|
9817
9932
|
keyword: "role",
|
|
9818
9933
|
field: "roles",
|
|
@@ -10013,8 +10128,8 @@ var Wl = [
|
|
|
10013
10128
|
keyword: "term",
|
|
10014
10129
|
field: "terms",
|
|
10015
10130
|
takesID: !0,
|
|
10016
|
-
parse:
|
|
10017
|
-
dump:
|
|
10131
|
+
parse: Vi,
|
|
10132
|
+
dump: Hi
|
|
10018
10133
|
}),
|
|
10019
10134
|
J({
|
|
10020
10135
|
keyword: "form",
|
|
@@ -10027,8 +10142,8 @@ var Wl = [
|
|
|
10027
10142
|
keyword: "certificate_template",
|
|
10028
10143
|
field: "certificateTemplates",
|
|
10029
10144
|
takesID: !0,
|
|
10030
|
-
parse:
|
|
10031
|
-
dump:
|
|
10145
|
+
parse: Rs,
|
|
10146
|
+
dump: zs
|
|
10032
10147
|
}),
|
|
10033
10148
|
J({
|
|
10034
10149
|
keyword: "subform",
|
|
@@ -10078,50 +10193,50 @@ var Wl = [
|
|
|
10078
10193
|
keyword: "calculation_context",
|
|
10079
10194
|
field: "calculationContexts",
|
|
10080
10195
|
takesID: !0,
|
|
10081
|
-
parse:
|
|
10082
|
-
dump:
|
|
10196
|
+
parse: Os,
|
|
10197
|
+
dump: ks
|
|
10083
10198
|
}),
|
|
10084
10199
|
J({
|
|
10085
10200
|
keyword: "evaluation_dimensions",
|
|
10086
10201
|
field: "evaluationDimensions",
|
|
10087
10202
|
takesID: !0,
|
|
10088
|
-
parse:
|
|
10089
|
-
dump:
|
|
10203
|
+
parse: Ms,
|
|
10204
|
+
dump: Ns
|
|
10090
10205
|
}),
|
|
10091
10206
|
J({
|
|
10092
10207
|
keyword: "evaluation_profile",
|
|
10093
10208
|
field: "evaluationProfiles",
|
|
10094
10209
|
takesID: !0,
|
|
10095
|
-
parse:
|
|
10096
|
-
dump:
|
|
10210
|
+
parse: Ps,
|
|
10211
|
+
dump: Fs
|
|
10097
10212
|
}),
|
|
10098
10213
|
J({
|
|
10099
10214
|
keyword: "verdict",
|
|
10100
10215
|
field: "verdicts",
|
|
10101
10216
|
takesID: !0,
|
|
10102
|
-
parse:
|
|
10103
|
-
dump:
|
|
10217
|
+
parse: Gi,
|
|
10218
|
+
dump: Ki
|
|
10104
10219
|
}),
|
|
10105
10220
|
J({
|
|
10106
10221
|
keyword: "reference_material",
|
|
10107
10222
|
field: "referenceMaterials",
|
|
10108
10223
|
takesID: !0,
|
|
10109
|
-
parse:
|
|
10110
|
-
dump:
|
|
10224
|
+
parse: Yi,
|
|
10225
|
+
dump: Xi
|
|
10111
10226
|
}),
|
|
10112
10227
|
J({
|
|
10113
10228
|
keyword: "test_point_set",
|
|
10114
10229
|
field: "testPointSets",
|
|
10115
10230
|
takesID: !0,
|
|
10116
|
-
parse:
|
|
10117
|
-
dump:
|
|
10231
|
+
parse: ga,
|
|
10232
|
+
dump: _a
|
|
10118
10233
|
}),
|
|
10119
10234
|
J({
|
|
10120
10235
|
keyword: "common_test_condition",
|
|
10121
10236
|
field: "commonTestConditions",
|
|
10122
10237
|
takesID: !0,
|
|
10123
|
-
parse:
|
|
10124
|
-
dump:
|
|
10238
|
+
parse: va,
|
|
10239
|
+
dump: ya
|
|
10125
10240
|
}),
|
|
10126
10241
|
J({
|
|
10127
10242
|
keyword: "competence_kind",
|
|
@@ -10134,36 +10249,36 @@ var Wl = [
|
|
|
10134
10249
|
keyword: "scheme_activity_kind",
|
|
10135
10250
|
field: "schemeActivityKinds",
|
|
10136
10251
|
takesID: !0,
|
|
10137
|
-
parse:
|
|
10138
|
-
dump:
|
|
10252
|
+
parse: ea,
|
|
10253
|
+
dump: ia
|
|
10139
10254
|
}),
|
|
10140
10255
|
J({
|
|
10141
10256
|
keyword: "scheme_type",
|
|
10142
10257
|
field: "schemeTypes",
|
|
10143
10258
|
takesID: !0,
|
|
10144
|
-
parse:
|
|
10145
|
-
dump:
|
|
10259
|
+
parse: na,
|
|
10260
|
+
dump: aa
|
|
10146
10261
|
}),
|
|
10147
10262
|
J({
|
|
10148
10263
|
keyword: "predicate",
|
|
10149
10264
|
field: "predicates",
|
|
10150
10265
|
takesID: !0,
|
|
10151
|
-
parse:
|
|
10152
|
-
dump:
|
|
10266
|
+
parse: oa,
|
|
10267
|
+
dump: sa
|
|
10153
10268
|
}),
|
|
10154
10269
|
J({
|
|
10155
10270
|
keyword: "constraint",
|
|
10156
10271
|
field: "constraints",
|
|
10157
10272
|
takesID: !0,
|
|
10158
|
-
parse:
|
|
10159
|
-
dump:
|
|
10273
|
+
parse: la,
|
|
10274
|
+
dump: ua
|
|
10160
10275
|
}),
|
|
10161
10276
|
J({
|
|
10162
10277
|
keyword: "discrepancy_record",
|
|
10163
10278
|
field: "discrepancyRecords",
|
|
10164
10279
|
takesID: !0,
|
|
10165
|
-
parse:
|
|
10166
|
-
dump:
|
|
10280
|
+
parse: fa,
|
|
10281
|
+
dump: pa
|
|
10167
10282
|
}),
|
|
10168
10283
|
J({
|
|
10169
10284
|
keyword: "state_machine",
|
|
@@ -10172,20 +10287,20 @@ var Wl = [
|
|
|
10172
10287
|
parse: Hr,
|
|
10173
10288
|
dump: Gr
|
|
10174
10289
|
}),
|
|
10175
|
-
|
|
10176
|
-
|
|
10177
|
-
|
|
10178
|
-
|
|
10179
|
-
|
|
10180
|
-
|
|
10181
|
-
|
|
10182
|
-
|
|
10290
|
+
ka,
|
|
10291
|
+
Aa,
|
|
10292
|
+
ts,
|
|
10293
|
+
ns,
|
|
10294
|
+
rs,
|
|
10295
|
+
is,
|
|
10296
|
+
as,
|
|
10297
|
+
Ia,
|
|
10183
10298
|
J({
|
|
10184
10299
|
keyword: "conformance_test",
|
|
10185
10300
|
field: "conformanceTests",
|
|
10186
10301
|
takesID: !0,
|
|
10187
|
-
parse:
|
|
10188
|
-
dump:
|
|
10302
|
+
parse: Ii,
|
|
10303
|
+
dump: Li
|
|
10189
10304
|
}),
|
|
10190
10305
|
J({
|
|
10191
10306
|
keyword: "verification_pathway",
|
|
@@ -10215,177 +10330,177 @@ var Wl = [
|
|
|
10215
10330
|
parse: nn,
|
|
10216
10331
|
dump: rn
|
|
10217
10332
|
}),
|
|
10218
|
-
|
|
10333
|
+
os,
|
|
10219
10334
|
J({
|
|
10220
10335
|
keyword: "identity_slot",
|
|
10221
10336
|
field: "identitySlots",
|
|
10222
10337
|
takesID: !0,
|
|
10223
|
-
parse:
|
|
10224
|
-
dump:
|
|
10338
|
+
parse: vs,
|
|
10339
|
+
dump: ys
|
|
10225
10340
|
}),
|
|
10226
10341
|
J({
|
|
10227
10342
|
keyword: "aspect",
|
|
10228
10343
|
field: "aspects",
|
|
10229
10344
|
takesID: !0,
|
|
10230
|
-
parse:
|
|
10231
|
-
dump:
|
|
10345
|
+
parse: xs,
|
|
10346
|
+
dump: Ss
|
|
10232
10347
|
}),
|
|
10233
10348
|
J({
|
|
10234
10349
|
keyword: "promise_set",
|
|
10235
10350
|
field: "promiseSets",
|
|
10236
10351
|
takesID: !0,
|
|
10237
|
-
parse:
|
|
10238
|
-
dump:
|
|
10352
|
+
parse: Cs,
|
|
10353
|
+
dump: ws
|
|
10239
10354
|
}),
|
|
10240
10355
|
J({
|
|
10241
10356
|
keyword: "application_declaration",
|
|
10242
10357
|
field: "applicationDeclarations",
|
|
10243
10358
|
takesID: !0,
|
|
10244
|
-
parse:
|
|
10245
|
-
dump:
|
|
10359
|
+
parse: Es,
|
|
10360
|
+
dump: Ds
|
|
10246
10361
|
}),
|
|
10247
|
-
|
|
10248
|
-
|
|
10249
|
-
|
|
10250
|
-
|
|
10251
|
-
|
|
10362
|
+
hs,
|
|
10363
|
+
Zs,
|
|
10364
|
+
Qs,
|
|
10365
|
+
jc,
|
|
10366
|
+
Mc,
|
|
10252
10367
|
J({
|
|
10253
10368
|
keyword: "activity_archetype",
|
|
10254
10369
|
field: "activityArchetypes",
|
|
10255
10370
|
takesID: !0,
|
|
10256
|
-
parse:
|
|
10257
|
-
dump:
|
|
10371
|
+
parse: zc,
|
|
10372
|
+
dump: Bc
|
|
10258
10373
|
}),
|
|
10259
10374
|
J({
|
|
10260
10375
|
keyword: "participant_kind",
|
|
10261
10376
|
field: "participantKinds",
|
|
10262
10377
|
takesID: !0,
|
|
10263
|
-
parse:
|
|
10264
|
-
dump:
|
|
10378
|
+
parse: Wc,
|
|
10379
|
+
dump: Jc
|
|
10265
10380
|
}),
|
|
10266
10381
|
J({
|
|
10267
10382
|
keyword: "governance_organ",
|
|
10268
10383
|
field: "governanceOrgans",
|
|
10269
10384
|
takesID: !0,
|
|
10270
|
-
parse:
|
|
10271
|
-
dump:
|
|
10385
|
+
parse: Yc,
|
|
10386
|
+
dump: Xc
|
|
10272
10387
|
}),
|
|
10273
10388
|
J({
|
|
10274
10389
|
keyword: "declaration_kind",
|
|
10275
10390
|
field: "declarationKinds",
|
|
10276
10391
|
takesID: !0,
|
|
10277
|
-
parse:
|
|
10278
|
-
dump:
|
|
10392
|
+
parse: Qc,
|
|
10393
|
+
dump: tl
|
|
10279
10394
|
}),
|
|
10280
10395
|
J({
|
|
10281
10396
|
keyword: "declaration_status",
|
|
10282
10397
|
field: "declarationStatuses",
|
|
10283
10398
|
takesID: !0,
|
|
10284
|
-
parse:
|
|
10285
|
-
dump:
|
|
10399
|
+
parse: nl,
|
|
10400
|
+
dump: rl
|
|
10286
10401
|
}),
|
|
10287
10402
|
J({
|
|
10288
10403
|
keyword: "declaration_gate",
|
|
10289
10404
|
field: "declarationGates",
|
|
10290
10405
|
takesID: !0,
|
|
10291
|
-
parse:
|
|
10292
|
-
dump:
|
|
10406
|
+
parse: il,
|
|
10407
|
+
dump: al
|
|
10293
10408
|
}),
|
|
10294
10409
|
J({
|
|
10295
10410
|
keyword: "scheme_definition",
|
|
10296
10411
|
field: "schemeDefinitions",
|
|
10297
10412
|
takesID: !0,
|
|
10298
|
-
parse:
|
|
10299
|
-
dump:
|
|
10413
|
+
parse: sl,
|
|
10414
|
+
dump: ll
|
|
10300
10415
|
}),
|
|
10301
10416
|
J({
|
|
10302
10417
|
keyword: "scheme_lifecycle",
|
|
10303
10418
|
field: "schemeLifecycles",
|
|
10304
10419
|
takesID: !0,
|
|
10305
|
-
parse:
|
|
10306
|
-
dump:
|
|
10420
|
+
parse: pl,
|
|
10421
|
+
dump: ml
|
|
10307
10422
|
}),
|
|
10308
10423
|
J({
|
|
10309
10424
|
keyword: "framework_document",
|
|
10310
10425
|
field: "frameworkDocuments",
|
|
10311
10426
|
takesID: !0,
|
|
10312
|
-
parse:
|
|
10313
|
-
dump:
|
|
10427
|
+
parse: gl,
|
|
10428
|
+
dump: _l
|
|
10314
10429
|
}),
|
|
10315
10430
|
J({
|
|
10316
10431
|
keyword: "document_precedence",
|
|
10317
10432
|
field: "documentPrecedences",
|
|
10318
10433
|
takesID: !0,
|
|
10319
|
-
parse:
|
|
10320
|
-
dump:
|
|
10434
|
+
parse: vl,
|
|
10435
|
+
dump: yl
|
|
10321
10436
|
}),
|
|
10322
10437
|
J({
|
|
10323
10438
|
keyword: "auto_inclusion",
|
|
10324
10439
|
field: "autoInclusions",
|
|
10325
10440
|
takesID: !0,
|
|
10326
|
-
parse:
|
|
10327
|
-
dump:
|
|
10441
|
+
parse: xl,
|
|
10442
|
+
dump: Sl
|
|
10328
10443
|
}),
|
|
10329
10444
|
J({
|
|
10330
10445
|
keyword: "decision_rule",
|
|
10331
10446
|
field: "decisionRules",
|
|
10332
10447
|
takesID: !0,
|
|
10333
|
-
parse:
|
|
10334
|
-
dump:
|
|
10448
|
+
parse: Ol,
|
|
10449
|
+
dump: Ml
|
|
10335
10450
|
}),
|
|
10336
10451
|
J({
|
|
10337
10452
|
keyword: "document_module",
|
|
10338
10453
|
field: "documentModules",
|
|
10339
10454
|
takesID: !0,
|
|
10340
|
-
parse:
|
|
10341
|
-
dump:
|
|
10455
|
+
parse: Nl,
|
|
10456
|
+
dump: Pl
|
|
10342
10457
|
}),
|
|
10343
10458
|
J({
|
|
10344
10459
|
keyword: "informative_annex",
|
|
10345
10460
|
field: "informativeAnnexes",
|
|
10346
10461
|
takesID: !0,
|
|
10347
|
-
parse:
|
|
10348
|
-
dump:
|
|
10462
|
+
parse: Rl,
|
|
10463
|
+
dump: zl
|
|
10349
10464
|
}),
|
|
10350
10465
|
J({
|
|
10351
10466
|
keyword: "part_annex",
|
|
10352
10467
|
field: "partAnnexes",
|
|
10353
10468
|
takesID: !0,
|
|
10354
|
-
parse:
|
|
10355
|
-
dump:
|
|
10469
|
+
parse: Vl,
|
|
10470
|
+
dump: Hl
|
|
10356
10471
|
}),
|
|
10357
10472
|
J({
|
|
10358
10473
|
keyword: "demo_world",
|
|
10359
10474
|
field: "demoWorlds",
|
|
10360
10475
|
takesID: !0,
|
|
10361
|
-
parse:
|
|
10362
|
-
dump:
|
|
10476
|
+
parse: ql,
|
|
10477
|
+
dump: Jl
|
|
10363
10478
|
}),
|
|
10364
10479
|
J({
|
|
10365
10480
|
keyword: "storyline",
|
|
10366
10481
|
field: "storylines",
|
|
10367
10482
|
takesID: !0,
|
|
10368
|
-
parse:
|
|
10369
|
-
dump:
|
|
10483
|
+
parse: Xl,
|
|
10484
|
+
dump: Zl
|
|
10370
10485
|
}),
|
|
10371
|
-
|
|
10372
|
-
nc,
|
|
10373
|
-
lc,
|
|
10486
|
+
Ja,
|
|
10374
10487
|
uc,
|
|
10375
|
-
|
|
10376
|
-
|
|
10488
|
+
_c,
|
|
10489
|
+
vc,
|
|
10490
|
+
bc,
|
|
10491
|
+
xc,
|
|
10377
10492
|
J({
|
|
10378
10493
|
keyword: "text",
|
|
10379
10494
|
field: "texts",
|
|
10380
10495
|
takesID: !0,
|
|
10381
|
-
parse:
|
|
10382
|
-
dump:
|
|
10496
|
+
parse: Sc,
|
|
10497
|
+
dump: Cc
|
|
10383
10498
|
}),
|
|
10384
|
-
|
|
10385
|
-
|
|
10386
|
-
|
|
10499
|
+
Fc,
|
|
10500
|
+
Lc,
|
|
10501
|
+
Rc
|
|
10387
10502
|
];
|
|
10388
|
-
function
|
|
10503
|
+
function $l(e) {
|
|
10389
10504
|
let t = {};
|
|
10390
10505
|
for (let n of e) {
|
|
10391
10506
|
if (!n.field) continue;
|
|
@@ -10399,61 +10514,61 @@ function Gl(e) {
|
|
|
10399
10514
|
}
|
|
10400
10515
|
return t;
|
|
10401
10516
|
}
|
|
10402
|
-
function
|
|
10517
|
+
function eu(e) {
|
|
10403
10518
|
let t = {};
|
|
10404
10519
|
for (let n of e) n.field && (t[n.field] = { resolve: n.resolve ?? ((e, t) => t) });
|
|
10405
10520
|
return t;
|
|
10406
10521
|
}
|
|
10407
|
-
function
|
|
10522
|
+
function tu(e) {
|
|
10408
10523
|
let t = {};
|
|
10409
10524
|
for (let n of e) n.field && (t[n.field] = n.dump);
|
|
10410
10525
|
return t;
|
|
10411
10526
|
}
|
|
10412
|
-
var
|
|
10413
|
-
package: { parse:
|
|
10527
|
+
var nu = {
|
|
10528
|
+
package: { parse: Pa },
|
|
10414
10529
|
root: { parse: (e) => (t) => (t.root = e.trim(), t) },
|
|
10415
10530
|
metadata: { parse: m },
|
|
10416
10531
|
version: { parse: () => (e) => e },
|
|
10417
|
-
|
|
10418
|
-
},
|
|
10532
|
+
...$l(Ql)
|
|
10533
|
+
}, ru = eu(Ql), iu = tu(Ql), Y = (/* @__PURE__ */ e(((e, t) => {
|
|
10419
10534
|
t.exports = {};
|
|
10420
|
-
})))(),
|
|
10421
|
-
function
|
|
10535
|
+
})))(), au = /^include\s+"([^"]+)"/gm, ou = /^[ \t]*(#|\/\/)/;
|
|
10536
|
+
function su(e, t = /* @__PURE__ */ new Set()) {
|
|
10422
10537
|
let n = (0, Y.resolve)(e);
|
|
10423
10538
|
if (t.has(n)) throw Error(`Include cycle detected: ${n} (chain: ${[...t, n].map((e) => e.split("/").pop()).join(" → ")})`);
|
|
10424
10539
|
if (t.add(n), !(0, Y.existsSync)(n)) throw Error(`Include file not found: ${n}`);
|
|
10425
10540
|
let r = (0, Y.readFileSync)(n, "utf8"), i = (0, Y.dirname)(n);
|
|
10426
|
-
return r.replace(
|
|
10541
|
+
return r.replace(au, (e, n, a) => {
|
|
10427
10542
|
let o = r.lastIndexOf("\n", a) + 1, s = r.slice(o, a);
|
|
10428
|
-
if (
|
|
10543
|
+
if (ou.test(s)) return e;
|
|
10429
10544
|
let c = (0, Y.isAbsolute)(n) ? n : (0, Y.resolve)(i, n);
|
|
10430
|
-
return
|
|
10545
|
+
return su(c.endsWith(".prl") || c.endsWith(".mmel") ? c : (0, Y.existsSync)(`${c}.prl`) ? `${c}.prl` : `${c}.mmel`, new Set(t));
|
|
10431
10546
|
});
|
|
10432
10547
|
}
|
|
10433
10548
|
//#endregion
|
|
10434
10549
|
//#region src/validate.ts
|
|
10435
|
-
function
|
|
10550
|
+
function cu(e) {
|
|
10436
10551
|
let t = [];
|
|
10437
|
-
for (let n of
|
|
10552
|
+
for (let n of lu) t.push(...n.check(e));
|
|
10438
10553
|
return t;
|
|
10439
10554
|
}
|
|
10440
|
-
var
|
|
10555
|
+
var lu = [
|
|
10441
10556
|
{
|
|
10442
10557
|
name: "empty-ids",
|
|
10443
|
-
check:
|
|
10558
|
+
check: uu
|
|
10444
10559
|
},
|
|
10445
10560
|
{
|
|
10446
10561
|
name: "form-references",
|
|
10447
|
-
check:
|
|
10562
|
+
check: du
|
|
10448
10563
|
},
|
|
10449
10564
|
{
|
|
10450
10565
|
name: "state-machine-cascades",
|
|
10451
|
-
check:
|
|
10566
|
+
check: fu
|
|
10452
10567
|
}
|
|
10453
10568
|
];
|
|
10454
|
-
function
|
|
10569
|
+
function uu(e) {
|
|
10455
10570
|
let t = [];
|
|
10456
|
-
for (let [n, r] of
|
|
10571
|
+
for (let [n, r] of pu(e)) for (let e of r) (!e.id || e.id.trim() === "") && t.push({
|
|
10457
10572
|
severity: "error",
|
|
10458
10573
|
code: "empty-id",
|
|
10459
10574
|
construct: n,
|
|
@@ -10461,7 +10576,7 @@ function nu(e) {
|
|
|
10461
10576
|
});
|
|
10462
10577
|
return t;
|
|
10463
10578
|
}
|
|
10464
|
-
function
|
|
10579
|
+
function du(e) {
|
|
10465
10580
|
let t = [], n = new Set(e.calculations.map((e) => e.id)), r = new Set(e.processes.map((e) => e.id));
|
|
10466
10581
|
for (let t of e.conformanceTests ?? []) r.add(t.id);
|
|
10467
10582
|
let i = new Set(e.subforms.map((e) => e.id));
|
|
@@ -10473,7 +10588,7 @@ function ru(e) {
|
|
|
10473
10588
|
message: `Form "${a.id}" references conformance process "${a.conformanceProcessId}" which does not exist`,
|
|
10474
10589
|
id: a.id
|
|
10475
10590
|
});
|
|
10476
|
-
for (let e of
|
|
10591
|
+
for (let e of mu(a)) {
|
|
10477
10592
|
let r = e.calculationId;
|
|
10478
10593
|
r && !r.startsWith("ocl{") && !n.has(r) && t.push({
|
|
10479
10594
|
severity: "error",
|
|
@@ -10492,7 +10607,7 @@ function ru(e) {
|
|
|
10492
10607
|
}
|
|
10493
10608
|
return t;
|
|
10494
10609
|
}
|
|
10495
|
-
function
|
|
10610
|
+
function fu(e) {
|
|
10496
10611
|
let t = [];
|
|
10497
10612
|
for (let n of e.stateMachines) {
|
|
10498
10613
|
let e = new Set(n.states.map((e) => e.name));
|
|
@@ -10513,10 +10628,10 @@ function iu(e) {
|
|
|
10513
10628
|
}
|
|
10514
10629
|
return t;
|
|
10515
10630
|
}
|
|
10516
|
-
function*
|
|
10631
|
+
function* pu(e) {
|
|
10517
10632
|
for (let [t, n] of Object.entries(e)) Array.isArray(n) && n.length > 0 && typeof n[0]?.id == "string" && (yield [t, n]);
|
|
10518
10633
|
}
|
|
10519
|
-
function*
|
|
10634
|
+
function* mu(e) {
|
|
10520
10635
|
let t = [...e.fields];
|
|
10521
10636
|
for (; t.length > 0;) {
|
|
10522
10637
|
let e = t.pop();
|
|
@@ -10525,7 +10640,7 @@ function* ou(e) {
|
|
|
10525
10640
|
}
|
|
10526
10641
|
//#endregion
|
|
10527
10642
|
//#region src/ser-des/package.ts
|
|
10528
|
-
var
|
|
10643
|
+
var hu = [
|
|
10529
10644
|
"model",
|
|
10530
10645
|
"entities",
|
|
10531
10646
|
"specification",
|
|
@@ -10533,23 +10648,23 @@ var su = [
|
|
|
10533
10648
|
"evaluation",
|
|
10534
10649
|
"framework"
|
|
10535
10650
|
];
|
|
10536
|
-
function
|
|
10651
|
+
function gu(e) {
|
|
10537
10652
|
let t = [];
|
|
10538
10653
|
if (!(0, Y.existsSync)(e)) return t;
|
|
10539
10654
|
for (let n of (0, Y.readdirSync)(e).sort()) {
|
|
10540
10655
|
let r = (0, Y.join)(e, n);
|
|
10541
|
-
(0, Y.statSync)(r).isDirectory() ? t.push(...
|
|
10656
|
+
(0, Y.statSync)(r).isDirectory() ? t.push(...gu(r)) : (n.endsWith(".prl") || n.endsWith(".mmel")) && t.push(r);
|
|
10542
10657
|
}
|
|
10543
10658
|
return t;
|
|
10544
10659
|
}
|
|
10545
|
-
function
|
|
10660
|
+
function _u(e) {
|
|
10546
10661
|
let t = (0, Y.resolve)(e), n = [], r = (0, Y.join)(t, "package.primmel");
|
|
10547
10662
|
(0, Y.existsSync)(r) && n.push({
|
|
10548
10663
|
path: r,
|
|
10549
10664
|
role: "manifest"
|
|
10550
10665
|
});
|
|
10551
10666
|
let i = [];
|
|
10552
|
-
for (let e of
|
|
10667
|
+
for (let e of hu) i.push(...gu((0, Y.join)(t, e)));
|
|
10553
10668
|
for (let e of (0, Y.readdirSync)(t).sort()) {
|
|
10554
10669
|
let n = (0, Y.join)(t, e);
|
|
10555
10670
|
(0, Y.statSync)(n).isFile() && (e.endsWith(".prl") || e.endsWith(".mmel")) && e !== "package.primmel" && e !== ".primmel-allowlist.prl" && i.push(n);
|
|
@@ -10561,10 +10676,10 @@ function lu(e) {
|
|
|
10561
10676
|
});
|
|
10562
10677
|
return n;
|
|
10563
10678
|
}
|
|
10564
|
-
function
|
|
10565
|
-
return
|
|
10679
|
+
function vu(e, t = {}) {
|
|
10680
|
+
return Eu(e, t).standard;
|
|
10566
10681
|
}
|
|
10567
|
-
function
|
|
10682
|
+
function yu(e, t) {
|
|
10568
10683
|
let n = /* @__PURE__ */ new Map(), r = [];
|
|
10569
10684
|
for (let i of t) {
|
|
10570
10685
|
let t = e.constructs[i.field]?.[i.id];
|
|
@@ -10580,37 +10695,37 @@ function du(e, t) {
|
|
|
10580
10695
|
unassigned: r
|
|
10581
10696
|
};
|
|
10582
10697
|
}
|
|
10583
|
-
function
|
|
10584
|
-
let n =
|
|
10698
|
+
function bu(e, t = {}) {
|
|
10699
|
+
let n = Eu(e, t, !0);
|
|
10585
10700
|
if (!n.provenance) throw Error("loadPackageWithProvenance: provenance not collected");
|
|
10586
10701
|
return {
|
|
10587
10702
|
...n,
|
|
10588
10703
|
provenance: n.provenance
|
|
10589
10704
|
};
|
|
10590
10705
|
}
|
|
10591
|
-
function
|
|
10706
|
+
function xu(e) {
|
|
10592
10707
|
let t = 0;
|
|
10593
10708
|
for (let n = 0; n < e.length; n++) e.charAt(n) === "\n" && t++;
|
|
10594
10709
|
return t;
|
|
10595
10710
|
}
|
|
10596
|
-
function
|
|
10711
|
+
function Su(e) {
|
|
10597
10712
|
let t = [], n = 0, r = 1;
|
|
10598
10713
|
for (let i of e) {
|
|
10599
10714
|
if (i.role !== "content") continue;
|
|
10600
|
-
let e =
|
|
10715
|
+
let e = su(i.path);
|
|
10601
10716
|
t.push({
|
|
10602
10717
|
path: i.path,
|
|
10603
10718
|
text: e,
|
|
10604
10719
|
start: n,
|
|
10605
10720
|
lineStart: r
|
|
10606
|
-
}), n += e.length + 2, r +=
|
|
10721
|
+
}), n += e.length + 2, r += xu(e) + 2;
|
|
10607
10722
|
}
|
|
10608
10723
|
return t;
|
|
10609
10724
|
}
|
|
10610
|
-
function
|
|
10725
|
+
function Cu(e) {
|
|
10611
10726
|
return e.map((e) => e.text).join("\n\n");
|
|
10612
10727
|
}
|
|
10613
|
-
function
|
|
10728
|
+
function wu(e, t, n) {
|
|
10614
10729
|
let r = {}, i = 0;
|
|
10615
10730
|
for (let a of e) {
|
|
10616
10731
|
for (; i + 1 < t.length && a.start.offset >= t[i + 1].start;) i++;
|
|
@@ -10630,46 +10745,46 @@ function gu(e, t, n) {
|
|
|
10630
10745
|
}
|
|
10631
10746
|
return r;
|
|
10632
10747
|
}
|
|
10633
|
-
function
|
|
10748
|
+
function Tu(e) {
|
|
10634
10749
|
let t = (0, Y.join)((0, Y.resolve)(e), "package.primmel");
|
|
10635
10750
|
if (!(0, Y.existsSync)(t)) throw Error(`loadPackage: no package.primmel found in ${(0, Y.resolve)(e)}`);
|
|
10636
10751
|
let n = (0, Y.readFileSync)(t, "utf8"), r = { packageManifest: null };
|
|
10637
|
-
|
|
10752
|
+
Pa(n)(r);
|
|
10638
10753
|
let i = r.packageManifest;
|
|
10639
10754
|
if (!i || !i.id) throw Error(`loadPackage: ${t} is not a valid package manifest`);
|
|
10640
10755
|
return i;
|
|
10641
10756
|
}
|
|
10642
|
-
function
|
|
10643
|
-
let r =
|
|
10757
|
+
function Eu(e, t = {}, n = !1) {
|
|
10758
|
+
let r = _u(e);
|
|
10644
10759
|
if (r.length === 0) throw Error(`loadPackage: no package files found in ${(0, Y.resolve)(e)}`);
|
|
10645
10760
|
let i = null;
|
|
10646
|
-
r.some((e) => e.role === "manifest") && (i =
|
|
10647
|
-
let a =
|
|
10648
|
-
if (i && t.resolvePackage &&
|
|
10761
|
+
r.some((e) => e.role === "manifest") && (i = Tu(e));
|
|
10762
|
+
let a = Su(r);
|
|
10763
|
+
if (i && t.resolvePackage && Ou(i).length > 0) return Fu(e, t, i, n);
|
|
10649
10764
|
let o = n ? {
|
|
10650
10765
|
...t,
|
|
10651
10766
|
withProvenance: !0
|
|
10652
|
-
} : t, s = u(
|
|
10767
|
+
} : t, s = u(Cu(a), nu, o);
|
|
10653
10768
|
if (i) {
|
|
10654
10769
|
s.packageManifest = i;
|
|
10655
|
-
let e =
|
|
10770
|
+
let e = ku(i);
|
|
10656
10771
|
e && s.issues.push(e);
|
|
10657
10772
|
}
|
|
10658
10773
|
let c = {
|
|
10659
|
-
standard: p(s,
|
|
10774
|
+
standard: p(s, ru),
|
|
10660
10775
|
issues: s.issues
|
|
10661
10776
|
};
|
|
10662
10777
|
if (n) {
|
|
10663
10778
|
let e = r.find((e) => e.role === "manifest")?.path;
|
|
10664
10779
|
c.provenance = {
|
|
10665
10780
|
...e === void 0 ? {} : { manifest: e },
|
|
10666
|
-
constructs:
|
|
10781
|
+
constructs: wu(s.constructs ?? [], a, i?.id)
|
|
10667
10782
|
};
|
|
10668
10783
|
}
|
|
10669
10784
|
return c;
|
|
10670
10785
|
}
|
|
10671
|
-
function
|
|
10672
|
-
return
|
|
10786
|
+
function Du(e, t = {}) {
|
|
10787
|
+
return Eu(e, t);
|
|
10673
10788
|
}
|
|
10674
10789
|
var X = class extends Error {
|
|
10675
10790
|
rule;
|
|
@@ -10677,12 +10792,12 @@ var X = class extends Error {
|
|
|
10677
10792
|
super(t), this.rule = e, this.name = "CompositionError";
|
|
10678
10793
|
}
|
|
10679
10794
|
};
|
|
10680
|
-
function
|
|
10795
|
+
function Ou(e) {
|
|
10681
10796
|
let t = [];
|
|
10682
10797
|
for (let n of [...e.uses ?? [], ...e.extends ? [e.extends] : []]) t.includes(n) || t.push(n);
|
|
10683
10798
|
return t;
|
|
10684
10799
|
}
|
|
10685
|
-
function
|
|
10800
|
+
function ku(e) {
|
|
10686
10801
|
return e.extends ? {
|
|
10687
10802
|
severity: "warning",
|
|
10688
10803
|
code: "extends-deprecated",
|
|
@@ -10691,47 +10806,47 @@ function xu(e) {
|
|
|
10691
10806
|
message: `package "${e.id}": 'extends ${e.extends}' is deprecated — declare 'uses { ${e.extends} }' instead (extends is treated as a single-entry uses)`
|
|
10692
10807
|
} : null;
|
|
10693
10808
|
}
|
|
10694
|
-
var
|
|
10695
|
-
function
|
|
10809
|
+
var Au = /* @__PURE__ */ "approvals.roles.processes.processModels.pages.gateways.regs.references.provisions.dataclasses.events.enums.variables.notes.tables.figures.links.mapProfiles.viewProfiles.terms.forms.subforms.symbols.formulaNotes.calculations.verdicts.referenceMaterials.testPointSets.commonTestConditions.competenceKinds.schemeActivityKinds.schemeTypes.constraints.discrepancyRecords.stateMachines.conformanceTests.conformanceClasses.requirements.requirementClasses.instruments.attributeDefinitions.capabilities.behaviors.conditionSets.subjects.identitySlots.aspects.promiseSets.applicationDeclarations.calculationContexts.evaluationDimensions.evaluationProfiles.certificateTemplates.workflowConfigs.workflowStages.verificationPathways.labSelectionCriteria.sampleSelectionRules.specimenGovernanceRules.testReportSkeletons.testReportChecklists.instances.quantityRegisters.duals.invariants.testSequences.formulasUsed.texts.participantKinds.governanceOrgans.declarationKinds.declarationStatuses.declarationGates.schemeDefinitions.schemeLifecycles.frameworkDocuments.documentPrecedences.autoInclusions.decisionRules.documentModules.informativeAnnexes.partAnnexes.demoWorlds.storylines.comments.predicates.artifactDefinitions.artifactInstances.activityArchetypes.connectorProfiles.monitors.passports.dataspaces.policies.dimensions".split("."), ju = /* @__PURE__ */ new Set(["workflowConfigs", "testReportChecklists"]);
|
|
10810
|
+
function Mu(e) {
|
|
10696
10811
|
return typeof e == "object" && !!e && !Array.isArray(e);
|
|
10697
10812
|
}
|
|
10698
|
-
function
|
|
10813
|
+
function Nu(e, t) {
|
|
10699
10814
|
if (Array.isArray(e) && Array.isArray(t)) {
|
|
10700
|
-
let n = (e) =>
|
|
10815
|
+
let n = (e) => Mu(e) && typeof e.id == "string", r = [...e, ...t];
|
|
10701
10816
|
if (r.length > 0 && r.every(n)) {
|
|
10702
10817
|
let e = [], t = /* @__PURE__ */ new Map();
|
|
10703
|
-
for (let n of r) t.has(n.id) ? t.set(n.id,
|
|
10818
|
+
for (let n of r) t.has(n.id) ? t.set(n.id, Nu(t.get(n.id), n)) : (e.push(n.id), t.set(n.id, n));
|
|
10704
10819
|
return e.map((e) => t.get(e));
|
|
10705
10820
|
}
|
|
10706
10821
|
let i = [...e];
|
|
10707
10822
|
for (let e of t) i.includes(e) || i.push(e);
|
|
10708
10823
|
return i;
|
|
10709
10824
|
}
|
|
10710
|
-
if (
|
|
10825
|
+
if (Mu(e) && Mu(t)) {
|
|
10711
10826
|
let n = { ...e };
|
|
10712
|
-
for (let [e, r] of Object.entries(t)) e !== "overlay" && r != null && (n[e] = e in n ?
|
|
10827
|
+
for (let [e, r] of Object.entries(t)) e !== "overlay" && r != null && (n[e] = e in n ? Nu(n[e], r) : r);
|
|
10713
10828
|
return n;
|
|
10714
10829
|
}
|
|
10715
10830
|
return t;
|
|
10716
10831
|
}
|
|
10717
|
-
function
|
|
10718
|
-
let n =
|
|
10832
|
+
function Pu(e, t) {
|
|
10833
|
+
let n = Su(_u(e));
|
|
10719
10834
|
return {
|
|
10720
|
-
ctx: u(
|
|
10835
|
+
ctx: u(Cu(n), nu, t),
|
|
10721
10836
|
chunks: n
|
|
10722
10837
|
};
|
|
10723
10838
|
}
|
|
10724
|
-
function
|
|
10839
|
+
function Fu(e, t, n, r = !1) {
|
|
10725
10840
|
let i = t.resolvePackage, a = n.id, o = /* @__PURE__ */ new Map([[a, (0, Y.resolve)(e)]]), s = /* @__PURE__ */ new Map([[a, n]]), c = [], l = /* @__PURE__ */ new Map(), u = [], d = (e) => {
|
|
10726
10841
|
l.set(e, 1), u.push(e);
|
|
10727
|
-
for (let t of
|
|
10842
|
+
for (let t of Ou(s.get(e))) {
|
|
10728
10843
|
let n = l.get(t) ?? 0;
|
|
10729
10844
|
if (n === 1) throw new X("uses-cycle", `uses cycle: ${[...u.slice(u.indexOf(t)), t].join(" → ")} — package composition must be acyclic (uses-cycle)`);
|
|
10730
10845
|
if (n !== 2) {
|
|
10731
10846
|
if (!o.has(t)) {
|
|
10732
10847
|
let n = i(t);
|
|
10733
10848
|
if (!n) throw new X("uses-resolves", `package "${e}" uses "${t}", which the package locator cannot resolve (uses-resolves)`);
|
|
10734
|
-
let r =
|
|
10849
|
+
let r = Tu(n);
|
|
10735
10850
|
if (r.id !== t) throw new X("uses-resolves", `package "${e}" uses "${t}", but the located package (${(0, Y.resolve)(n)}) declares id "${r.id}" (uses-resolves)`);
|
|
10736
10851
|
if (o.set(t, n), s.set(t, r), r.kind === "product_reference") {
|
|
10737
10852
|
l.set(t, 2);
|
|
@@ -10749,13 +10864,13 @@ function Du(e, t, n, r = !1) {
|
|
|
10749
10864
|
withProvenance: !0
|
|
10750
10865
|
} : t, m = /* @__PURE__ */ new Map(), h = /* @__PURE__ */ new Map();
|
|
10751
10866
|
for (let e of c) {
|
|
10752
|
-
let t =
|
|
10867
|
+
let t = Pu(o.get(e), f);
|
|
10753
10868
|
m.set(e, t.ctx), h.set(e, t.chunks);
|
|
10754
10869
|
}
|
|
10755
10870
|
let g = /* @__PURE__ */ new Map();
|
|
10756
|
-
for (let e of
|
|
10871
|
+
for (let e of Au) g.set(e, /* @__PURE__ */ new Map());
|
|
10757
10872
|
let _ = m.get(c[0]);
|
|
10758
|
-
for (let e of
|
|
10873
|
+
for (let e of Au) for (let t of Object.keys(_[e])) g.get(e).set(t, c[0]);
|
|
10759
10874
|
let v = /* @__PURE__ */ new Map(), y = (e, t) => {
|
|
10760
10875
|
for (let n of Object.values(t.documentModules)) n.namespace !== "" && !v.has(n.namespace) && v.set(n.namespace, e);
|
|
10761
10876
|
for (let n of Object.keys(t.requirementClasses)) v.has(n) || v.set(n, e);
|
|
@@ -10769,13 +10884,13 @@ function Du(e, t, n, r = !1) {
|
|
|
10769
10884
|
for (let e of c.slice(1)) {
|
|
10770
10885
|
let t = m.get(e);
|
|
10771
10886
|
b(e, t);
|
|
10772
|
-
for (let n of
|
|
10887
|
+
for (let n of Au) {
|
|
10773
10888
|
let r = _[n], i = g.get(n);
|
|
10774
10889
|
for (let [a, o] of Object.entries(t[n])) {
|
|
10775
10890
|
let t = i.get(a);
|
|
10776
10891
|
if (t !== void 0) {
|
|
10777
|
-
if (!(typeof o == "object" && o && o.overlay === !0 && (n === "terms" ||
|
|
10778
|
-
if (
|
|
10892
|
+
if (!(typeof o == "object" && o && o.overlay === !0 && (n === "terms" || ju.has(n)))) throw new X("uses-no-redefine", `package "${e}" redefines ${String(n)} id "${a}" already declared by package "${t}" — an overlay may reference upstream ids, never redefine them (uses-no-redefine)`);
|
|
10893
|
+
if (ju.has(n)) {
|
|
10779
10894
|
if (n === "testReportChecklists") {
|
|
10780
10895
|
let t = new Set((r[a].entries ?? []).map((e) => e.id));
|
|
10781
10896
|
for (let n of o.entries ?? []) t.has(n.id) || _.issues.push({
|
|
@@ -10786,7 +10901,7 @@ function Du(e, t, n, r = !1) {
|
|
|
10786
10901
|
message: `package "${e}" overlay test_report_checklist "${a}" declares entry "${n.id}", which no upstream package's checklist carries — an overlay adds rec-bound strings to an upstream entry, never a fresh entry (orphan-overlay-entry)`
|
|
10787
10902
|
});
|
|
10788
10903
|
}
|
|
10789
|
-
r[a] =
|
|
10904
|
+
r[a] = Nu(r[a], o), i.set(a, e);
|
|
10790
10905
|
continue;
|
|
10791
10906
|
}
|
|
10792
10907
|
}
|
|
@@ -10814,12 +10929,12 @@ function Du(e, t, n, r = !1) {
|
|
|
10814
10929
|
}
|
|
10815
10930
|
});
|
|
10816
10931
|
for (let e of s.values()) {
|
|
10817
|
-
let t =
|
|
10932
|
+
let t = ku(e);
|
|
10818
10933
|
t && x.push(t);
|
|
10819
10934
|
}
|
|
10820
10935
|
_.packageManifest = n;
|
|
10821
10936
|
let S = {
|
|
10822
|
-
standard: p(_,
|
|
10937
|
+
standard: p(_, ru),
|
|
10823
10938
|
issues: [..._.issues, ...x],
|
|
10824
10939
|
composition: {
|
|
10825
10940
|
root: a,
|
|
@@ -10829,7 +10944,7 @@ function Du(e, t, n, r = !1) {
|
|
|
10829
10944
|
if (r) {
|
|
10830
10945
|
let t = {};
|
|
10831
10946
|
for (let e of c) {
|
|
10832
|
-
let n =
|
|
10947
|
+
let n = wu(m.get(e).constructs ?? [], h.get(e), e);
|
|
10833
10948
|
for (let [e, r] of Object.entries(n)) {
|
|
10834
10949
|
let n = t[e] ??= {};
|
|
10835
10950
|
for (let [e, t] of Object.entries(r)) n[e] = t;
|
|
@@ -10844,7 +10959,7 @@ function Du(e, t, n, r = !1) {
|
|
|
10844
10959
|
}
|
|
10845
10960
|
//#endregion
|
|
10846
10961
|
//#region src/ser-des/prm.ts
|
|
10847
|
-
var
|
|
10962
|
+
var Iu = /* @__PURE__ */ new Set(["MMEL_MAP", "Primmel_MAP"]), Lu = /* @__PURE__ */ new Set([
|
|
10848
10963
|
"full",
|
|
10849
10964
|
"minimal",
|
|
10850
10965
|
"partial",
|
|
@@ -10853,7 +10968,7 @@ var Ou = /* @__PURE__ */ new Set(["MMEL_MAP", "Primmel_MAP"]), ku = /* @__PURE__
|
|
|
10853
10968
|
function Z(e) {
|
|
10854
10969
|
throw Error(`.prm parse error: ${e}`);
|
|
10855
10970
|
}
|
|
10856
|
-
function
|
|
10971
|
+
function Ru(e, t) {
|
|
10857
10972
|
let n = {
|
|
10858
10973
|
description: "",
|
|
10859
10974
|
justification: "",
|
|
@@ -10862,9 +10977,9 @@ function Au(e, t) {
|
|
|
10862
10977
|
if (e == null) return n;
|
|
10863
10978
|
(typeof e != "object" || Array.isArray(e)) && Z(`${t}: pair metadata must be an object`);
|
|
10864
10979
|
let r = e;
|
|
10865
|
-
return r.description !== void 0 && (typeof r.description != "string" && Z(`${t}: "description" must be a string`), n.description = r.description), r.justification !== void 0 && (typeof r.justification != "string" && Z(`${t}: "justification" must be a string`), n.justification = r.justification), r.coverage !== void 0 && ((typeof r.coverage != "string" || !
|
|
10980
|
+
return r.description !== void 0 && (typeof r.description != "string" && Z(`${t}: "description" must be a string`), n.description = r.description), r.justification !== void 0 && (typeof r.justification != "string" && Z(`${t}: "justification" must be a string`), n.justification = r.justification), r.coverage !== void 0 && ((typeof r.coverage != "string" || !Lu.has(r.coverage)) && Z(`${t}: "coverage" must be one of full | minimal | partial | none`), n.coverage = r.coverage), n;
|
|
10866
10981
|
}
|
|
10867
|
-
function
|
|
10982
|
+
function zu(e) {
|
|
10868
10983
|
let t;
|
|
10869
10984
|
try {
|
|
10870
10985
|
t = JSON.parse(e);
|
|
@@ -10873,7 +10988,7 @@ function ju(e) {
|
|
|
10873
10988
|
}
|
|
10874
10989
|
(typeof t != "object" || !t || Array.isArray(t)) && Z("top level must be an object");
|
|
10875
10990
|
let n = t, r = typeof n["@type"] == "string" ? n["@type"] : "";
|
|
10876
|
-
|
|
10991
|
+
Iu.has(r) || Z(`"@type" must be MMEL_MAP or Primmel_MAP (got "${r}")`);
|
|
10877
10992
|
let i = {
|
|
10878
10993
|
context: typeof n["@context"] == "string" ? n["@context"] : "",
|
|
10879
10994
|
type: r,
|
|
@@ -10889,20 +11004,20 @@ function ju(e) {
|
|
|
10889
11004
|
coverage: {}
|
|
10890
11005
|
}, a = n.coverage ?? {};
|
|
10891
11006
|
(typeof a != "object" || !a || Array.isArray(a)) && Z(`mapSet."${e}".coverage: must be an object`);
|
|
10892
|
-
for (let [t, n] of Object.entries(a)) (typeof n != "string" || !
|
|
11007
|
+
for (let [t, n] of Object.entries(a)) (typeof n != "string" || !Lu.has(n)) && Z(`mapSet."${e}".coverage."${t}": must be one of full | minimal | partial | none`), r.coverage[t] = n;
|
|
10893
11008
|
let o = n.mappings ?? {};
|
|
10894
11009
|
(typeof o != "object" || !o || Array.isArray(o)) && Z(`mapSet."${e}".mappings: must be an object`);
|
|
10895
11010
|
for (let [t, n] of Object.entries(o)) {
|
|
10896
11011
|
(typeof n != "object" || !n || Array.isArray(n)) && Z(`mapSet."${e}".mappings."${t}": must be an object`);
|
|
10897
11012
|
let i = {};
|
|
10898
|
-
for (let [r, a] of Object.entries(n)) i[r] =
|
|
11013
|
+
for (let [r, a] of Object.entries(n)) i[r] = Ru(a, `mapSet."${e}".mappings."${t}"."${r}"`);
|
|
10899
11014
|
r.mappings[t] = i;
|
|
10900
11015
|
}
|
|
10901
11016
|
i.mapSet[e] = r;
|
|
10902
11017
|
}
|
|
10903
11018
|
return i;
|
|
10904
11019
|
}
|
|
10905
|
-
function
|
|
11020
|
+
function Bu(e) {
|
|
10906
11021
|
let t = {};
|
|
10907
11022
|
e.context && (t["@context"] = e.context), t["@type"] = e.type || "Primmel_MAP", t.id = e.id;
|
|
10908
11023
|
let n = {};
|
|
@@ -10927,7 +11042,7 @@ function Mu(e) {
|
|
|
10927
11042
|
}
|
|
10928
11043
|
return t.mapSet = n, JSON.stringify(t, null, 2) + "\n";
|
|
10929
11044
|
}
|
|
10930
|
-
function
|
|
11045
|
+
function Vu(e) {
|
|
10931
11046
|
let t = [];
|
|
10932
11047
|
for (let [n, r] of Object.entries(e.mapSet)) {
|
|
10933
11048
|
let e = {};
|
|
@@ -10946,7 +11061,7 @@ function Nu(e) {
|
|
|
10946
11061
|
}
|
|
10947
11062
|
return t;
|
|
10948
11063
|
}
|
|
10949
|
-
function
|
|
11064
|
+
function Hu(e, t) {
|
|
10950
11065
|
let n = {
|
|
10951
11066
|
context: "",
|
|
10952
11067
|
type: "Primmel_MAP",
|
|
@@ -10974,7 +11089,7 @@ function Pu(e, t) {
|
|
|
10974
11089
|
}
|
|
10975
11090
|
//#endregion
|
|
10976
11091
|
//#region src/type-expr.ts
|
|
10977
|
-
var
|
|
11092
|
+
var Uu = [
|
|
10978
11093
|
"integer",
|
|
10979
11094
|
"float",
|
|
10980
11095
|
"double",
|
|
@@ -10989,8 +11104,8 @@ var Fu = [
|
|
|
10989
11104
|
"reference",
|
|
10990
11105
|
"object",
|
|
10991
11106
|
"any"
|
|
10992
|
-
],
|
|
10993
|
-
function
|
|
11107
|
+
], Wu = /^[A-Za-z_][A-Za-z0-9_-]*$/;
|
|
11108
|
+
function Gu(e) {
|
|
10994
11109
|
let t = 0;
|
|
10995
11110
|
for (let n = 0; n < e.length; n++) {
|
|
10996
11111
|
let r = e[n];
|
|
@@ -11000,33 +11115,33 @@ function Lu(e) {
|
|
|
11000
11115
|
}
|
|
11001
11116
|
return null;
|
|
11002
11117
|
}
|
|
11003
|
-
function
|
|
11118
|
+
function Ku(e) {
|
|
11004
11119
|
let t = e.trim();
|
|
11005
11120
|
if (t === "QuantityValue") return { kind: "quantity" };
|
|
11006
|
-
if (
|
|
11121
|
+
if (Uu.includes(t)) return {
|
|
11007
11122
|
kind: "primitive",
|
|
11008
11123
|
name: t
|
|
11009
11124
|
};
|
|
11010
11125
|
let n = /^reference\(([^)]+)\)$/.exec(t);
|
|
11011
11126
|
if (n) {
|
|
11012
11127
|
let e = n[1].trim();
|
|
11013
|
-
return
|
|
11128
|
+
return Wu.test(e) ? {
|
|
11014
11129
|
kind: "reference",
|
|
11015
11130
|
target: e
|
|
11016
11131
|
} : null;
|
|
11017
11132
|
}
|
|
11018
11133
|
if (t.startsWith("map<") && t.endsWith(">")) {
|
|
11019
|
-
let e =
|
|
11134
|
+
let e = Gu(t.slice(4, -1));
|
|
11020
11135
|
if (!e) return null;
|
|
11021
11136
|
let n = e[0].trim(), r = null;
|
|
11022
11137
|
n === "string" ? r = {
|
|
11023
11138
|
kind: "primitive",
|
|
11024
11139
|
name: "string"
|
|
11025
|
-
} :
|
|
11140
|
+
} : Wu.test(n) && (r = {
|
|
11026
11141
|
kind: "reference",
|
|
11027
11142
|
target: n
|
|
11028
11143
|
});
|
|
11029
|
-
let i =
|
|
11144
|
+
let i = Ku(e[1]);
|
|
11030
11145
|
return !r || !i ? null : {
|
|
11031
11146
|
kind: "map",
|
|
11032
11147
|
key: r,
|
|
@@ -11035,13 +11150,13 @@ function Ru(e) {
|
|
|
11035
11150
|
}
|
|
11036
11151
|
return null;
|
|
11037
11152
|
}
|
|
11038
|
-
function
|
|
11039
|
-
let t =
|
|
11153
|
+
function qu(e) {
|
|
11154
|
+
let t = Ku(e);
|
|
11040
11155
|
return t !== null && t.kind === "map";
|
|
11041
11156
|
}
|
|
11042
11157
|
//#endregion
|
|
11043
11158
|
//#region src/mapping-coverage.ts
|
|
11044
|
-
function
|
|
11159
|
+
function Ju(e, t) {
|
|
11045
11160
|
let n = e.indexOf("#");
|
|
11046
11161
|
if (n >= 0) {
|
|
11047
11162
|
let t = e.slice(0, n), r = e.slice(n + 1);
|
|
@@ -11057,12 +11172,12 @@ function Bu(e, t) {
|
|
|
11057
11172
|
qualified: t + "#" + e
|
|
11058
11173
|
};
|
|
11059
11174
|
}
|
|
11060
|
-
function
|
|
11175
|
+
function Yu(e, t) {
|
|
11061
11176
|
let n = [];
|
|
11062
11177
|
for (let [r, i] of Object.entries(e.mappings)) for (let a of i) n.push({
|
|
11063
11178
|
source: r,
|
|
11064
11179
|
sourceModel: t,
|
|
11065
|
-
target:
|
|
11180
|
+
target: Ju(a.target, e.namespace).qualified,
|
|
11066
11181
|
targetModel: e.namespace,
|
|
11067
11182
|
description: a.description,
|
|
11068
11183
|
justification: a.justification,
|
|
@@ -11070,12 +11185,12 @@ function Vu(e, t) {
|
|
|
11070
11185
|
});
|
|
11071
11186
|
return n;
|
|
11072
11187
|
}
|
|
11073
|
-
function
|
|
11188
|
+
function Xu(e, t = {}) {
|
|
11074
11189
|
let n = t.modelId ?? e.packageManifest?.id ?? e.meta?.namespace ?? "", r = [...e.mapProfiles ?? []], i = t.prm ? Array.isArray(t.prm) ? t.prm : [t.prm] : [];
|
|
11075
|
-
for (let e of i) r.push(...
|
|
11076
|
-
return r.flatMap((e) =>
|
|
11190
|
+
for (let e of i) r.push(...Vu(e));
|
|
11191
|
+
return r.flatMap((e) => Yu(e, n));
|
|
11077
11192
|
}
|
|
11078
|
-
function
|
|
11193
|
+
function Zu(e, t = {}) {
|
|
11079
11194
|
let n = t.idPrefix ?? "", r = (e.processes ?? []).filter((e) => !n || e.id.startsWith(n)), i = new Set(r.map((e) => e.id)), a = /* @__PURE__ */ new Map();
|
|
11080
11195
|
for (let e of r) a.set(e.id, {
|
|
11081
11196
|
id: e.id.slice(n.length),
|
|
@@ -11089,18 +11204,18 @@ function Uu(e, t = {}) {
|
|
|
11089
11204
|
}
|
|
11090
11205
|
return o;
|
|
11091
11206
|
}
|
|
11092
|
-
function
|
|
11207
|
+
function Qu(e, t) {
|
|
11093
11208
|
return t.length === 0 ? "none" : t.every((e) => e === "full") ? "full" : e === "gateway" && t.some((e) => e === "full" || e === "minimal") ? "minimal" : t.some((e) => e !== "none") ? "partial" : "none";
|
|
11094
11209
|
}
|
|
11095
|
-
function
|
|
11096
|
-
let a = Array.isArray(t) ? t :
|
|
11210
|
+
function $u(e, t, n, r, i = {}) {
|
|
11211
|
+
let a = Array.isArray(t) ? t : Zu(t), o = n.filter((e) => e.targetModel === r), s = /* @__PURE__ */ new Map();
|
|
11097
11212
|
for (let e of o) {
|
|
11098
|
-
let t =
|
|
11213
|
+
let t = Ju(e.target, r).id;
|
|
11099
11214
|
(s.get(t) ?? s.set(t, []).get(t)).push(e.source);
|
|
11100
11215
|
}
|
|
11101
11216
|
let c = /* @__PURE__ */ new Map(), l = /* @__PURE__ */ new Map(), u = (e, t) => {
|
|
11102
11217
|
let n = s.has(e.id), r = n ? e.id : t, i = e.children.map((e) => u(e, r)), a;
|
|
11103
|
-
return r === null ? a = e.children.length === 0 ? "none" :
|
|
11218
|
+
return r === null ? a = e.children.length === 0 ? "none" : Qu(e.composition, i) : (a = "full", !n && t !== null && l.set(e.id, t)), c.set(e.id, a), a;
|
|
11104
11219
|
};
|
|
11105
11220
|
for (let e of a) u(e, null);
|
|
11106
11221
|
let d = [], f = /* @__PURE__ */ new Map(), p = (e) => {
|
|
@@ -11122,7 +11237,7 @@ function Gu(e, t, n, r, i = {}) {
|
|
|
11122
11237
|
for (let e of d) m[e.coverage]++;
|
|
11123
11238
|
let h = [], g = /* @__PURE__ */ new Set();
|
|
11124
11239
|
for (let e of o) {
|
|
11125
|
-
let t =
|
|
11240
|
+
let t = Ju(e.target, r).id;
|
|
11126
11241
|
f.has(t) ? g.add(e.source) : h.push({
|
|
11127
11242
|
source: e.source,
|
|
11128
11243
|
target: e.target
|
|
@@ -11133,7 +11248,7 @@ function Gu(e, t, n, r, i = {}) {
|
|
|
11133
11248
|
y.has(t) || (y.add(t), v.push(e));
|
|
11134
11249
|
};
|
|
11135
11250
|
for (let e of o) {
|
|
11136
|
-
let t =
|
|
11251
|
+
let t = Ju(e.target, r).id, n = f.get(t);
|
|
11137
11252
|
if (!n) continue;
|
|
11138
11253
|
let i = (e, t) => {
|
|
11139
11254
|
for (let n of e.children) t.push(n), i(n, t);
|
|
@@ -11180,7 +11295,7 @@ function Gu(e, t, n, r, i = {}) {
|
|
|
11180
11295
|
summary: m
|
|
11181
11296
|
};
|
|
11182
11297
|
}
|
|
11183
|
-
function
|
|
11298
|
+
function ed(e) {
|
|
11184
11299
|
let t = [], n = /* @__PURE__ */ new Set();
|
|
11185
11300
|
for (let r of e) for (let i of r.mappings) for (let r of e) if (r.modelId === i.targetModel) for (let e of r.mappings) {
|
|
11186
11301
|
if (i.target !== `${r.modelId}#${e.source}`) continue;
|
|
@@ -11198,7 +11313,7 @@ function Ku(e) {
|
|
|
11198
11313
|
}
|
|
11199
11314
|
return t;
|
|
11200
11315
|
}
|
|
11201
|
-
function
|
|
11316
|
+
function td(e) {
|
|
11202
11317
|
let t = /* @__PURE__ */ new Map();
|
|
11203
11318
|
for (let n of e) for (let e of n.mappings) {
|
|
11204
11319
|
let r = `${n.modelId}→${e.targetModel}`, i = t.get(r) ?? {
|
|
@@ -11210,14 +11325,14 @@ function qu(e) {
|
|
|
11210
11325
|
}
|
|
11211
11326
|
return [...t.values()];
|
|
11212
11327
|
}
|
|
11213
|
-
function
|
|
11328
|
+
function nd(e) {
|
|
11214
11329
|
if (e && typeof e == "object") {
|
|
11215
|
-
for (let t of Object.values(e))
|
|
11330
|
+
for (let t of Object.values(e)) nd(t);
|
|
11216
11331
|
Object.freeze(e);
|
|
11217
11332
|
}
|
|
11218
11333
|
return e;
|
|
11219
11334
|
}
|
|
11220
|
-
function
|
|
11335
|
+
function rd(e, t, n = null) {
|
|
11221
11336
|
let r = new Set(t.visibleElements ?? []), i = r.size > 0, a = i ? [...r] : (e.processes ?? []).map((e) => e.id), o = null;
|
|
11222
11337
|
if (n) {
|
|
11223
11338
|
let e = n.components.filter((e) => !i || r.has(e.id) || e.mappedBy.some((e) => r.has(e))), t = {
|
|
@@ -11235,14 +11350,14 @@ function Yu(e, t, n = null) {
|
|
|
11235
11350
|
summary: t
|
|
11236
11351
|
};
|
|
11237
11352
|
}
|
|
11238
|
-
return
|
|
11353
|
+
return nd({
|
|
11239
11354
|
id: t.id,
|
|
11240
11355
|
against: t.against ?? "",
|
|
11241
11356
|
elements: a,
|
|
11242
11357
|
coverage: o
|
|
11243
11358
|
});
|
|
11244
11359
|
}
|
|
11245
|
-
function
|
|
11360
|
+
function id(e) {
|
|
11246
11361
|
let t = /* @__PURE__ */ new Set(), n = (e) => {
|
|
11247
11362
|
for (let n of e ?? []) t.add(n.id);
|
|
11248
11363
|
};
|
|
@@ -11259,13 +11374,13 @@ function Xu(e) {
|
|
|
11259
11374
|
}
|
|
11260
11375
|
//#endregion
|
|
11261
11376
|
//#region src/model-diff.ts
|
|
11262
|
-
var
|
|
11377
|
+
var ad = [
|
|
11263
11378
|
"foundations",
|
|
11264
11379
|
"primary",
|
|
11265
11380
|
"secondary",
|
|
11266
11381
|
"tertiary",
|
|
11267
11382
|
"cross-cutting"
|
|
11268
|
-
],
|
|
11383
|
+
], od = {
|
|
11269
11384
|
terms: "foundations",
|
|
11270
11385
|
references: "foundations",
|
|
11271
11386
|
roles: "foundations",
|
|
@@ -11354,9 +11469,9 @@ function Q(e) {
|
|
|
11354
11469
|
};
|
|
11355
11470
|
return n(e);
|
|
11356
11471
|
}
|
|
11357
|
-
var
|
|
11358
|
-
function
|
|
11359
|
-
let r = e ?? "", i = n ?? "", a =
|
|
11472
|
+
var sd = /#([^#]*)$/;
|
|
11473
|
+
function cd(e, t, n = "") {
|
|
11474
|
+
let r = e ?? "", i = n ?? "", a = sd.exec(r);
|
|
11360
11475
|
a && (r = r.slice(0, a.index), i ||= a[1]);
|
|
11361
11476
|
let o = r.lastIndexOf(":"), s = r, c = "";
|
|
11362
11477
|
if (o >= 0) {
|
|
@@ -11370,11 +11485,11 @@ function ed(e, t, n = "") {
|
|
|
11370
11485
|
fragment: i
|
|
11371
11486
|
};
|
|
11372
11487
|
}
|
|
11373
|
-
var
|
|
11488
|
+
var ld = [
|
|
11374
11489
|
"source",
|
|
11375
11490
|
"sourceRef",
|
|
11376
11491
|
"sourceRefs"
|
|
11377
|
-
],
|
|
11492
|
+
], ud = {
|
|
11378
11493
|
requirements: {
|
|
11379
11494
|
statement: [
|
|
11380
11495
|
"name",
|
|
@@ -11423,7 +11538,7 @@ var td = [
|
|
|
11423
11538
|
"profile"
|
|
11424
11539
|
]
|
|
11425
11540
|
}
|
|
11426
|
-
},
|
|
11541
|
+
}, dd = [
|
|
11427
11542
|
"name",
|
|
11428
11543
|
"label",
|
|
11429
11544
|
"title",
|
|
@@ -11432,16 +11547,16 @@ var td = [
|
|
|
11432
11547
|
"statement",
|
|
11433
11548
|
"purpose",
|
|
11434
11549
|
"text"
|
|
11435
|
-
],
|
|
11550
|
+
], fd = [
|
|
11436
11551
|
"parent",
|
|
11437
11552
|
"bindsTo",
|
|
11438
11553
|
"targets",
|
|
11439
11554
|
"conformanceProcessId",
|
|
11440
11555
|
"conformanceProcessIds"
|
|
11441
11556
|
];
|
|
11442
|
-
function
|
|
11557
|
+
function pd(e) {
|
|
11443
11558
|
let t = {}, n = (e, n) => {
|
|
11444
|
-
n && typeof n == "object" && (n.doc || n.clause) && (t[e] ??= []).push(
|
|
11559
|
+
n && typeof n == "object" && (n.doc || n.clause) && (t[e] ??= []).push(cd(n.doc ?? "", n.clause ?? "", n.fragment));
|
|
11445
11560
|
};
|
|
11446
11561
|
n("source", e.source), n("sourceRef", e.sourceRef);
|
|
11447
11562
|
for (let t of e.sourceRefs ?? []) n("sourceRefs", t);
|
|
@@ -11453,7 +11568,7 @@ function ad(e) {
|
|
|
11453
11568
|
let i = (e) => {
|
|
11454
11569
|
let t = /* @__PURE__ */ new Set();
|
|
11455
11570
|
return e.filter((e) => {
|
|
11456
|
-
let n =
|
|
11571
|
+
let n = md(e);
|
|
11457
11572
|
return !t.has(n) && (t.add(n), !0);
|
|
11458
11573
|
});
|
|
11459
11574
|
};
|
|
@@ -11463,17 +11578,17 @@ function ad(e) {
|
|
|
11463
11578
|
channels: t
|
|
11464
11579
|
};
|
|
11465
11580
|
}
|
|
11466
|
-
function
|
|
11581
|
+
function md(e) {
|
|
11467
11582
|
return Q({
|
|
11468
11583
|
basis: e.basis,
|
|
11469
11584
|
clause: e.clause,
|
|
11470
11585
|
fragment: e.fragment
|
|
11471
11586
|
});
|
|
11472
11587
|
}
|
|
11473
|
-
function
|
|
11474
|
-
let n = String(t.id ?? t.entityName ?? ""), r =
|
|
11588
|
+
function hd(e, t) {
|
|
11589
|
+
let n = String(t.id ?? t.entityName ?? ""), r = od[e] ?? "cross-cutting", { edges: i, channels: a } = pd(t), o = new Set(ld);
|
|
11475
11590
|
typeof t.reference == "string" && t.reference.startsWith("urn:") && o.add("reference");
|
|
11476
|
-
let s = {}, c = {}, l =
|
|
11591
|
+
let s = {}, c = {}, l = ud[e], u = (e) => {
|
|
11477
11592
|
let n = {};
|
|
11478
11593
|
for (let r of e) t[r] !== void 0 && (n[r] = t[r], o.add(r), s[r] = t[r]);
|
|
11479
11594
|
return n;
|
|
@@ -11493,9 +11608,9 @@ function sd(e, t) {
|
|
|
11493
11608
|
c[`spelling:${t.spelling}`] = Q(e), s[`spelling:${t.spelling}`] = e;
|
|
11494
11609
|
}
|
|
11495
11610
|
} else {
|
|
11496
|
-
let e = u(
|
|
11611
|
+
let e = u(dd);
|
|
11497
11612
|
Object.keys(e).length > 0 && (c.statement = Q(e));
|
|
11498
|
-
let t = u(
|
|
11613
|
+
let t = u(fd);
|
|
11499
11614
|
Object.keys(t).length > 0 && (c.anchor = Q(t));
|
|
11500
11615
|
}
|
|
11501
11616
|
if (i.length > 0) {
|
|
@@ -11522,31 +11637,31 @@ function sd(e, t) {
|
|
|
11522
11637
|
provenance: i
|
|
11523
11638
|
};
|
|
11524
11639
|
}
|
|
11525
|
-
function
|
|
11640
|
+
function gd(e, t) {
|
|
11526
11641
|
let n = /* @__PURE__ */ new Map();
|
|
11527
|
-
for (let r of Object.keys(
|
|
11642
|
+
for (let r of Object.keys(od)) {
|
|
11528
11643
|
let i = e[r];
|
|
11529
11644
|
if (Array.isArray(i)) {
|
|
11530
11645
|
for (let e of i) if (e && typeof e == "object" && ("id" in e || "entityName" in e)) {
|
|
11531
|
-
let i =
|
|
11646
|
+
let i = hd(r, e);
|
|
11532
11647
|
n.has(i.key) && t?.push(i.key), n.set(i.key, i);
|
|
11533
11648
|
}
|
|
11534
11649
|
}
|
|
11535
11650
|
}
|
|
11536
11651
|
return n;
|
|
11537
11652
|
}
|
|
11538
|
-
function
|
|
11653
|
+
function _d(e, t) {
|
|
11539
11654
|
return `${e}#${t}`;
|
|
11540
11655
|
}
|
|
11541
11656
|
function $(e) {
|
|
11542
11657
|
return e?.version ?? "";
|
|
11543
11658
|
}
|
|
11544
|
-
function
|
|
11659
|
+
function vd(e) {
|
|
11545
11660
|
let t = [...new Set(e)].sort();
|
|
11546
11661
|
return t.filter((e) => !t.some((t) => t !== e && e.startsWith(t + ".")));
|
|
11547
11662
|
}
|
|
11548
|
-
function
|
|
11549
|
-
let r = n.mappingsA ??
|
|
11663
|
+
function yd(e, t, n) {
|
|
11664
|
+
let r = n.mappingsA ?? Xu(e), i = n.mappingsB ?? Xu(t), a = (e) => `${e.sourceModel}#${e.source}⇒${e.target}`, o = new Map(r.map((e) => [a(e), e])), s = new Map(i.map((e) => [a(e), e])), c = [], l = [], u = [];
|
|
11550
11665
|
for (let [e, t] of s) o.has(e) || c.push(t);
|
|
11551
11666
|
for (let [e, t] of o) {
|
|
11552
11667
|
let n = s.get(e);
|
|
@@ -11567,7 +11682,7 @@ function dd(e, t, n) {
|
|
|
11567
11682
|
let o = (e) => {
|
|
11568
11683
|
let t = n.references?.[a];
|
|
11569
11684
|
if (t) return t;
|
|
11570
|
-
let r =
|
|
11685
|
+
let r = Zu(e, { idPrefix: `${a}#` });
|
|
11571
11686
|
return r.length > 0 ? r : null;
|
|
11572
11687
|
}, s = o(e), c = o(t);
|
|
11573
11688
|
if (!s && !c) {
|
|
@@ -11576,11 +11691,11 @@ function dd(e, t, n) {
|
|
|
11576
11691
|
}
|
|
11577
11692
|
let l = /* @__PURE__ */ new Map();
|
|
11578
11693
|
if (s) {
|
|
11579
|
-
let t =
|
|
11694
|
+
let t = $u(e, s, r, a);
|
|
11580
11695
|
for (let e of t.components) l.set(e.id, { from: e.coverage });
|
|
11581
11696
|
}
|
|
11582
11697
|
if (c) {
|
|
11583
|
-
let e =
|
|
11698
|
+
let e = $u(t, c, i, a);
|
|
11584
11699
|
for (let t of e.components) {
|
|
11585
11700
|
let e = l.get(t.id) ?? {};
|
|
11586
11701
|
e.to = t.coverage, l.set(t.id, e);
|
|
@@ -11604,12 +11719,12 @@ function dd(e, t, n) {
|
|
|
11604
11719
|
namespacesSkipped: p
|
|
11605
11720
|
};
|
|
11606
11721
|
}
|
|
11607
|
-
function
|
|
11722
|
+
function bd(e, t) {
|
|
11608
11723
|
let n = [];
|
|
11609
11724
|
for (let [t, r] of e) {
|
|
11610
11725
|
let e = /* @__PURE__ */ new Set([...t.provenance.map((e) => e.basis), ...r.provenance.map((e) => e.basis)]);
|
|
11611
11726
|
for (let i of [...e].sort()) {
|
|
11612
|
-
let e = (e) =>
|
|
11727
|
+
let e = (e) => vd(e.provenance.filter((e) => e.basis === i).map((e) => e.clause)).filter((e) => e.length > 0), a = e(t), o = e(r), s = a.filter((e) => !o.includes(e)), c = o.filter((e) => !a.includes(e));
|
|
11613
11728
|
if (s.length === 0 && c.length === 0) continue;
|
|
11614
11729
|
let l = {
|
|
11615
11730
|
key: t.key,
|
|
@@ -11659,7 +11774,7 @@ function fd(e, t) {
|
|
|
11659
11774
|
}
|
|
11660
11775
|
let r = (e) => {
|
|
11661
11776
|
if (e.kind !== "renumbered" || !t.sentencesA || !t.sentencesB) return "unavailable";
|
|
11662
|
-
let n = t.sentencesA.get(
|
|
11777
|
+
let n = t.sentencesA.get(_d(e.doc, e.from)), r = t.sentencesB.get(_d(e.doc, e.to));
|
|
11663
11778
|
return n === void 0 || r === void 0 ? "unavailable" : n.replace(/\s+/g, " ").trim() === r.replace(/\s+/g, " ").trim() ? "same" : "differed";
|
|
11664
11779
|
}, i = /* @__PURE__ */ new Map();
|
|
11665
11780
|
for (let e of n) {
|
|
@@ -11675,21 +11790,21 @@ function fd(e, t) {
|
|
|
11675
11790
|
}
|
|
11676
11791
|
return [...i.values()].sort((e, t) => `${e.doc} ${e.from} ${e.to}`.localeCompare(`${t.doc} ${t.from} ${t.to}`));
|
|
11677
11792
|
}
|
|
11678
|
-
function
|
|
11793
|
+
function xd(e, t, n) {
|
|
11679
11794
|
return e.kind !== "texts" || !n.startsWith("spelling:") ? n : n in e.aspects ? n in t.aspects ? `${n} (changed)` : `${n} (removed)` : `${n} (added)`;
|
|
11680
11795
|
}
|
|
11681
|
-
var
|
|
11682
|
-
function
|
|
11683
|
-
if (
|
|
11796
|
+
var Sd = (e) => typeof e == "object" && !!e && !Array.isArray(e);
|
|
11797
|
+
function Cd(e, t, n, r) {
|
|
11798
|
+
if (Sd(t) && Sd(n)) {
|
|
11684
11799
|
let i = [.../* @__PURE__ */ new Set([...Object.keys(t), ...Object.keys(n)])].sort();
|
|
11685
|
-
for (let a of i)
|
|
11800
|
+
for (let a of i) Cd(`${e}.${a}`, t[a], n[a], r);
|
|
11686
11801
|
return;
|
|
11687
11802
|
}
|
|
11688
11803
|
Q(t) !== Q(n) && r.push(e);
|
|
11689
11804
|
}
|
|
11690
|
-
function
|
|
11805
|
+
function wd(e, t) {
|
|
11691
11806
|
let n = [.../* @__PURE__ */ new Set([...Object.keys(e.fields), ...Object.keys(t.fields)])].sort(), r = [];
|
|
11692
|
-
for (let i of n)
|
|
11807
|
+
for (let i of n) Cd(i, e.fields[i], t.fields[i], r);
|
|
11693
11808
|
let i = [
|
|
11694
11809
|
"source",
|
|
11695
11810
|
"sourceRef",
|
|
@@ -11702,8 +11817,8 @@ function gd(e, t) {
|
|
|
11702
11817
|
return !a.has(r) && (a.add(r), !0);
|
|
11703
11818
|
});
|
|
11704
11819
|
}
|
|
11705
|
-
function
|
|
11706
|
-
let r = [], i = [], a =
|
|
11820
|
+
function Td(e, t, n = {}) {
|
|
11821
|
+
let r = [], i = [], a = gd(e, r), o = gd(t, i), s = [], c = [], l = [], u = [], d = [], f = 0, p = Object.fromEntries(ad.map((e) => [e, {
|
|
11707
11822
|
added: 0,
|
|
11708
11823
|
removed: 0,
|
|
11709
11824
|
changed: 0,
|
|
@@ -11741,11 +11856,11 @@ function _d(e, t, n = {}) {
|
|
|
11741
11856
|
id: t.id,
|
|
11742
11857
|
kind: t.kind,
|
|
11743
11858
|
tier: t.tier,
|
|
11744
|
-
aspects: r.map((e) =>
|
|
11745
|
-
fields:
|
|
11859
|
+
aspects: r.map((e) => xd(t, n, e)).sort(),
|
|
11860
|
+
fields: wd(t, n)
|
|
11746
11861
|
}), p[t.tier].changed++);
|
|
11747
11862
|
}
|
|
11748
|
-
let m =
|
|
11863
|
+
let m = yd(e, t, n), h = bd(d, n), g = s.length === 0 && c.length === 0 && l.length === 0 && u.length === 0 && m.added.length === 0 && m.removed.length === 0 && m.changed.length === 0 && m.coverageDelta.length === 0 && h.length === 0, _ = e.packageManifest, v = t.packageManifest, y = n.aLabel ?? (_?.id ? `${_.id}@${$(_) || "?"}` : "a"), b = n.bLabel ?? (v?.id ? `${v.id}@${$(v) || "?"}` : "b"), x = !!_?.id && _.id === v?.id && $(_) !== $(v), S = (e, t) => `${e}: duplicate element ${t} — the last declaration wins (a data error the duplicate-id linter owns); this side under-reports`, C = [...r.map((e) => S(y, e)), ...i.map((e) => S(b, e))];
|
|
11749
11864
|
return {
|
|
11750
11865
|
aLabel: y,
|
|
11751
11866
|
bLabel: b,
|
|
@@ -11764,40 +11879,40 @@ function _d(e, t, n = {}) {
|
|
|
11764
11879
|
empty: g
|
|
11765
11880
|
};
|
|
11766
11881
|
}
|
|
11767
|
-
function
|
|
11882
|
+
function Ed(e) {
|
|
11768
11883
|
return `[${e.tier}/${e.kind}] ${e.id}`;
|
|
11769
11884
|
}
|
|
11770
|
-
function
|
|
11885
|
+
function Dd(e, t) {
|
|
11771
11886
|
try {
|
|
11772
11887
|
let n = e ? JSON.parse(e) : {}, r = t ? JSON.parse(t) : {}, i = [.../* @__PURE__ */ new Set([...Object.keys(n), ...Object.keys(r)])].sort().filter((e) => Q(n[e]) !== Q(r[e])).map((e) => `${e}: ${Q(n[e])} → ${Q(r[e])}`);
|
|
11773
11888
|
if (i.length > 0) return i;
|
|
11774
11889
|
} catch {}
|
|
11775
11890
|
return [`from ${e}`, `to ${t}`];
|
|
11776
11891
|
}
|
|
11777
|
-
function
|
|
11892
|
+
function Od(e) {
|
|
11778
11893
|
let t = [], n = e.editionComparison ? `edition comparison — ${e.aLabel} → ${e.bLabel}` : `model diff — ${e.aLabel} → ${e.bLabel}`;
|
|
11779
11894
|
t.push(`primmel diff: ${n}`), t.push(""), t.push(`elements: +${e.added.length} -${e.removed.length} ~${e.changed.length} >${e.moved.length} (${e.unchanged} unchanged)`), t.push(""), t.push("by tier: added removed changed moved unchanged");
|
|
11780
|
-
for (let n of
|
|
11895
|
+
for (let n of ad) {
|
|
11781
11896
|
let r = e.byTier[n];
|
|
11782
11897
|
t.push(` ${n.padEnd(13)} ${String(r.added).padStart(5)} ${String(r.removed).padStart(8)} ${String(r.changed).padStart(8)} ${String(r.moved).padStart(6)} ${String(r.unchanged).padStart(9)}`);
|
|
11783
11898
|
}
|
|
11784
11899
|
if (e.added.length > 0) {
|
|
11785
11900
|
t.push("", "added:");
|
|
11786
|
-
for (let n of e.added) t.push(` + ${
|
|
11901
|
+
for (let n of e.added) t.push(` + ${Ed(n)}`);
|
|
11787
11902
|
}
|
|
11788
11903
|
if (e.removed.length > 0) {
|
|
11789
11904
|
t.push("", "removed:");
|
|
11790
|
-
for (let n of e.removed) t.push(` - ${
|
|
11905
|
+
for (let n of e.removed) t.push(` - ${Ed(n)}`);
|
|
11791
11906
|
}
|
|
11792
11907
|
if (e.changed.length > 0) {
|
|
11793
11908
|
t.push("", "changed:");
|
|
11794
|
-
for (let n of e.changed) t.push(` ~ ${
|
|
11909
|
+
for (let n of e.changed) t.push(` ~ ${Ed(n)} — ${n.aspects.join(", ")} (fields: ${n.fields.join(", ")})`);
|
|
11795
11910
|
}
|
|
11796
11911
|
if (e.moved.length > 0) {
|
|
11797
11912
|
t.push("", "moved (re-anchored):");
|
|
11798
11913
|
for (let n of e.moved) {
|
|
11799
|
-
t.push(` > ${
|
|
11800
|
-
for (let e of
|
|
11914
|
+
t.push(` > ${Ed(n)}`);
|
|
11915
|
+
for (let e of Dd(n.from, n.to)) t.push(` ${e}`);
|
|
11801
11916
|
}
|
|
11802
11917
|
}
|
|
11803
11918
|
if (e.warnings.length > 0) {
|
|
@@ -11822,27 +11937,27 @@ function bd(e) {
|
|
|
11822
11937
|
}
|
|
11823
11938
|
//#endregion
|
|
11824
11939
|
//#region src/ser-des/index.ts
|
|
11825
|
-
function
|
|
11826
|
-
return p(u(e,
|
|
11940
|
+
function kd(e, t = {}) {
|
|
11941
|
+
return p(u(e, nu, t), ru);
|
|
11827
11942
|
}
|
|
11828
|
-
function
|
|
11829
|
-
let n = u(e,
|
|
11943
|
+
function Ad(e, t = {}) {
|
|
11944
|
+
let n = u(e, nu, t);
|
|
11830
11945
|
return {
|
|
11831
|
-
standard: p(n,
|
|
11946
|
+
standard: p(n, ru),
|
|
11832
11947
|
issues: n.issues
|
|
11833
11948
|
};
|
|
11834
11949
|
}
|
|
11835
|
-
function
|
|
11836
|
-
return
|
|
11950
|
+
function jd(e, t = {}) {
|
|
11951
|
+
return kd(su(e), t);
|
|
11837
11952
|
}
|
|
11838
|
-
function
|
|
11839
|
-
return
|
|
11953
|
+
function Md(e, t = {}) {
|
|
11954
|
+
return Ad(su(e), t);
|
|
11840
11955
|
}
|
|
11841
|
-
function
|
|
11842
|
-
return qe(e,
|
|
11956
|
+
function Nd(e) {
|
|
11957
|
+
return qe(e, iu);
|
|
11843
11958
|
}
|
|
11844
|
-
function
|
|
11845
|
-
return
|
|
11959
|
+
function Pd(e) {
|
|
11960
|
+
return cu(e);
|
|
11846
11961
|
}
|
|
11847
11962
|
//#endregion
|
|
11848
|
-
export { X as CompositionError,
|
|
11963
|
+
export { X as CompositionError, Ra as ENDPOINT_ACCESS_SCOPES, La as ENDPOINT_OPERATION_KINDS, fc as PASSPORT_ACCESS_CLASSES, dc as PASSPORT_CONTENT_CLASSES, pc as PASSPORT_UPI_LEVELS, Uu as PRIMITIVE_TYPES, od as TIER_BY_FIELD, ad as TIER_ORDER, rd as applyView, Zu as buildProcessTree, Q as canonical, _d as clauseTextKey, Xu as collectMappings, id as componentIds, $u as computeCoverage, Td as diffStandards, ed as discoverTransitive, Nd as dump, Fa as dumpPackage, Bu as dumpPrm, Ou as effectiveUses, gd as elementIndex, Od as formatDiffReport, yu as groupBySourceFile, qu as isWellFormedMapType, kd as load, jd as loadFile, Md as loadFileWithIssues, vu as loadPackage, Du as loadPackageWithIssues, bu as loadPackageWithProvenance, zu as loadPrm, Ad as loadWithIssues, Hu as mapProfilesToPrm, Yu as mappingsFromProfile, cd as normalizeSourceRef, _u as packageFiles, Ju as parseTargetRef, Ku as parseTypeExpression, Vu as prmToMapProfiles, Tu as readPackageManifest, td as repoMap, Pd as validate };
|