@lionweb/validation 0.5.0-beta.8 → 0.5.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.
Files changed (157) hide show
  1. package/README.md +20 -21
  2. package/dist/diff/LionwebDiff.d.ts +40 -0
  3. package/dist/diff/LionwebDiff.d.ts.map +1 -0
  4. package/dist/diff/LionwebDiff.js +158 -0
  5. package/dist/diff/LionwebDiff.js.map +1 -0
  6. package/dist/index.d.ts +5 -0
  7. package/dist/index.d.ts.map +1 -0
  8. package/dist/index.js +5 -0
  9. package/dist/index.js.map +1 -0
  10. package/dist/issues/JsonContext.d.ts +11 -0
  11. package/dist/issues/JsonContext.d.ts.map +1 -0
  12. package/dist/issues/JsonContext.js +25 -0
  13. package/dist/issues/JsonContext.js.map +1 -0
  14. package/dist/issues/LanguageIssues.d.ts +75 -0
  15. package/dist/issues/LanguageIssues.d.ts.map +1 -0
  16. package/dist/issues/LanguageIssues.js +110 -0
  17. package/dist/issues/LanguageIssues.js.map +1 -0
  18. package/dist/issues/ReferenceIssues.d.ts +43 -0
  19. package/dist/issues/ReferenceIssues.d.ts.map +1 -0
  20. package/dist/issues/ReferenceIssues.js +53 -0
  21. package/dist/issues/ReferenceIssues.js.map +1 -0
  22. package/dist/issues/SyntaxIssues.d.ts +53 -0
  23. package/dist/issues/SyntaxIssues.d.ts.map +1 -0
  24. package/dist/issues/SyntaxIssues.js +81 -0
  25. package/dist/issues/SyntaxIssues.js.map +1 -0
  26. package/dist/issues/ValidationIssue.d.ts +9 -0
  27. package/dist/issues/ValidationIssue.d.ts.map +1 -0
  28. package/dist/issues/ValidationIssue.js +9 -0
  29. package/dist/issues/ValidationIssue.js.map +1 -0
  30. package/dist/issues/index.d.ts +6 -0
  31. package/dist/issues/index.d.ts.map +1 -0
  32. package/dist/issues/index.js +6 -0
  33. package/dist/issues/index.js.map +1 -0
  34. package/dist/json/ChunkUtils.d.ts +26 -0
  35. package/dist/json/ChunkUtils.d.ts.map +1 -0
  36. package/dist/json/ChunkUtils.js +46 -0
  37. package/dist/json/ChunkUtils.js.map +1 -0
  38. package/dist/json/LanguageUtils.d.ts +9 -0
  39. package/dist/json/LanguageUtils.d.ts.map +1 -0
  40. package/dist/json/LanguageUtils.js +30 -0
  41. package/dist/json/LanguageUtils.js.map +1 -0
  42. package/dist/json/LionWebJson.d.ts +56 -0
  43. package/dist/json/LionWebJson.d.ts.map +1 -0
  44. package/dist/json/LionWebJson.js +28 -0
  45. package/dist/json/LionWebJson.js.map +1 -0
  46. package/dist/json/LionWebJsonChunkWrapper.d.ts +25 -0
  47. package/dist/json/LionWebJsonChunkWrapper.d.ts.map +1 -0
  48. package/dist/json/LionWebJsonChunkWrapper.js +53 -0
  49. package/dist/json/LionWebJsonChunkWrapper.js.map +1 -0
  50. package/dist/json/LionWebLanguageDefinition.d.ts +48 -0
  51. package/dist/json/LionWebLanguageDefinition.d.ts.map +1 -0
  52. package/dist/json/LionWebLanguageDefinition.js +126 -0
  53. package/dist/json/LionWebLanguageDefinition.js.map +1 -0
  54. package/dist/json/NodeUtils.d.ts +26 -0
  55. package/dist/json/NodeUtils.d.ts.map +1 -0
  56. package/dist/json/NodeUtils.js +60 -0
  57. package/dist/json/NodeUtils.js.map +1 -0
  58. package/dist/json/index.d.ts +7 -0
  59. package/dist/json/index.d.ts.map +1 -0
  60. package/dist/json/index.js +7 -0
  61. package/dist/json/index.js.map +1 -0
  62. package/dist/runners/FileUtils.d.ts +6 -0
  63. package/dist/runners/FileUtils.d.ts.map +1 -0
  64. package/dist/runners/FileUtils.js +77 -0
  65. package/dist/runners/FileUtils.js.map +1 -0
  66. package/dist/runners/RunCheckFolder.d.ts +2 -0
  67. package/dist/runners/RunCheckFolder.d.ts.map +1 -0
  68. package/dist/runners/RunCheckFolder.js +4 -0
  69. package/dist/runners/RunCheckFolder.js.map +1 -0
  70. package/dist/runners/RunCheckFolderWithLanguage.d.ts +2 -0
  71. package/dist/runners/RunCheckFolderWithLanguage.d.ts.map +1 -0
  72. package/dist/runners/RunCheckFolderWithLanguage.js +36 -0
  73. package/dist/runners/RunCheckFolderWithLanguage.js.map +1 -0
  74. package/dist/runners/RunCheckOneFile.d.ts +2 -0
  75. package/dist/runners/RunCheckOneFile.d.ts.map +1 -0
  76. package/dist/runners/RunCheckOneFile.js +4 -0
  77. package/dist/runners/RunCheckOneFile.js.map +1 -0
  78. package/dist/runners/RunCheckOneFileWithLanguage.d.ts +2 -0
  79. package/dist/runners/RunCheckOneFileWithLanguage.d.ts.map +1 -0
  80. package/dist/runners/RunCheckOneFileWithLanguage.js +22 -0
  81. package/dist/runners/RunCheckOneFileWithLanguage.js.map +1 -0
  82. package/dist/runners/RunLioncoreDiff.d.ts +2 -0
  83. package/dist/runners/RunLioncoreDiff.d.ts.map +1 -0
  84. package/dist/runners/RunLioncoreDiff.js +22 -0
  85. package/dist/runners/RunLioncoreDiff.js.map +1 -0
  86. package/dist/runners/Utils.d.ts +7 -0
  87. package/dist/runners/Utils.d.ts.map +1 -0
  88. package/dist/runners/Utils.js +49 -0
  89. package/dist/runners/Utils.js.map +1 -0
  90. package/dist/runners/index.d.ts +3 -0
  91. package/dist/runners/index.d.ts.map +1 -0
  92. package/dist/runners/index.js +3 -0
  93. package/dist/runners/index.js.map +1 -0
  94. package/dist/validators/LionWebLanguageReferenceValidator.d.ts +24 -0
  95. package/dist/validators/LionWebLanguageReferenceValidator.d.ts.map +1 -0
  96. package/dist/validators/LionWebLanguageReferenceValidator.js +109 -0
  97. package/dist/validators/LionWebLanguageReferenceValidator.js.map +1 -0
  98. package/dist/validators/LionWebLanguageValidator.d.ts +12 -0
  99. package/dist/validators/LionWebLanguageValidator.d.ts.map +1 -0
  100. package/dist/validators/LionWebLanguageValidator.js +35 -0
  101. package/dist/validators/LionWebLanguageValidator.js.map +1 -0
  102. package/dist/validators/LionWebReferenceValidator.d.ts +45 -0
  103. package/dist/validators/LionWebReferenceValidator.d.ts.map +1 -0
  104. package/dist/validators/LionWebReferenceValidator.js +210 -0
  105. package/dist/validators/LionWebReferenceValidator.js.map +1 -0
  106. package/dist/validators/LionWebSyntaxValidator.d.ts +88 -0
  107. package/dist/validators/LionWebSyntaxValidator.d.ts.map +1 -0
  108. package/dist/validators/LionWebSyntaxValidator.js +244 -0
  109. package/dist/validators/LionWebSyntaxValidator.js.map +1 -0
  110. package/dist/validators/LionWebValidator.d.ts +24 -0
  111. package/dist/validators/LionWebValidator.d.ts.map +1 -0
  112. package/dist/validators/LionWebValidator.js +59 -0
  113. package/dist/validators/LionWebValidator.js.map +1 -0
  114. package/dist/validators/SimpleFieldValidator.d.ts +27 -0
  115. package/dist/validators/SimpleFieldValidator.d.ts.map +1 -0
  116. package/dist/validators/SimpleFieldValidator.js +77 -0
  117. package/dist/validators/SimpleFieldValidator.js.map +1 -0
  118. package/dist/validators/ValidationResult.d.ts +8 -0
  119. package/dist/validators/ValidationResult.d.ts.map +1 -0
  120. package/dist/validators/ValidationResult.js +15 -0
  121. package/dist/validators/ValidationResult.js.map +1 -0
  122. package/dist/validators/index.d.ts +8 -0
  123. package/dist/validators/index.d.ts.map +1 -0
  124. package/dist/validators/index.js +8 -0
  125. package/dist/validators/index.js.map +1 -0
  126. package/package.json +12 -10
  127. package/src/diff/LionwebDiff.ts +6 -6
  128. package/src/index.ts +4 -0
  129. package/src/issues/JsonContext.ts +31 -0
  130. package/src/issues/LanguageIssues.ts +3 -2
  131. package/src/issues/ReferenceIssues.ts +3 -2
  132. package/src/issues/SyntaxIssues.ts +2 -1
  133. package/src/issues/ValidationIssue.ts +1 -31
  134. package/src/issues/index.ts +5 -0
  135. package/src/json/ChunkUtils.ts +1 -1
  136. package/src/json/LanguageUtils.ts +43 -2
  137. package/src/json/LionWebJson.ts +2 -0
  138. package/src/json/LionWebJsonChunkWrapper.ts +4 -11
  139. package/src/json/LionWebLanguageDefinition.ts +24 -17
  140. package/src/json/NodeUtils.ts +1 -1
  141. package/src/json/index.ts +6 -0
  142. package/src/runners/FileUtils.ts +87 -0
  143. package/src/runners/RunCheckFolder.ts +2 -33
  144. package/src/runners/RunCheckFolderWithLanguage.ts +5 -5
  145. package/src/runners/RunCheckOneFile.ts +2 -13
  146. package/src/runners/RunCheckOneFileWithLanguage.ts +4 -4
  147. package/src/runners/RunLioncoreDiff.ts +2 -2
  148. package/src/runners/Utils.ts +37 -3
  149. package/src/runners/index.ts +2 -0
  150. package/src/validators/LionWebLanguageReferenceValidator.ts +7 -7
  151. package/src/validators/LionWebLanguageValidator.ts +7 -7
  152. package/src/validators/LionWebReferenceValidator.ts +20 -7
  153. package/src/validators/LionWebSyntaxValidator.ts +8 -6
  154. package/src/validators/LionWebValidator.ts +8 -8
  155. package/src/validators/SimpleFieldValidator.ts +5 -5
  156. package/src/validators/ValidationResult.ts +1 -1
  157. package/src/validators/index.ts +7 -0
package/README.md CHANGED
@@ -1,31 +1,30 @@
1
- # @lionweb/validation
1
+ # The `validation` package
2
2
 
3
- The code in this package implements the checks to run the tests in `lionweb-integration-testing/testset`.
3
+ The code in this package implements validators that check serialization chunks against the [serialization specification](https://github.com/LionWeb-io/specification/blob/main/2023.1/serialization/serialization.adoc).
4
+ This package is intentionally kept very lightweight, e.g. it uses types instead of classes and has zero dependencies on external libraries/packages.
4
5
 
5
- This package is intentionally kept very lightweigt, e.g. it uses type instead of classes and has has zero dependencies on external libraries/packages.
6
+ It's tested by running the validators against the [test set in `lionweb-integration-testing/testset`](https://github.com/LionWeb-io/lionweb-integration-testing/tree/main/testset).
6
7
 
7
- It assumes that node.js 18 is used, but will propably work with other versions as well.
8
+ To run the tests, checkout the `lionweb-integration-testing` project in next to the `lionweb-typescript` project, and run:
8
9
 
9
- To run the tests checkout the `lionweb-integration-testing` project in next to the `lionweb-typescript` project
10
- and run
10
+ ```shell
11
+ # install dependencies and build source:
12
+ ./build.sh
11
13
 
12
- # install ts-node
13
- npm install
14
+ # run the tests in the test set:
15
+ npm run testValid
16
+ npm run testInvalid
17
+ npm run testValidWithLanguage
18
+ npm run testInvalidWithLanguage
19
+ ```
14
20
 
15
- # run the tests
16
- npm run testValid
17
- npm run testInvalid
18
- npm run testValidWithLanguage
19
- npm run testInvalidWithLanguage
20
-
21
- This will run the tests in the respective folders in the `testset` folder in `lionweb-integration-testing`.
21
+ This will run the tests in the respective folders in the `testset/` folder in `lionweb-integration-testing`.
22
22
 
23
23
  Notes:
24
- - testing with enums is not implemented yet
25
- - all tests in the testset with duplicates are defined as invalid, are not invalid anymore, as decided in the meeting from 23-08-2023. They should be moved to valid.
26
-
27
- The testrunner runs tests at various levels similar (but probably not quite) as described in
28
- the model-correctness document (link).
29
- These two should converge in the near future.
24
+ - Testing with enums is not implemented yet.
25
+ - All tests in the test set with duplicates (which used to be considered invalid), are not invalid anymore, as decided in the meeting on 23-08-2023.
26
+ They should be moved to valid.
30
27
 
28
+ The test runner runs tests at various levels similar (but probably not quite) as described in the [model correctness document](https://github.com/LionWeb-io/specification/blob/meinte/correctness/documentation/correctness.adoc).
29
+ These two should converge in the future.
31
30
 
@@ -0,0 +1,40 @@
1
+ import { LionWebSyntaxValidator } from "../validators/LionWebSyntaxValidator.js";
2
+ import { LionWebJsonChild, LionWebJsonChunk, LionWebJsonNode, LionWebJsonReference } from "../json/LionWebJson.js";
3
+ export type ChangedType = {
4
+ path: string;
5
+ oldValue: unknown;
6
+ newValue: unknown;
7
+ };
8
+ export type AddedOrDeletedType = {
9
+ path: string;
10
+ value: unknown;
11
+ };
12
+ export type MatchedType = {
13
+ path: string;
14
+ value: unknown;
15
+ };
16
+ export type ResultType = {
17
+ matched: MatchedType[];
18
+ changed: ChangedType[];
19
+ added: AddedOrDeletedType[];
20
+ deleted: AddedOrDeletedType[];
21
+ };
22
+ export declare class LwDiff {
23
+ errors: string[];
24
+ lwChecker: LionWebSyntaxValidator;
25
+ constructor();
26
+ error(msg: string): void;
27
+ check(b: boolean, message: string): void;
28
+ /**
29
+ * Compare two LwNode objects and return their difference
30
+ * @param obj1
31
+ * @param obj2
32
+ */
33
+ diffLwNode(obj1: LionWebJsonNode, obj2: LionWebJsonNode): void;
34
+ diffLwChunk(chunk1: LionWebJsonChunk, chunk2: LionWebJsonChunk): void;
35
+ diffLwChild(obj1: LionWebJsonChild, obj2: LionWebJsonChild): void;
36
+ diffLwReference(ref1: LionWebJsonReference, ref2: LionWebJsonReference): void;
37
+ private diffLwUsedLanguage;
38
+ private diffLwProperty;
39
+ }
40
+ //# sourceMappingURL=LionwebDiff.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LionwebDiff.d.ts","sourceRoot":"","sources":["../../src/diff/LionwebDiff.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,EAEH,gBAAgB,EAChB,gBAAgB,EAChB,eAAe,EACf,oBAAoB,EACvB,MAAM,wBAAwB,CAAC;AAKhC,MAAM,MAAM,WAAW,GAAG;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;CACrB,CAAC;AACF,MAAM,MAAM,kBAAkB,GAAG;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC;AACF,MAAM,MAAM,WAAW,GAAG;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;CAClB,CAAC;AACF,MAAM,MAAM,UAAU,GAAG;IACrB,OAAO,EAAE,WAAW,EAAE,CAAC;IACvB,OAAO,EAAE,WAAW,EAAE,CAAC;IACvB,KAAK,EAAE,kBAAkB,EAAE,CAAC;IAC5B,OAAO,EAAE,kBAAkB,EAAE,CAAC;CACjC,CAAC;AAEF,qBAAa,MAAM;IACf,MAAM,EAAE,MAAM,EAAE,CAAM;IACtB,SAAS,yBAAsD;;IAM/D,KAAK,CAAC,GAAG,EAAE,MAAM;IAIjB,KAAK,CAAC,CAAC,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,GAAG,IAAI;IAMxC;;;;OAIG;IACH,UAAU,CAAC,IAAI,EAAE,eAAe,EAAE,IAAI,EAAE,eAAe,GAAG,IAAI;IAuC9D,WAAW,CAAC,MAAM,EAAE,gBAAgB,EAAE,MAAM,EAAE,gBAAgB,GAAG,IAAI;IA0CrE,WAAW,CAAC,IAAI,EAAE,gBAAgB,EAAE,IAAI,EAAE,gBAAgB,GAAG,IAAI;IAkBjE,eAAe,CAAC,IAAI,EAAE,oBAAoB,EAAE,IAAI,EAAE,oBAAoB,GAAG,IAAI;IAsB7E,OAAO,CAAC,kBAAkB;IAM1B,OAAO,CAAC,cAAc;CAQzB"}
@@ -0,0 +1,158 @@
1
+ // TODO The diff is outdated and need work to become fully functional again.
2
+ import { LionWebSyntaxValidator } from "../validators/LionWebSyntaxValidator.js";
3
+ import { isEqualMetaPointer, } from "../json/LionWebJson.js";
4
+ import { NodeUtils } from "../json/NodeUtils.js";
5
+ import { ChunkUtils } from "../json/ChunkUtils.js";
6
+ import { ValidationResult } from "../validators/ValidationResult.js";
7
+ export class LwDiff {
8
+ constructor() {
9
+ this.errors = [];
10
+ this.lwChecker = new LionWebSyntaxValidator(new ValidationResult());
11
+ this.lwChecker.recursive = false;
12
+ }
13
+ error(msg) {
14
+ this.errors.push(msg + "\n");
15
+ }
16
+ check(b, message) {
17
+ if (!b) {
18
+ this.error("Check error: " + message);
19
+ }
20
+ }
21
+ /**
22
+ * Compare two LwNode objects and return their difference
23
+ * @param obj1
24
+ * @param obj2
25
+ */
26
+ diffLwNode(obj1, obj2) {
27
+ // console.log("Comparing nodes")
28
+ if (!isEqualMetaPointer(obj1.classifier, obj2.classifier)) {
29
+ this.error(`Object ${obj1.id} has classifier ${JSON.stringify(obj1.classifier)} vs. ${JSON.stringify(obj2.classifier)}`);
30
+ }
31
+ if (obj1.parent !== obj2.parent) {
32
+ this.error(`Object ${obj1.id} has parent ${obj1.parent} vs. ${obj2.parent}`);
33
+ }
34
+ for (const property of obj1.properties) {
35
+ const key = property.property.key;
36
+ // console.log(` property ${key} of node ${obj1.id}`)
37
+ const otherProp = NodeUtils.findLwProperty(obj2, key);
38
+ if (otherProp === null) {
39
+ this.error(`Property with concept key ${key} does not exist in second object`);
40
+ continue;
41
+ }
42
+ // const tmp = this.diffLwProperty(prop, otherProp);
43
+ }
44
+ for (const containment of obj1.containments) {
45
+ const key = containment.containment.key;
46
+ // console.log(` property ${key} of node ${obj1.id}`)
47
+ const otherChild = NodeUtils.findLwChild(obj2, key);
48
+ if (otherChild === null) {
49
+ this.error(`Child with containment key ${key} does not exist in second object`);
50
+ continue;
51
+ }
52
+ // const tmp = this.diffLwChild(child, otherChild);
53
+ }
54
+ for (const reference of obj1.references) {
55
+ const key = reference.reference.key;
56
+ const otherref = NodeUtils.findLwReference(obj2, key);
57
+ if (otherref === null) {
58
+ this.error(`Child with containment key ${key} does not exist in second object`);
59
+ continue;
60
+ }
61
+ // const tmp = this.diffLwReference(ref, otherref);
62
+ }
63
+ }
64
+ diffLwChunk(chunk1, chunk2) {
65
+ console.log("Comparing chuncks");
66
+ if (chunk1.serializationFormatVersion !== chunk2.serializationFormatVersion) {
67
+ this.error(`Serialization versions do not match: ${chunk1.serializationFormatVersion} vs ${chunk2.serializationFormatVersion}`);
68
+ }
69
+ for (const language of chunk1.languages) {
70
+ const otherLanguage = ChunkUtils.findLwUsedLanguage(chunk2, language.key);
71
+ if (otherLanguage === null) {
72
+ // return { isEqual: false, diffMessage: `Node with concept key ${id} does not exist in second object`};
73
+ this.error(`Language with key ${language.key} does not exist in second object`);
74
+ continue;
75
+ }
76
+ // const tmp = this.diffLwUsedLanguage(language, otherLanguage);
77
+ }
78
+ for (const language of chunk2.languages) {
79
+ console.log("Comparing languages");
80
+ const otherLanguage = ChunkUtils.findLwUsedLanguage(chunk1, language.key);
81
+ if (otherLanguage === null) {
82
+ // return { isEqual: false, diffMessage: `Node with concept key ${id} does not exist in second object`};
83
+ this.error(`Language with key ${language.key} does not exist in first object`);
84
+ }
85
+ }
86
+ for (const node of chunk1.nodes) {
87
+ const id = node.id;
88
+ const otherNode = ChunkUtils.findNode(chunk2, id);
89
+ if (otherNode === null) {
90
+ // return { isEqual: false, diffMessage: `Node with concept key ${id} does not exist in second object`};
91
+ this.error(`Node with concept key ${id} does not exist in second object`);
92
+ continue;
93
+ }
94
+ // const tmp = this.diffLwNode(node, otherNode);
95
+ }
96
+ for (const node of chunk2.nodes) {
97
+ const id = node.id;
98
+ const otherNode = ChunkUtils.findNode(chunk1, id);
99
+ if (otherNode === null) {
100
+ // return { isEqual: false, diffMessage: `Node with concept key ${id} does not exist in second object`};
101
+ this.error(`Node with concept key ${id} does not exist in first object`);
102
+ }
103
+ }
104
+ }
105
+ diffLwChild(obj1, obj2) {
106
+ if (!isEqualMetaPointer(obj1.containment, obj2.containment)) {
107
+ // return { isEqual: false, diffMessage: `Property Object has concept ${JSON.stringify(obj1.property)} vs ${JSON.stringify(obj2.property)}`}
108
+ this.error(`Child Object has concept ${JSON.stringify(obj1.containment)} vs ${JSON.stringify(obj2.containment)}`);
109
+ }
110
+ // Check whether children exist in both objects (two for loops)
111
+ for (const childId1 of obj1.children) {
112
+ if (!obj2.children.includes(childId1)) {
113
+ this.error(`Child ${childId1} is missing in other object`);
114
+ }
115
+ }
116
+ for (const childId2 of obj2.children) {
117
+ if (!obj1.children.includes(childId2)) {
118
+ console.error(`Child ${childId2} is missing in first object`);
119
+ }
120
+ }
121
+ }
122
+ diffLwReference(ref1, ref2) {
123
+ if (!isEqualMetaPointer(ref1.reference, ref2.reference)) {
124
+ // return { isEqual: false, diffMessage: `Property Object has concept ${JSON.stringify(obj1.property)} vs ${JSON.stringify(obj2.property)}`}
125
+ this.error(`Reference has concept ${JSON.stringify(ref1.reference)} vs ${JSON.stringify(ref2.reference)}`);
126
+ }
127
+ for (const target of ref1.targets) {
128
+ const otherTarget = NodeUtils.findLwReferenceTarget(ref2.targets, target);
129
+ if (otherTarget === null) {
130
+ console.error(`REFERENCE Target ${JSON.stringify(target)} missing in second `);
131
+ }
132
+ else {
133
+ if (target.reference !== otherTarget.reference || target.resolveInfo !== otherTarget.resolveInfo) {
134
+ this.error(`REFERENCE target ${JSON.stringify(target)} vs ${JSON.stringify(otherTarget)}`);
135
+ }
136
+ }
137
+ }
138
+ for (const target of ref2.targets) {
139
+ if (NodeUtils.findLwReferenceTarget(ref1.targets, target) === null) {
140
+ this.error(`REFERENCE Target ${JSON.stringify(target)} missing in first `);
141
+ }
142
+ }
143
+ }
144
+ diffLwUsedLanguage(obj1, obj2) {
145
+ if (obj1.key !== obj2.key || obj1.version !== obj2.version) {
146
+ this.error(`Different used languages ${JSON.stringify(obj1)} vs ${JSON.stringify(obj2)}`);
147
+ }
148
+ }
149
+ diffLwProperty(obj1, obj2) {
150
+ if (!isEqualMetaPointer(obj1.property, obj2.property)) {
151
+ this.error(`Property Object has concept ${JSON.stringify(obj1.property)} vs ${JSON.stringify(obj2.property)}`);
152
+ }
153
+ if (obj1.value !== obj2.value) {
154
+ this.error(`Property ${obj1.property.key} has value ${obj1.value} vs ${obj2.value}`);
155
+ }
156
+ }
157
+ }
158
+ //# sourceMappingURL=LionwebDiff.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LionwebDiff.js","sourceRoot":"","sources":["../../src/diff/LionwebDiff.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAE5E,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AACjF,OAAO,EACH,kBAAkB,GAKrB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AAsBrE,MAAM,OAAO,MAAM;IAIf;QAHA,WAAM,GAAa,EAAE,CAAC;QACtB,cAAS,GAAG,IAAI,sBAAsB,CAAC,IAAI,gBAAgB,EAAE,CAAC,CAAC;QAG3D,IAAI,CAAC,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,CAAC,+BAA+B,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;QACnH,CAAC;QACD,IAAI,IAAI,CAAC,KAAK,KAAK,IAAI,CAAC,KAAK,EAAE,CAAC;YAC5B,IAAI,CAAC,KAAK,CAAC,YAAY,IAAI,CAAC,QAAQ,CAAC,GAAG,cAAc,IAAI,CAAC,KAAK,OAAO,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC;QACzF,CAAC;IACL,CAAC;CACJ"}
@@ -0,0 +1,5 @@
1
+ export * from "./issues/index.js";
2
+ export * from "./json/index.js";
3
+ export * from "./validators/index.js";
4
+ export * from "./runners/index.js";
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,5 @@
1
+ export * from "./issues/index.js";
2
+ export * from "./json/index.js";
3
+ export * from "./validators/index.js";
4
+ export * from "./runners/index.js";
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC"}
@@ -0,0 +1,11 @@
1
+ type JsonPath = (string | number)[];
2
+ export declare class JsonContext {
3
+ private parent;
4
+ private local_path;
5
+ concat(...items: JsonPath): JsonContext;
6
+ path(): JsonPath;
7
+ constructor(parent: JsonContext | null, path: JsonPath);
8
+ toString(): string;
9
+ }
10
+ export {};
11
+ //# sourceMappingURL=JsonContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"JsonContext.d.ts","sourceRoot":"","sources":["../../src/issues/JsonContext.ts"],"names":[],"mappings":"AAAA,KAAK,QAAQ,GAAG,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,CAAC;AAEpC,qBAAa,WAAW;IACpB,OAAO,CAAC,MAAM,CAAqB;IACnC,OAAO,CAAC,UAAU,CAAW;IAE7B,MAAM,CAAC,GAAI,KAAK,EAAE,QAAQ,GAAI,WAAW;IAIzC,IAAI,IAAI,QAAQ;gBAIJ,MAAM,EAAE,WAAW,GAAG,IAAI,EAAE,IAAI,EAAE,QAAQ;IAKtD,QAAQ,IAAI,MAAM;CAWrB"}
@@ -0,0 +1,25 @@
1
+ export class JsonContext {
2
+ concat(...items) {
3
+ return new JsonContext(this, items);
4
+ }
5
+ path() {
6
+ return this.parent === null ? this.local_path : this.parent.path().concat(this.local_path);
7
+ }
8
+ constructor(parent, path) {
9
+ this.parent = parent;
10
+ this.local_path = path;
11
+ }
12
+ toString() {
13
+ let result = "";
14
+ this.path().forEach((part, index) => {
15
+ if (typeof part === "string") {
16
+ result += (index === 0 ? "" : ".") + part;
17
+ }
18
+ else if (typeof part === "number") {
19
+ result += "[" + part + "]";
20
+ }
21
+ });
22
+ return result;
23
+ }
24
+ }
25
+ //# sourceMappingURL=JsonContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"JsonContext.js","sourceRoot":"","sources":["../../src/issues/JsonContext.ts"],"names":[],"mappings":"AAEA,MAAM,OAAO,WAAW;IAIpB,MAAM,CAAC,GAAI,KAAe;QACtB,OAAO,IAAI,WAAW,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;IACxC,CAAC;IAED,IAAI;QACA,OAAO,IAAI,CAAC,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IAC/F,CAAC;IAED,YAAY,MAA0B,EAAE,IAAc;QAClD,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC;IAC3B,CAAC;IAED,QAAQ;QACJ,IAAI,MAAM,GAAG,EAAE,CAAC;QAChB,IAAI,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;YAChC,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;gBAC3B,MAAM,IAAI,CAAC,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC;YAC9C,CAAC;iBAAM,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;gBAClC,MAAM,IAAI,GAAG,GAAG,IAAI,GAAG,GAAG,CAAC;YAC/B,CAAC;QACL,CAAC,CAAC,CAAC;QACH,OAAO,MAAM,CAAC;IAClB,CAAC;CACJ"}
@@ -0,0 +1,75 @@
1
+ import { LionWebJsonMetaPointer } from "../json/LionWebJson.js";
2
+ import { JsonContext } from "./JsonContext.js";
3
+ import { ValidationIssue } from "./ValidationIssue.js";
4
+ export declare class Language_PropertyValue_Issue extends ValidationIssue {
5
+ property: string;
6
+ value: string;
7
+ expectedType: string;
8
+ readonly id = "PropertyValue";
9
+ constructor(context: JsonContext, property: string, value: string, expectedType: string);
10
+ msg: () => string;
11
+ }
12
+ export declare abstract class Language_IncorrectMetaPointerType_Issue extends ValidationIssue {
13
+ metaPointer: LionWebJsonMetaPointer;
14
+ incorrectType: string;
15
+ abstract readonly metaType: string;
16
+ constructor(context: JsonContext, metaPointer: LionWebJsonMetaPointer, incorrectType: string);
17
+ msg: () => string;
18
+ }
19
+ export declare class Language_IncorrectPropertyMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
20
+ readonly id = "IncorrectPropertyMetaPointer";
21
+ readonly metaType = "Property";
22
+ }
23
+ export declare class Language_IncorrectConceptMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
24
+ readonly id = "IncorrectConceptMetaPointer";
25
+ readonly metaType = "Concept";
26
+ }
27
+ export declare class Language_IncorrectReferenceMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
28
+ readonly id = "IncorrectReferenceMetaPointer";
29
+ readonly metaType = "Reference";
30
+ }
31
+ export declare class Language_IncorrectContainmentMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
32
+ readonly id = "IncorrectContainmentMetaPointer";
33
+ readonly metaType = "Containment";
34
+ }
35
+ export declare abstract class Language_UnknownMetaPointer_Issue extends ValidationIssue {
36
+ metaPointer: LionWebJsonMetaPointer;
37
+ abstract readonly metaType: string;
38
+ constructor(context: JsonContext, metaPointer: LionWebJsonMetaPointer);
39
+ msg: () => string;
40
+ }
41
+ export declare class Language_UnknownReference_Issue extends Language_UnknownMetaPointer_Issue {
42
+ readonly id = "UnknownReference";
43
+ readonly metaType = "Reference";
44
+ }
45
+ export declare class Language_UnknownContainment_Issue extends Language_UnknownMetaPointer_Issue {
46
+ readonly id = "UnknownContainment";
47
+ readonly metaType = "Containment";
48
+ }
49
+ export declare class Language_UnknownProperty_Issue extends Language_UnknownMetaPointer_Issue {
50
+ readonly id = "UnknownProperty";
51
+ readonly metaType = "Property";
52
+ }
53
+ export declare class Language_UnknownConcept_Issue extends Language_UnknownMetaPointer_Issue {
54
+ readonly id = "UnknownConcept";
55
+ readonly metaType = "Concept";
56
+ }
57
+ export declare class NumberOfLanguagesUsed_Issue extends ValidationIssue {
58
+ nrOfLanguages: number;
59
+ readonly id = "NumberOfLanguagesUsed";
60
+ constructor(context: JsonContext, nrOfLanguages: number);
61
+ msg: () => string;
62
+ }
63
+ export declare class NotLionCoreLanguageKey_Issue extends ValidationIssue {
64
+ incorrectKey: string;
65
+ readonly id = "NotLionCoreLanguageKey";
66
+ constructor(context: JsonContext, incorrectKey: string);
67
+ msg: () => string;
68
+ }
69
+ export declare class IncorrectLionCoreVersion_Issue extends ValidationIssue {
70
+ incorrectVersion: string;
71
+ readonly id = "IncorrectLionCoreVersion";
72
+ constructor(context: JsonContext, incorrectVersion: string);
73
+ msg: () => string;
74
+ }
75
+ //# sourceMappingURL=LanguageIssues.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LanguageIssues.d.ts","sourceRoot":"","sources":["../../src/issues/LanguageIssues.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAEvD,qBAAa,4BAA6B,SAAQ,eAAe;IAGpB,QAAQ,EAAE,MAAM;IAAS,KAAK,EAAE,MAAM;IAAQ,YAAY,EAAE,MAAM;IAF3G,QAAQ,CAAC,EAAE,mBAAmB;gBAElB,OAAO,EAAE,WAAW,EAAS,QAAQ,EAAE,MAAM,EAAS,KAAK,EAAE,MAAM,EAAQ,YAAY,EAAE,MAAM;IAI3G,GAAG,QAAO,MAAM,CAAmG;CACtH;AAGD,8BAAsB,uCAAwC,SAAQ,eAAe;IAGxC,WAAW,EAAE,sBAAsB;IAAS,aAAa,EAAE,MAAM;IAF1G,QAAQ,CAAC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;gBAEvB,OAAO,EAAE,WAAW,EAAS,WAAW,EAAE,sBAAsB,EAAS,aAAa,EAAE,MAAM;IAI1G,GAAG,QAAO,MAAM,CAAgI;CACnJ;AAED,qBAAa,2CAA4C,SAAQ,uCAAuC;IACpG,QAAQ,CAAC,EAAE,kCAAkC;IAC7C,QAAQ,CAAC,QAAQ,cAAc;CAClC;AACD,qBAAa,0CAA2C,SAAQ,uCAAuC;IACnG,QAAQ,CAAC,EAAE,iCAAiC;IAC5C,QAAQ,CAAC,QAAQ,aAAa;CACjC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+B,SAAQ,eAAe;IAEtB,gBAAgB,EAAE,MAAM;IADjE,QAAQ,CAAC,EAAE,8BAA8B;gBAC7B,OAAO,EAAE,WAAW,EAAS,gBAAgB,EAAE,MAAM;IAGjE,GAAG,eAA8F;CACpG"}
@@ -0,0 +1,110 @@
1
+ import { ValidationIssue } from "./ValidationIssue.js";
2
+ export class Language_PropertyValue_Issue extends ValidationIssue {
3
+ constructor(context, property, value, expectedType) {
4
+ super(context);
5
+ this.property = property;
6
+ this.value = value;
7
+ this.expectedType = expectedType;
8
+ this.id = "PropertyValue";
9
+ this.msg = () => `Property "${this.property}" with value "${this.value}" is not of type "${this.expectedType}"`;
10
+ }
11
+ }
12
+ // Incorrect Meta Pointers
13
+ export class Language_IncorrectMetaPointerType_Issue extends ValidationIssue {
14
+ constructor(context, metaPointer, incorrectType) {
15
+ super(context);
16
+ this.metaPointer = metaPointer;
17
+ this.incorrectType = incorrectType;
18
+ this.msg = () => `${this.metaType} with key "${this.metaPointer.key}" does not refer to a ${this.metaType}, but to a "${this.incorrectType}"`;
19
+ }
20
+ }
21
+ export class Language_IncorrectPropertyMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
22
+ constructor() {
23
+ super(...arguments);
24
+ this.id = "IncorrectPropertyMetaPointer";
25
+ this.metaType = "Property";
26
+ }
27
+ }
28
+ export class Language_IncorrectConceptMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
29
+ constructor() {
30
+ super(...arguments);
31
+ this.id = "IncorrectConceptMetaPointer";
32
+ this.metaType = "Concept";
33
+ }
34
+ }
35
+ export class Language_IncorrectReferenceMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
36
+ constructor() {
37
+ super(...arguments);
38
+ this.id = "IncorrectReferenceMetaPointer";
39
+ this.metaType = "Reference";
40
+ }
41
+ }
42
+ export class Language_IncorrectContainmentMetaPointer_Issue extends Language_IncorrectMetaPointerType_Issue {
43
+ constructor() {
44
+ super(...arguments);
45
+ this.id = "IncorrectContainmentMetaPointer";
46
+ this.metaType = "Containment";
47
+ }
48
+ }
49
+ // Unknown Meta Pointers
50
+ export class Language_UnknownMetaPointer_Issue extends ValidationIssue {
51
+ constructor(context, metaPointer) {
52
+ super(context);
53
+ this.metaPointer = metaPointer;
54
+ this.msg = () => `${this.metaType} with key ${this.metaPointer.key} is unknown in the language`;
55
+ }
56
+ }
57
+ export class Language_UnknownReference_Issue extends Language_UnknownMetaPointer_Issue {
58
+ constructor() {
59
+ super(...arguments);
60
+ this.id = "UnknownReference";
61
+ this.metaType = "Reference";
62
+ }
63
+ }
64
+ export class Language_UnknownContainment_Issue extends Language_UnknownMetaPointer_Issue {
65
+ constructor() {
66
+ super(...arguments);
67
+ this.id = "UnknownContainment";
68
+ this.metaType = "Containment";
69
+ }
70
+ }
71
+ export class Language_UnknownProperty_Issue extends Language_UnknownMetaPointer_Issue {
72
+ constructor() {
73
+ super(...arguments);
74
+ this.id = "UnknownProperty";
75
+ this.metaType = "Property";
76
+ }
77
+ }
78
+ export class Language_UnknownConcept_Issue extends Language_UnknownMetaPointer_Issue {
79
+ constructor() {
80
+ super(...arguments);
81
+ this.id = "UnknownConcept";
82
+ this.metaType = "Concept";
83
+ }
84
+ }
85
+ // Actual Language checks on M2
86
+ export class NumberOfLanguagesUsed_Issue extends ValidationIssue {
87
+ constructor(context, nrOfLanguages) {
88
+ super(context);
89
+ this.nrOfLanguages = nrOfLanguages;
90
+ this.id = "NumberOfLanguagesUsed";
91
+ this.msg = () => `Is not a language: number of used languages should be 1, is ${this.nrOfLanguages}`;
92
+ }
93
+ }
94
+ export class NotLionCoreLanguageKey_Issue extends ValidationIssue {
95
+ constructor(context, incorrectKey) {
96
+ super(context);
97
+ this.incorrectKey = incorrectKey;
98
+ this.id = "NotLionCoreLanguageKey";
99
+ this.msg = () => `Is not a language: the used language key is not LionCore-M3, but ${this.incorrectKey}`;
100
+ }
101
+ }
102
+ export class IncorrectLionCoreVersion_Issue extends ValidationIssue {
103
+ constructor(context, incorrectVersion) {
104
+ super(context);
105
+ this.incorrectVersion = incorrectVersion;
106
+ this.id = "IncorrectLionCoreVersion";
107
+ this.msg = () => `Is not a language: the used language version is not 1, but ${this.incorrectVersion}`;
108
+ }
109
+ }
110
+ //# sourceMappingURL=LanguageIssues.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LanguageIssues.js","sourceRoot":"","sources":["../../src/issues/LanguageIssues.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAEvD,MAAM,OAAO,4BAA6B,SAAQ,eAAe;IAG7D,YAAY,OAAoB,EAAS,QAAgB,EAAS,KAAa,EAAQ,YAAoB;QACvG,KAAK,CAAC,OAAO,CAAC,CAAC;QADsB,aAAQ,GAAR,QAAQ,CAAQ;QAAS,UAAK,GAAL,KAAK,CAAQ;QAAQ,iBAAY,GAAZ,YAAY,CAAQ;QAFlG,OAAE,GAAG,eAAe,CAAC;QAM9B,QAAG,GAAG,GAAW,EAAE,CAAC,cAAc,IAAI,CAAC,QAAQ,iBAAiB,IAAI,CAAC,KAAK,qBAAqB,IAAI,CAAC,YAAY,GAAG,CAAA;IAFnH,CAAC;CAGJ;AAED,0BAA0B;AAC1B,MAAM,OAAgB,uCAAwC,SAAQ,eAAe;IAGjF,YAAY,OAAoB,EAAS,WAAmC,EAAS,aAAqB;QACtG,KAAK,CAAC,OAAO,CAAC,CAAC;QADsB,gBAAW,GAAX,WAAW,CAAwB;QAAS,kBAAa,GAAb,aAAa,CAAQ;QAI1G,QAAG,GAAG,GAAW,EAAE,CAAC,GAAG,IAAI,CAAC,QAAQ,cAAc,IAAI,CAAC,WAAW,CAAC,GAAG,yBAAyB,IAAI,CAAC,QAAQ,eAAe,IAAI,CAAC,aAAa,GAAG,CAAA;IAFhJ,CAAC;CAGJ;AAED,MAAM,OAAO,2CAA4C,SAAQ,uCAAuC;IAAxG;;QACa,OAAE,GAAG,8BAA8B,CAAC;QACpC,aAAQ,GAAG,UAAU,CAAC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AC/B,MAAM,OAAO,2BAA4B,SAAQ,eAAe;IAE5D,YAAY,OAAoB,EAAS,aAAqB;QAC1D,KAAK,CAAC,OAAO,CAAC,CAAC;QADsB,kBAAa,GAAb,aAAa,CAAQ;QADrD,OAAE,GAAG,uBAAuB,CAAC;QAItC,QAAG,GAAG,GAAG,EAAE,CAAC,+DAA+D,IAAI,CAAC,aAAa,EAAE,CAAA;IAD/F,CAAC;CAEJ;AACD,MAAM,OAAO,4BAA6B,SAAQ,eAAe;IAE7D,YAAY,OAAoB,EAAS,YAAoB;QACzD,KAAK,CAAC,OAAO,CAAC,CAAC;QADsB,iBAAY,GAAZ,YAAY,CAAQ;QADpD,OAAE,GAAG,wBAAwB,CAAC;QAIvC,QAAG,GAAG,GAAG,EAAE,CAAC,oEAAoE,IAAI,CAAC,YAAY,EAAE,CAAA;IADnG,CAAC;CAEJ;AACD,MAAM,OAAO,8BAA+B,SAAQ,eAAe;IAE/D,YAAY,OAAoB,EAAS,gBAAwB;QAC7D,KAAK,CAAC,OAAO,CAAC,CAAC;QADsB,qBAAgB,GAAhB,gBAAgB,CAAQ;QADxD,OAAE,GAAG,0BAA0B,CAAC;QAIzC,QAAG,GAAG,GAAG,EAAE,CAAC,8DAA8D,IAAI,CAAC,gBAAgB,EAAE,CAAA;IADjG,CAAC;CAEJ"}
@@ -0,0 +1,43 @@
1
+ import { LionWebJsonMetaPointer, LionWebJsonNode } from "../json/LionWebJson.js";
2
+ import { JsonContext } from "./JsonContext.js";
3
+ import { ValidationIssue } from "./ValidationIssue.js";
4
+ export declare class Reference_DuplicateNodeId_Issue extends ValidationIssue {
5
+ nodeId: string;
6
+ readonly id = "DuplicateNodeId";
7
+ constructor(context: JsonContext, nodeId: string);
8
+ msg: () => string;
9
+ }
10
+ export declare class Reference_ChildMissingInParent_Issue extends ValidationIssue {
11
+ child: LionWebJsonNode;
12
+ parent: LionWebJsonNode;
13
+ readonly id = "ChildMissingInParent";
14
+ constructor(context: JsonContext, child: LionWebJsonNode, parent: LionWebJsonNode);
15
+ msg: () => string;
16
+ }
17
+ export declare class Reference_ParentMissingInChild_Issue extends ValidationIssue {
18
+ parent: LionWebJsonNode;
19
+ child: LionWebJsonNode;
20
+ readonly id = "ParentMissingInChild";
21
+ constructor(context: JsonContext, parent: LionWebJsonNode, child: LionWebJsonNode);
22
+ msg: () => string;
23
+ }
24
+ export declare class Reference_CirculairParent_Issue extends ValidationIssue {
25
+ node: LionWebJsonNode | undefined;
26
+ parentPath: string[];
27
+ readonly id = "CirculairParent";
28
+ constructor(context: JsonContext, node: LionWebJsonNode | undefined, parentPath: string[]);
29
+ msg: () => string;
30
+ }
31
+ export declare class Reference_LanguageUnknown_Issue extends ValidationIssue {
32
+ languageRef: LionWebJsonMetaPointer;
33
+ readonly id = "LanguageUnknown";
34
+ constructor(context: JsonContext, languageRef: LionWebJsonMetaPointer);
35
+ msg: () => string;
36
+ }
37
+ export declare class Duplicates_Issue extends ValidationIssue {
38
+ nodeid: string;
39
+ readonly id = "Duplicates";
40
+ constructor(context: JsonContext, nodeid: string);
41
+ msg: () => string;
42
+ }
43
+ //# sourceMappingURL=ReferenceIssues.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReferenceIssues.d.ts","sourceRoot":"","sources":["../../src/issues/ReferenceIssues.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACjF,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAEvD,qBAAa,+BAAgC,SAAQ,eAAe;IAGvB,MAAM,EAAE,MAAM;IAFvD,QAAQ,CAAC,EAAE,qBAAqB;gBAEpB,OAAO,EAAE,WAAW,EAAS,MAAM,EAAE,MAAM;IAIvD,GAAG,QAAQ,MAAM,CAA4C;CAChE;AAED,qBAAa,oCAAqC,SAAQ,eAAe;IAG5B,KAAK,EAAE,eAAe;IAAS,MAAM,EAAE,eAAe;IAF/F,QAAQ,CAAC,EAAE,0BAA0B;gBAEzB,OAAO,EAAE,WAAW,EAAS,KAAK,EAAE,eAAe,EAAS,MAAM,EAAE,eAAe;IAI/F,GAAG,QAAQ,MAAM,CAAwH;CAC5I;AAED,qBAAa,oCAAqC,SAAQ,eAAe;IAG5B,MAAM,EAAE,eAAe;IAAS,KAAK,EAAE,eAAe;IAF/F,QAAQ,CAAC,EAAE,0BAA0B;gBAEzB,OAAO,EAAE,WAAW,EAAS,MAAM,EAAE,eAAe,EAAS,KAAK,EAAE,eAAe;IAI/F,GAAG,QAAQ,MAAM,CAAuG;CAC3H;AAED,qBAAa,+BAAgC,SAAQ,eAAe;IAGvB,IAAI,EAAE,eAAe,GAAG,SAAS;IAAS,UAAU,EAAE,MAAM,EAAE;IAFvG,QAAQ,CAAC,EAAE,qBAAqB;gBAEpB,OAAO,EAAE,WAAW,EAAS,IAAI,EAAE,eAAe,GAAG,SAAS,EAAS,UAAU,EAAE,MAAM,EAAE;IAIvG,GAAG,QAAQ,MAAM,CAAwF;CAC5G;AAED,qBAAa,+BAAgC,SAAQ,eAAe;IAGvB,WAAW,EAAE,sBAAsB;IAF5E,QAAQ,CAAC,EAAE,qBAAqB;gBAEpB,OAAO,EAAE,WAAW,EAAS,WAAW,EAAE,sBAAsB;IAG5E,GAAG,eAAwJ;CAC9J;AAED,qBAAa,gBAAiB,SAAQ,eAAe;IAGR,MAAM,EAAE,MAAM;IAFvD,QAAQ,CAAC,EAAE,gBAAgB;gBAEf,OAAO,EAAE,WAAW,EAAS,MAAM,EAAE,MAAM;IAGvD,GAAG,eAA2C;CACjD"}
@@ -0,0 +1,53 @@
1
+ import { ValidationIssue } from "./ValidationIssue.js";
2
+ export class Reference_DuplicateNodeId_Issue extends ValidationIssue {
3
+ constructor(context, nodeId) {
4
+ super(context);
5
+ this.nodeId = nodeId;
6
+ this.id = "DuplicateNodeId";
7
+ this.msg = () => `Node has duplicate id "${this.nodeId}"`;
8
+ }
9
+ }
10
+ export class Reference_ChildMissingInParent_Issue extends ValidationIssue {
11
+ constructor(context, child, parent) {
12
+ super(context);
13
+ this.child = child;
14
+ this.parent = parent;
15
+ this.id = "ChildMissingInParent";
16
+ this.msg = () => `Node with id "${this.child.id}" has parent with id "${this.parent.id}" but parent does not contains it as a child.`;
17
+ }
18
+ }
19
+ export class Reference_ParentMissingInChild_Issue extends ValidationIssue {
20
+ constructor(context, parent, child) {
21
+ super(context);
22
+ this.parent = parent;
23
+ this.child = child;
24
+ this.id = "ParentMissingInChild";
25
+ this.msg = () => `Node with id "${this.parent.id}" has child with id "${this.child.id}" but child has empty parent.`;
26
+ }
27
+ }
28
+ export class Reference_CirculairParent_Issue extends ValidationIssue {
29
+ constructor(context, node, parentPath) {
30
+ super(context);
31
+ this.node = node;
32
+ this.parentPath = parentPath;
33
+ this.id = "CirculairParent";
34
+ this.msg = () => `Node with id "${this.node?.id}" has circulair parent through "${this.parentPath}".`;
35
+ }
36
+ }
37
+ export class Reference_LanguageUnknown_Issue extends ValidationIssue {
38
+ constructor(context, languageRef) {
39
+ super(context);
40
+ this.languageRef = languageRef;
41
+ this.id = "LanguageUnknown";
42
+ this.msg = () => `Node uses language { language = ${this.languageRef.language}, version = ${this.languageRef.version} } which is not declared in used languages`;
43
+ }
44
+ }
45
+ export class Duplicates_Issue extends ValidationIssue {
46
+ constructor(context, nodeid) {
47
+ super(context);
48
+ this.nodeid = nodeid;
49
+ this.id = "Duplicates";
50
+ this.msg = () => `Duplicate value "${this.nodeid}"`;
51
+ }
52
+ }
53
+ //# sourceMappingURL=ReferenceIssues.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReferenceIssues.js","sourceRoot":"","sources":["../../src/issues/ReferenceIssues.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAEvD,MAAM,OAAO,+BAAgC,SAAQ,eAAe;IAGhE,YAAY,OAAoB,EAAS,MAAc;QACnD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