@api-client/core 0.11.11 → 0.12.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 (252) hide show
  1. package/Testing.md +1 -1
  2. package/bin/plugins/events/EventPlugin.ts +61 -0
  3. package/bin/plugins/events/assert.ts +193 -0
  4. package/bin/plugins/events/types.ts +6 -0
  5. package/bin/test.ts +8 -1
  6. package/build/src/amf/AmfShapeGenerator.d.ts +6 -3
  7. package/build/src/amf/AmfShapeGenerator.d.ts.map +1 -1
  8. package/build/src/amf/AmfShapeGenerator.js +4 -1
  9. package/build/src/amf/AmfShapeGenerator.js.map +1 -1
  10. package/build/src/amf/AmfTypes.d.ts +2 -2
  11. package/build/src/amf/AmfTypes.d.ts.map +1 -1
  12. package/build/src/amf/AmfTypes.js.map +1 -1
  13. package/build/src/amf/DataValueGenerator.d.ts +15 -15
  14. package/build/src/amf/DataValueGenerator.d.ts.map +1 -1
  15. package/build/src/amf/DataValueGenerator.js +14 -14
  16. package/build/src/amf/DataValueGenerator.js.map +1 -1
  17. package/build/src/browser.d.ts +12 -9
  18. package/build/src/browser.d.ts.map +1 -1
  19. package/build/src/browser.js +11 -8
  20. package/build/src/browser.js.map +1 -1
  21. package/build/src/exceptions/attach_exception.d.ts +11 -0
  22. package/build/src/exceptions/attach_exception.d.ts.map +1 -0
  23. package/build/src/exceptions/attach_exception.js +11 -0
  24. package/build/src/exceptions/attach_exception.js.map +1 -0
  25. package/build/src/exceptions/detach_exception.d.ts +11 -0
  26. package/build/src/exceptions/detach_exception.d.ts.map +1 -0
  27. package/build/src/exceptions/detach_exception.js +11 -0
  28. package/build/src/exceptions/detach_exception.js.map +1 -0
  29. package/build/src/exceptions/remove_model_exception.d.ts +8 -0
  30. package/build/src/exceptions/remove_model_exception.d.ts.map +1 -0
  31. package/build/src/exceptions/remove_model_exception.js +8 -0
  32. package/build/src/exceptions/remove_model_exception.js.map +1 -0
  33. package/build/src/exceptions/remove_namespace_exception.d.ts +8 -0
  34. package/build/src/exceptions/remove_namespace_exception.d.ts.map +1 -0
  35. package/build/src/exceptions/remove_namespace_exception.js +8 -0
  36. package/build/src/exceptions/remove_namespace_exception.js.map +1 -0
  37. package/build/src/index.d.ts +12 -9
  38. package/build/src/index.d.ts.map +1 -1
  39. package/build/src/index.js +11 -8
  40. package/build/src/index.js.map +1 -1
  41. package/build/src/legacy.d.ts +8 -0
  42. package/build/src/legacy.d.ts.map +1 -1
  43. package/build/src/legacy.js +9 -0
  44. package/build/src/legacy.js.map +1 -1
  45. package/build/src/modeling/Bindings.d.ts +2 -2
  46. package/build/src/modeling/Bindings.d.ts.map +1 -1
  47. package/build/src/modeling/Bindings.js.map +1 -1
  48. package/build/src/modeling/DataDomain.d.ts +601 -0
  49. package/build/src/modeling/DataDomain.d.ts.map +1 -0
  50. package/build/src/modeling/DataDomain.js +1142 -0
  51. package/build/src/modeling/DataDomain.js.map +1 -0
  52. package/build/src/modeling/DataFormat.d.ts +42 -41
  53. package/build/src/modeling/DataFormat.d.ts.map +1 -1
  54. package/build/src/modeling/DataFormat.js +30 -131
  55. package/build/src/modeling/DataFormat.js.map +1 -1
  56. package/build/src/modeling/DomainAssociation.d.ts +281 -0
  57. package/build/src/modeling/DomainAssociation.d.ts.map +1 -0
  58. package/build/src/modeling/DomainAssociation.js +440 -0
  59. package/build/src/modeling/DomainAssociation.js.map +1 -0
  60. package/build/src/modeling/DomainElement.d.ts +33 -0
  61. package/build/src/modeling/DomainElement.d.ts.map +1 -0
  62. package/build/src/modeling/DomainElement.js +32 -0
  63. package/build/src/modeling/DomainElement.js.map +1 -0
  64. package/build/src/modeling/DomainEntity.d.ts +383 -0
  65. package/build/src/modeling/DomainEntity.d.ts.map +1 -0
  66. package/build/src/modeling/DomainEntity.js +718 -0
  67. package/build/src/modeling/DomainEntity.js.map +1 -0
  68. package/build/src/modeling/DomainFile.d.ts +25 -0
  69. package/build/src/modeling/DomainFile.d.ts.map +1 -0
  70. package/build/src/modeling/DomainFile.js +86 -0
  71. package/build/src/modeling/DomainFile.js.map +1 -0
  72. package/build/src/modeling/DomainImpactAnalysis.d.ts +60 -47
  73. package/build/src/modeling/DomainImpactAnalysis.d.ts.map +1 -1
  74. package/build/src/modeling/DomainImpactAnalysis.js +201 -132
  75. package/build/src/modeling/DomainImpactAnalysis.js.map +1 -1
  76. package/build/src/modeling/DomainModel.d.ts +226 -0
  77. package/build/src/modeling/DomainModel.d.ts.map +1 -0
  78. package/build/src/modeling/DomainModel.js +401 -0
  79. package/build/src/modeling/DomainModel.js.map +1 -0
  80. package/build/src/modeling/DomainNamespace.d.ts +268 -0
  81. package/build/src/modeling/DomainNamespace.d.ts.map +1 -0
  82. package/build/src/modeling/DomainNamespace.js +512 -0
  83. package/build/src/modeling/DomainNamespace.js.map +1 -0
  84. package/build/src/modeling/DomainProperty.d.ts +281 -0
  85. package/build/src/modeling/DomainProperty.d.ts.map +1 -0
  86. package/build/src/modeling/DomainProperty.js +560 -0
  87. package/build/src/modeling/DomainProperty.js.map +1 -0
  88. package/build/src/modeling/DomainSerialization.d.ts +40 -0
  89. package/build/src/modeling/DomainSerialization.d.ts.map +1 -0
  90. package/build/src/modeling/DomainSerialization.js +288 -0
  91. package/build/src/modeling/DomainSerialization.js.map +1 -0
  92. package/build/src/modeling/DomainVersioning.d.ts +17 -0
  93. package/build/src/modeling/DomainVersioning.d.ts.map +1 -0
  94. package/build/src/modeling/DomainVersioning.js +124 -0
  95. package/build/src/modeling/DomainVersioning.js.map +1 -0
  96. package/build/src/modeling/GraphUtils.d.ts +8 -0
  97. package/build/src/modeling/GraphUtils.d.ts.map +1 -0
  98. package/build/src/modeling/GraphUtils.js +26 -0
  99. package/build/src/modeling/GraphUtils.js.map +1 -0
  100. package/build/src/modeling/amf/ShapeGenerator.d.ts +164 -0
  101. package/build/src/modeling/amf/ShapeGenerator.d.ts.map +1 -0
  102. package/build/src/modeling/amf/ShapeGenerator.js +492 -0
  103. package/build/src/modeling/amf/ShapeGenerator.js.map +1 -0
  104. package/build/src/modeling/{DataAssociation.d.ts → legacy/DataAssociation.d.ts} +10 -5
  105. package/build/src/modeling/legacy/DataAssociation.d.ts.map +1 -0
  106. package/build/src/modeling/{DataAssociation.js → legacy/DataAssociation.js} +9 -6
  107. package/build/src/modeling/legacy/DataAssociation.js.map +1 -0
  108. package/build/src/modeling/{DataEntity.d.ts → legacy/DataEntity.d.ts} +12 -7
  109. package/build/src/modeling/legacy/DataEntity.d.ts.map +1 -0
  110. package/build/src/modeling/{DataEntity.js → legacy/DataEntity.js} +19 -18
  111. package/build/src/modeling/legacy/DataEntity.js.map +1 -0
  112. package/build/src/modeling/{DataEntityBuilder.d.ts → legacy/DataEntityBuilder.d.ts} +3 -2
  113. package/build/src/modeling/legacy/DataEntityBuilder.d.ts.map +1 -0
  114. package/build/src/modeling/{DataEntityBuilder.js → legacy/DataEntityBuilder.js} +3 -2
  115. package/build/src/modeling/legacy/DataEntityBuilder.js.map +1 -0
  116. package/build/src/modeling/legacy/DataImpactAnalysis.d.ts +298 -0
  117. package/build/src/modeling/legacy/DataImpactAnalysis.d.ts.map +1 -0
  118. package/build/src/modeling/legacy/DataImpactAnalysis.js +441 -0
  119. package/build/src/modeling/legacy/DataImpactAnalysis.js.map +1 -0
  120. package/build/src/modeling/{DataModel.d.ts → legacy/DataModel.d.ts} +6 -4
  121. package/build/src/modeling/legacy/DataModel.d.ts.map +1 -0
  122. package/build/src/modeling/{DataModel.js → legacy/DataModel.js} +7 -6
  123. package/build/src/modeling/legacy/DataModel.js.map +1 -0
  124. package/build/src/modeling/{DataNamespace.d.ts → legacy/DataNamespace.d.ts} +22 -3
  125. package/build/src/modeling/legacy/DataNamespace.d.ts.map +1 -0
  126. package/build/src/modeling/{DataNamespace.js → legacy/DataNamespace.js} +7 -3
  127. package/build/src/modeling/legacy/DataNamespace.js.map +1 -0
  128. package/build/src/modeling/{DataProperty.d.ts → legacy/DataProperty.d.ts} +13 -5
  129. package/build/src/modeling/legacy/DataProperty.d.ts.map +1 -0
  130. package/build/src/modeling/{DataProperty.js → legacy/DataProperty.js} +8 -5
  131. package/build/src/modeling/legacy/DataProperty.js.map +1 -0
  132. package/build/src/modeling/observed.d.ts +67 -0
  133. package/build/src/modeling/observed.d.ts.map +1 -0
  134. package/build/src/modeling/observed.js +230 -0
  135. package/build/src/modeling/observed.js.map +1 -0
  136. package/build/src/modeling/types.d.ts +165 -1
  137. package/build/src/modeling/types.d.ts.map +1 -1
  138. package/build/src/modeling/types.js.map +1 -1
  139. package/build/src/models/Thing.d.ts +26 -5
  140. package/build/src/models/Thing.d.ts.map +1 -1
  141. package/build/src/models/Thing.js +193 -91
  142. package/build/src/models/Thing.js.map +1 -1
  143. package/build/src/models/kinds.d.ts +31 -6
  144. package/build/src/models/kinds.d.ts.map +1 -1
  145. package/build/src/models/kinds.js +31 -6
  146. package/build/src/models/kinds.js.map +1 -1
  147. package/build/src/models/store/DataFile.d.ts +3 -1
  148. package/build/src/models/store/DataFile.d.ts.map +1 -1
  149. package/build/src/models/store/DataFile.js +2 -0
  150. package/build/src/models/store/DataFile.js.map +1 -1
  151. package/build/src/models/types.d.ts +12 -0
  152. package/build/src/models/types.d.ts.map +1 -0
  153. package/build/src/models/types.js +2 -0
  154. package/build/src/models/types.js.map +1 -0
  155. package/build/src/runtime/store/FilesSdk.d.ts +2 -2
  156. package/build/src/runtime/store/FilesSdk.d.ts.map +1 -1
  157. package/build/src/runtime/store/FilesSdk.js.map +1 -1
  158. package/data/models/example-generator-api.json +16 -16
  159. package/package.json +20 -6
  160. package/readme.md +1 -1
  161. package/src/amf/AmfShapeGenerator.ts +7 -4
  162. package/src/amf/AmfTypes.ts +2 -2
  163. package/src/amf/DataValueGenerator.ts +21 -21
  164. package/src/exceptions/attach_exception.ts +11 -0
  165. package/src/exceptions/detach_exception.ts +11 -0
  166. package/src/exceptions/remove_model_exception.ts +8 -0
  167. package/src/exceptions/remove_namespace_exception.ts +8 -0
  168. package/src/modeling/Bindings.ts +2 -2
  169. package/src/modeling/DataDomain.ts +1221 -0
  170. package/src/modeling/DataFormat.ts +54 -163
  171. package/src/modeling/DomainAssociation.ts +476 -0
  172. package/src/modeling/DomainElement.ts +50 -0
  173. package/src/modeling/DomainEntity.ts +769 -0
  174. package/src/modeling/DomainFile.ts +94 -0
  175. package/src/modeling/DomainImpactAnalysis.ts +218 -144
  176. package/src/modeling/DomainModel.ts +421 -0
  177. package/src/modeling/DomainNamespace.ts +537 -0
  178. package/src/modeling/DomainProperty.ts +548 -0
  179. package/src/modeling/DomainSerialization.ts +312 -0
  180. package/src/modeling/DomainVersioning.ts +144 -0
  181. package/src/modeling/GraphUtils.ts +28 -0
  182. package/src/modeling/amf/ShapeGenerator.ts +552 -0
  183. package/src/modeling/graph.md +115 -0
  184. package/src/modeling/{DataAssociation.ts → legacy/DataAssociation.ts} +13 -8
  185. package/src/modeling/{DataEntity.ts → legacy/DataEntity.ts} +28 -23
  186. package/src/modeling/{DataEntityBuilder.ts → legacy/DataEntityBuilder.ts} +4 -3
  187. package/src/modeling/legacy/DataImpactAnalysis.ts +530 -0
  188. package/src/modeling/{DataModel.ts → legacy/DataModel.ts} +10 -8
  189. package/src/modeling/{DataNamespace.ts → legacy/DataNamespace.ts} +23 -5
  190. package/src/modeling/{DataProperty.ts → legacy/DataProperty.ts} +15 -7
  191. package/src/modeling/observed.ts +267 -0
  192. package/src/modeling/types.ts +174 -1
  193. package/src/models/Thing.ts +70 -5
  194. package/src/models/kinds.ts +32 -6
  195. package/src/models/store/DataFile.ts +3 -1
  196. package/src/models/types.ts +11 -0
  197. package/src/runtime/store/FilesSdk.ts +2 -2
  198. package/tests/unit/amf/data_value_generator.spec.ts +15 -15
  199. package/tests/unit/legacy-transformers/ARC-legacy-import.spec.ts +1 -1
  200. package/tests/unit/modeling/amf/shape_generator.spec.ts +1174 -0
  201. package/tests/unit/modeling/data_domain.spec.ts +444 -0
  202. package/tests/unit/modeling/data_domain_associations.spec.ts +279 -0
  203. package/tests/unit/modeling/data_domain_change_observers.spec.ts +681 -0
  204. package/tests/unit/modeling/data_domain_entities.spec.ts +449 -0
  205. package/tests/unit/modeling/data_domain_foreign.spec.ts +355 -0
  206. package/tests/unit/modeling/data_domain_models.spec.ts +658 -0
  207. package/tests/unit/modeling/data_domain_namespaces.spec.ts +668 -0
  208. package/tests/unit/modeling/data_domain_property.spec.ts +264 -0
  209. package/tests/unit/modeling/data_domain_serialization.spec.ts +294 -0
  210. package/tests/unit/modeling/domain.property.spec.ts +822 -0
  211. package/tests/unit/modeling/domain_asociation.spec.ts +643 -0
  212. package/tests/unit/modeling/domain_asociation_targets.spec.ts +350 -0
  213. package/tests/unit/modeling/domain_entity.spec.ts +730 -0
  214. package/tests/unit/modeling/domain_entity_associations.spec.ts +330 -0
  215. package/tests/unit/modeling/domain_entity_example_generator_json.spec.ts +988 -0
  216. package/tests/unit/modeling/domain_entity_example_generator_xml.spec.ts +1451 -0
  217. package/tests/unit/modeling/domain_entity_fields.spec.ts +113 -0
  218. package/tests/unit/modeling/domain_entity_generators.spec.ts +20 -0
  219. package/tests/unit/modeling/domain_entity_parents.spec.ts +291 -0
  220. package/tests/unit/modeling/domain_entity_properties.spec.ts +305 -0
  221. package/tests/unit/modeling/{data_file.spec.ts → domain_file.spec.ts} +29 -85
  222. package/tests/unit/modeling/domain_impact_analysis.spec.ts +452 -0
  223. package/tests/unit/modeling/domain_model.spec.ts +568 -0
  224. package/tests/unit/modeling/domain_model_entities.spec.ts +408 -0
  225. package/tests/unit/modeling/domain_namespace.spec.ts +514 -0
  226. package/tests/unit/modeling/domain_namespace_models.spec.ts +324 -0
  227. package/tests/unit/modeling/domain_namespace_namespaces.spec.ts +404 -0
  228. package/tests/unit/modeling/domain_versioning.spec.ts +140 -0
  229. package/tests/unit/{amf → modeling/legacy}/amf_shape_generator.spec.ts +11 -11
  230. package/tests/unit/modeling/{data_association.spec.ts → legacy/data_association.spec.ts} +3 -11
  231. package/tests/unit/modeling/{data_entity.spec.ts → legacy/data_entity.spec.ts} +10 -8
  232. package/tests/unit/modeling/{data_entity_generator_json.spec.ts → legacy/data_entity_generator_json.spec.ts} +1 -1
  233. package/tests/unit/modeling/{data_entity_generator_xml.spec.ts → legacy/data_entity_generator_xml.spec.ts} +1 -1
  234. package/tests/unit/modeling/{data_model.spec.ts → legacy/data_model.spec.ts} +3 -3
  235. package/tests/unit/modeling/{data_namespace.spec.ts → legacy/data_namespace.spec.ts} +3 -10
  236. package/tests/unit/modeling/{data_property.spec.ts → legacy/data_property.spec.ts} +3 -6
  237. package/tests/unit/modeling/{impact_analysis.spec.ts → legacy/impact_analysis.spec.ts} +9 -9
  238. package/tests/unit/models/File/new.spec.ts +1 -1
  239. package/tests/unit/models/HttpProject.spec.ts +3 -3
  240. package/tsconfig.node.json +35 -0
  241. package/build/src/modeling/DataAssociation.d.ts.map +0 -1
  242. package/build/src/modeling/DataAssociation.js.map +0 -1
  243. package/build/src/modeling/DataEntity.d.ts.map +0 -1
  244. package/build/src/modeling/DataEntity.js.map +0 -1
  245. package/build/src/modeling/DataEntityBuilder.d.ts.map +0 -1
  246. package/build/src/modeling/DataEntityBuilder.js.map +0 -1
  247. package/build/src/modeling/DataModel.d.ts.map +0 -1
  248. package/build/src/modeling/DataModel.js.map +0 -1
  249. package/build/src/modeling/DataNamespace.d.ts.map +0 -1
  250. package/build/src/modeling/DataNamespace.js.map +0 -1
  251. package/build/src/modeling/DataProperty.d.ts.map +0 -1
  252. package/build/src/modeling/DataProperty.js.map +0 -1
@@ -1,103 +1,205 @@
1
+ import { __esDecorate, __runInitializers } from "tslib";
1
2
  import { ThingKind } from './kinds.js';
2
- export class Thing {
3
- kind = ThingKind;
4
- /**
5
- * The name of the thing.
6
- */
7
- name;
8
- /**
9
- * Optional value to overwrite the `name` in the UI.
10
- * The primary descriptive field is the `name`. The display name is only used in the presentation of the data.
11
- */
12
- displayName;
13
- /**
14
- * The description of the thing.
15
- */
16
- description;
17
- /**
18
- * The version number of the thing.
19
- */
20
- version;
21
- /**
22
- * Returns one in this order:
23
- * - displayName
24
- * - name
25
- * - 'Unnamed object'
26
- */
27
- get renderLabel() {
28
- return this.displayName || this.name || 'Unnamed object';
29
- }
30
- /**
31
- * Creates a basic description from a name.
32
- */
33
- static fromName(name) {
34
- const thing = new Thing({
35
- name,
36
- kind: ThingKind,
37
- });
38
- return thing;
39
- }
40
- /**
41
- * @param input The thing definition used to restore the state.
42
- */
43
- constructor(input) {
44
- let init;
45
- if (typeof input === 'string') {
46
- init = JSON.parse(input);
3
+ import { observed } from '../modeling/observed.js';
4
+ let Thing = (() => {
5
+ let _classSuper = EventTarget;
6
+ let _name_decorators;
7
+ let _name_initializers = [];
8
+ let _name_extraInitializers = [];
9
+ let _displayName_decorators;
10
+ let _displayName_initializers = [];
11
+ let _displayName_extraInitializers = [];
12
+ let _description_decorators;
13
+ let _description_initializers = [];
14
+ let _description_extraInitializers = [];
15
+ let _version_decorators;
16
+ let _version_initializers = [];
17
+ let _version_extraInitializers = [];
18
+ return class Thing extends _classSuper {
19
+ static {
20
+ const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
21
+ _name_decorators = [observed()];
22
+ _displayName_decorators = [observed()];
23
+ _description_decorators = [observed()];
24
+ _version_decorators = [observed()];
25
+ __esDecorate(this, null, _name_decorators, { kind: "accessor", name: "name", static: false, private: false, access: { has: obj => "name" in obj, get: obj => obj.name, set: (obj, value) => { obj.name = value; } }, metadata: _metadata }, _name_initializers, _name_extraInitializers);
26
+ __esDecorate(this, null, _displayName_decorators, { kind: "accessor", name: "displayName", static: false, private: false, access: { has: obj => "displayName" in obj, get: obj => obj.displayName, set: (obj, value) => { obj.displayName = value; } }, metadata: _metadata }, _displayName_initializers, _displayName_extraInitializers);
27
+ __esDecorate(this, null, _description_decorators, { kind: "accessor", name: "description", static: false, private: false, access: { has: obj => "description" in obj, get: obj => obj.description, set: (obj, value) => { obj.description = value; } }, metadata: _metadata }, _description_initializers, _description_extraInitializers);
28
+ __esDecorate(this, null, _version_decorators, { kind: "accessor", name: "version", static: false, private: false, access: { has: obj => "version" in obj, get: obj => obj.version, set: (obj, value) => { obj.version = value; } }, metadata: _metadata }, _version_initializers, _version_extraInitializers);
29
+ if (_metadata) Object.defineProperty(this, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
47
30
  }
48
- else if (typeof input === 'object') {
49
- init = input;
31
+ kind = ThingKind;
32
+ #name_accessor_storage = __runInitializers(this, _name_initializers, void 0);
33
+ /**
34
+ * The name of the thing.
35
+ */
36
+ get name() { return this.#name_accessor_storage; }
37
+ set name(value) { this.#name_accessor_storage = value; }
38
+ #displayName_accessor_storage = (__runInitializers(this, _name_extraInitializers), __runInitializers(this, _displayName_initializers, void 0));
39
+ /**
40
+ * Optional value to overwrite the `name` in the UI.
41
+ * The primary descriptive field is the `name`. The display name is only used in the presentation of the data.
42
+ */
43
+ get displayName() { return this.#displayName_accessor_storage; }
44
+ set displayName(value) { this.#displayName_accessor_storage = value; }
45
+ #description_accessor_storage = (__runInitializers(this, _displayName_extraInitializers), __runInitializers(this, _description_initializers, void 0));
46
+ /**
47
+ * The description of the thing.
48
+ */
49
+ get description() { return this.#description_accessor_storage; }
50
+ set description(value) { this.#description_accessor_storage = value; }
51
+ #version_accessor_storage = (__runInitializers(this, _description_extraInitializers), __runInitializers(this, _version_initializers, void 0));
52
+ /**
53
+ * The version number of the thing.
54
+ */
55
+ get version() { return this.#version_accessor_storage; }
56
+ set version(value) { this.#version_accessor_storage = value; }
57
+ /**
58
+ * Returns one in this order:
59
+ * - displayName
60
+ * - name
61
+ * - 'Unnamed object'
62
+ *
63
+ * @deprecated Use `getLabel()` instead.
64
+ */
65
+ get renderLabel() {
66
+ return this.displayName || this.name || 'Unnamed object';
50
67
  }
51
- else {
52
- init = {
68
+ /**
69
+ * Creates a basic description from a name.
70
+ */
71
+ static fromName(name) {
72
+ const thing = new Thing({
73
+ name,
53
74
  kind: ThingKind,
54
- };
75
+ });
76
+ return thing;
77
+ }
78
+ /**
79
+ * Creates a new thing instance.
80
+ *
81
+ * @param input The thing definition used to restore the state.
82
+ */
83
+ static fromJSON(input = {}, defaults = {}) {
84
+ const result = new Thing();
85
+ const { name, displayName, description, version } = input || {};
86
+ if (typeof name === 'string') {
87
+ result.name = name;
88
+ }
89
+ else if (typeof defaults.name === 'string') {
90
+ result.name = defaults.name;
91
+ }
92
+ if (typeof displayName === 'string') {
93
+ result.displayName = displayName;
94
+ }
95
+ else if (typeof defaults.displayName === 'string') {
96
+ result.displayName = defaults.displayName;
97
+ }
98
+ if (description) {
99
+ result.description = description;
100
+ }
101
+ else if (typeof defaults.description === 'string') {
102
+ result.description = defaults.description;
103
+ }
104
+ if (version) {
105
+ result.version = version;
106
+ }
107
+ else if (typeof defaults.version === 'string') {
108
+ result.version = defaults.version;
109
+ }
110
+ return result;
111
+ }
112
+ /**
113
+ * @param input The thing definition used to restore the state.
114
+ */
115
+ constructor(input) {
116
+ super();
117
+ __runInitializers(this, _version_extraInitializers);
118
+ let init;
119
+ if (typeof input === 'string') {
120
+ init = JSON.parse(input);
121
+ }
122
+ else if (typeof input === 'object') {
123
+ init = input;
124
+ }
125
+ else {
126
+ init = {
127
+ kind: ThingKind,
128
+ };
129
+ }
130
+ this.new(init);
55
131
  }
56
- this.new(init);
57
- }
58
- /**
59
- * Creates a new thing clearing anything that is so far defined.
60
- *
61
- * Note, this throws an error when the server is not a thing.
62
- */
63
- new(init) {
64
- if (!Thing.isThing(init)) {
65
- throw new Error(`Not a thing.`);
132
+ /**
133
+ * Creates a new thing clearing anything that is so far defined.
134
+ *
135
+ * Note, this throws an error when the server is not a thing.
136
+ */
137
+ new(init) {
138
+ if (!Thing.isThing(init)) {
139
+ throw new Error(`Not a thing.`);
140
+ }
141
+ const { description, name, version, displayName } = init;
142
+ this.kind = ThingKind;
143
+ this.name = name;
144
+ this.displayName = displayName;
145
+ this.description = description;
146
+ this.version = version;
66
147
  }
67
- const { description, name, version, displayName } = init;
68
- this.kind = ThingKind;
69
- this.name = name;
70
- this.displayName = displayName;
71
- this.description = description;
72
- this.version = version;
73
- }
74
- /**
75
- * Checks whether the input is a definition of a server.
76
- */
77
- static isThing(input) {
78
- const typed = input;
79
- if (input && typed.kind === ThingKind) {
80
- return true;
148
+ notifyChange() {
149
+ this.dispatchEvent(new Event('change'));
81
150
  }
82
- return false;
83
- }
84
- toJSON() {
85
- const result = {
86
- kind: ThingKind,
87
- };
88
- if (typeof this.name === 'string') {
89
- result.name = this.name;
151
+ static validate(input, options = {}) {
152
+ const { strict } = options;
153
+ if (input && typeof input === 'object') {
154
+ const typed = input;
155
+ if (strict && typed.kind !== ThingKind) {
156
+ return false;
157
+ }
158
+ return true;
159
+ }
160
+ return false;
90
161
  }
91
- if (typeof this.displayName === 'string') {
92
- result.displayName = this.displayName;
162
+ /**
163
+ * Checks whether the input is a definition of a server.
164
+ */
165
+ static isThing(input) {
166
+ const typed = input;
167
+ if (input && typed.kind === ThingKind) {
168
+ return true;
169
+ }
170
+ return false;
93
171
  }
94
- if (this.description) {
95
- result.description = this.description;
172
+ toJSON() {
173
+ const result = {
174
+ kind: ThingKind,
175
+ };
176
+ if (typeof this.name === 'string') {
177
+ result.name = this.name;
178
+ }
179
+ if (typeof this.displayName === 'string') {
180
+ result.displayName = this.displayName;
181
+ }
182
+ if (this.description) {
183
+ result.description = this.description;
184
+ }
185
+ if (this.version) {
186
+ result.version = this.version;
187
+ }
188
+ return result;
96
189
  }
97
- if (this.version) {
98
- result.version = this.version;
190
+ /**
191
+ * Returns one in this order:
192
+ * - `this.displayName`
193
+ * - `this.name`
194
+ * - `defaultName`
195
+ * - 'Unnamed object'
196
+ *
197
+ * @param defaultName The default name to use when no other is available.
198
+ */
199
+ getLabel(defaultName) {
200
+ return this.displayName || this.name || defaultName || 'Unnamed object';
99
201
  }
100
- return result;
101
- }
102
- }
202
+ };
203
+ })();
204
+ export { Thing };
103
205
  //# sourceMappingURL=Thing.js.map
@@ -1 +1 @@
1
- {"version":3,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;QACxD,IAAI,CAAC,IAAI,GAAG,SAAS,CAAA;QACrB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAA;QAChB,IAAI,CAAC,WAAW,GAAG,WAAW,CAAA;QAC9B,IAAI,CAAC,WAAW,GAAG,WAAW,CAAA;QAC9B,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;IACxB,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,OAAO,CAAC,KAAc;QAC3B,MAAM,KAAK,GAAG,KAAe,CAAA;QAC7B,IAAI,KAAK,IAAI,KAAK,CAAC,IAAI,KAAK,SAAS,EAAE,CAAC;YACtC,OAAO,IAAI,CAAA;QACb,CAAC;QACD,OAAO,KAAK,CAAA;IACd,CAAC;IAED,MAAM;QACJ,MAAM,MAAM,GAAW;YACrB,IAAI,EAAE,SAAS;SAChB,CAAA;QACD,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;YAClC,MAAM,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAA;QACzB,CAAC;QACD,IAAI,OAAO,IAAI,CAAC,WAAW,KAAK,QAAQ,EAAE,CAAC;YACzC,MAAM,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,CAAA;QACvC,CAAC;QACD,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;YACrB,MAAM,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,CAAA;QACvC,CAAC;QACD,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;YACjB,MAAM,CAAC,OAAO,GAAG,IAAI,CAAC,OAAO,CAAA;QAC/B,CAAC;QACD,OAAO,MAAM,CAAA;IACf,CAAC;CACF","sourcesContent":["import { ThingKind } from './kinds.js'\n\n/**\n * An interface describing a base metadata of a thing.\n */\nexport declare interface IThing {\n /**\n * The data kind. The application ignores the input with an unknown `kind`, unless\n * it can be determined from the context.\n */\n kind?: typeof ThingKind\n /**\n * The name of the thing.\n */\n name?: string\n /**\n * Optional value to overwrite the `name` in the UI.\n * The primary descriptive field is the `name`. The display name is only used in the presentation of the data.\n */\n displayName?: string\n /**\n * The description of the thing.\n */\n description?: string\n /**\n * The version number of the thing.\n */\n version?: string\n}\n\nexport class Thing {\n kind = ThingKind\n /**\n * The name of the thing.\n */\n name?: string\n /**\n * Optional value to overwrite the `name` in the UI.\n * The primary descriptive field is the `name`. The display name is only used in the presentation of the data.\n */\n displayName?: string\n /**\n * The description of the thing.\n */\n description?: string\n /**\n * The version number of the thing.\n */\n version?: string\n\n /**\n * Returns one in this order:\n * - displayName\n * - name\n * - 'Unnamed object'\n */\n get renderLabel(): string {\n return this.displayName || this.name || 'Unnamed object'\n }\n\n /**\n * Creates a basic description from a name.\n */\n static fromName(name: string): Thing {\n const thing = new Thing({\n name,\n kind: ThingKind,\n })\n return thing\n }\n\n /**\n * @param input The thing definition used to restore the state.\n */\n constructor(input?: string | IThing) {\n let init: IThing\n if (typeof input === 'string') {\n init = JSON.parse(input)\n } else if (typeof input === 'object') {\n init = input\n } else {\n init = {\n kind: ThingKind,\n }\n }\n this.new(init)\n }\n\n /**\n * Creates a new thing clearing anything that is so far defined.\n *\n * Note, this throws an error when the server is not a thing.\n */\n new(init: IThing): void {\n if (!Thing.isThing(init)) {\n throw new Error(`Not a thing.`)\n }\n const { description, name, version, displayName } = init\n this.kind = ThingKind\n this.name = name\n this.displayName = displayName\n this.description = description\n this.version = version\n }\n\n /**\n * Checks whether the input is a definition of a server.\n */\n static isThing(input: unknown): boolean {\n const typed = input as IThing\n if (input && typed.kind === ThingKind) {\n return true\n }\n return false\n }\n\n toJSON(): IThing {\n const result: IThing = {\n kind: ThingKind,\n }\n if (typeof this.name === 'string') {\n result.name = this.name\n }\n if (typeof this.displayName === 'string') {\n result.displayName = this.displayName\n }\n if (this.description) {\n result.description = this.description\n }\n if (this.version) {\n result.version = this.version\n }\n return result\n }\n}\n"]}
1
+ {"version":3,"file":"Thing.js","sourceRoot":"","sources":["../../../src/models/Thing.ts"],"names":[],"mappings":";AAAA,OAAO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AAG,KAAe,CAAA;YAC7B,IAAI,KAAK,IAAI,KAAK,CAAC,IAAI,KAAK,SAAS,EAAE,CAAC;gBACtC,OAAO,IAAI,CAAA;YACb,CAAC;YACD,OAAO,KAAK,CAAA;QACd,CAAC;QAED,MAAM;YACJ,MAAM,MAAM,GAAW;gBACrB,IAAI,EAAE,SAAS;aAChB,CAAA;YACD,IAAI,OAAO,IAAI,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;gBAClC,MAAM,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAA;YACzB,CAAC;YACD,IAAI,OAAO,IAAI,CAAC,WAAW,KAAK,QAAQ,EAAE,CAAC;gBACzC,MAAM,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,CAAA;YACvC,CAAC;YACD,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;gBACrB,MAAM,CAAC,WAAW,GAAG,IAAI,CAAC,WAAW,CAAA;YACvC,CAAC;YACD,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;gBACjB,MAAM,CAAC,OAAO,GAAG,IAAI,CAAC,OAAO,CAAA;YAC/B,CAAC;YACD,OAAO,MAAM,CAAA;QACf,CAAC;QAED;;;;;;;;WAQG;QACH,QAAQ,CAAC,WAAoB;YAC3B,OAAO,IAAI,CAAC,WAAW,IAAI,IAAI,CAAC,IAAI,IAAI,WAAW,IAAI,gBAAgB,CAAA;QACzE,CAAC;;;SAtKU,KAAK","sourcesContent":["import { ThingKind } from './kinds.js'\nimport { ModelValidationOptions } from './types.js'\nimport { observed } from '../modeling/observed.js'\n\n/**\n * An interface describing a base metadata of a thing.\n */\nexport declare interface IThing {\n /**\n * The data kind. The application ignores the input with an unknown `kind`, unless\n * it can be determined from the context.\n */\n kind?: typeof ThingKind\n /**\n * The name of the thing.\n */\n name?: string\n /**\n * Optional value to overwrite the `name` in the UI.\n * The primary descriptive field is the `name`. The display name is only used in the presentation of the data.\n */\n displayName?: string\n /**\n * The description of the thing.\n */\n description?: string\n /**\n * The version number of the thing.\n */\n version?: string\n}\n\nexport class Thing extends EventTarget {\n kind = ThingKind\n /**\n * The name of the thing.\n */\n @observed() accessor name: string | undefined\n /**\n * Optional value to overwrite the `name` in the UI.\n * The primary descriptive field is the `name`. The display name is only used in the presentation of the data.\n */\n @observed() accessor displayName: string | undefined\n /**\n * The description of the thing.\n */\n @observed() accessor description: string | undefined\n /**\n * The version number of the thing.\n */\n @observed() accessor version: string | undefined\n\n /**\n * Returns one in this order:\n * - displayName\n * - name\n * - 'Unnamed object'\n *\n * @deprecated Use `getLabel()` instead.\n */\n get renderLabel(): string {\n return this.displayName || this.name || 'Unnamed object'\n }\n\n /**\n * Creates a basic description from a name.\n */\n static fromName(name: string): Thing {\n const thing = new Thing({\n name,\n kind: ThingKind,\n })\n return thing\n }\n\n /**\n * Creates a new thing instance.\n *\n * @param input The thing definition used to restore the state.\n */\n static fromJSON(input: Partial<IThing> = {}, defaults: Partial<IThing> = {}): Thing {\n const result = new Thing()\n const { name, displayName, description, version } = input || {}\n if (typeof name === 'string') {\n result.name = name\n } else if (typeof defaults.name === 'string') {\n result.name = defaults.name\n }\n if (typeof displayName === 'string') {\n result.displayName = displayName\n } else if (typeof defaults.displayName === 'string') {\n result.displayName = defaults.displayName\n }\n if (description) {\n result.description = description\n } else if (typeof defaults.description === 'string') {\n result.description = defaults.description\n }\n if (version) {\n result.version = version\n } else if (typeof defaults.version === 'string') {\n result.version = defaults.version\n }\n return result\n }\n\n /**\n * @param input The thing definition used to restore the state.\n */\n constructor(input?: string | IThing) {\n super()\n let init: IThing\n if (typeof input === 'string') {\n init = JSON.parse(input)\n } else if (typeof input === 'object') {\n init = input\n } else {\n init = {\n kind: ThingKind,\n }\n }\n this.new(init)\n }\n\n /**\n * Creates a new thing clearing anything that is so far defined.\n *\n * Note, this throws an error when the server is not a thing.\n */\n new(init: IThing): void {\n if (!Thing.isThing(init)) {\n throw new Error(`Not a thing.`)\n }\n const { description, name, version, displayName } = init\n this.kind = ThingKind\n this.name = name\n this.displayName = displayName\n this.description = description\n this.version = version\n }\n\n notifyChange(): void {\n this.dispatchEvent(new Event('change'))\n }\n\n static validate(input: unknown, options: ModelValidationOptions = {}): boolean {\n const { strict } = options\n if (input && typeof input === 'object') {\n const typed = input as IThing\n if (strict && typed.kind !== ThingKind) {\n return false\n }\n return true\n }\n return false\n }\n\n /**\n * Checks whether the input is a definition of a server.\n */\n static isThing(input: unknown): boolean {\n const typed = input as IThing\n if (input && typed.kind === ThingKind) {\n return true\n }\n return false\n }\n\n toJSON(): IThing {\n const result: IThing = {\n kind: ThingKind,\n }\n if (typeof this.name === 'string') {\n result.name = this.name\n }\n if (typeof this.displayName === 'string') {\n result.displayName = this.displayName\n }\n if (this.description) {\n result.description = this.description\n }\n if (this.version) {\n result.version = this.version\n }\n return result\n }\n\n /**\n * Returns one in this order:\n * - `this.displayName`\n * - `this.name`\n * - `defaultName`\n * - 'Unnamed object'\n *\n * @param defaultName The default name to use when no other is available.\n */\n getLabel(defaultName?: string): string {\n return this.displayName || this.name || defaultName || 'Unnamed object'\n }\n}\n"]}
@@ -2,17 +2,42 @@ export declare const ProjectFolderKind = "Core#ProjectFolder";
2
2
  export declare const ResponseKind = "Core#HttpResponse";
3
3
  export declare const HttpResponseKind = "Core#HttpResponse";
4
4
  export declare const CertificateFileKind = "Core#CertificateFile";
5
- export declare const DataNamespaceKind = "Core#DataNamespace";
6
- export declare const DataModelKind = "Core#DataModel";
7
- export declare const DataEntityKind = "Core#DataEntity";
8
- export declare const DataAssociationKind = "Core#DataAssociation";
9
- export declare const DataPropertyKind = "Core#DataProperty";
10
5
  export declare const FolderKind = "Core#Folder";
11
6
  export declare const ProjectKind = "Core#Project";
12
7
  export declare const ThingKind = "Core#Thing";
13
- export declare const DataFileKind = "Core#DataFile";
14
8
  export declare const DeletionKind = "Core#Deletion";
15
9
  export declare const RevisionKind = "Core#Revision";
16
10
  export declare const UnresolvedDependencyKind = "Core#UnresolvedDependency";
17
11
  export declare const UserKind = "Core#User";
12
+ export declare const DomainFileKind = "Data#DomainFile";
13
+ export declare const DataDomainKind = "Data#Domain";
14
+ export declare const DomainNamespaceKind = "Domain#Namespace";
15
+ export declare const DomainModelKind = "Domain#Model";
16
+ export declare const DomainEntityKind = "Domain#Entity";
17
+ export declare const DomainAssociationKind = "Domain#Association";
18
+ export declare const DomainPropertyKind = "Domain#Property";
19
+ /**
20
+ * @deprecated Not used anymore.
21
+ */
22
+ export declare const DataFileKind = "Core#DataFile";
23
+ /**
24
+ * @deprecated Not used anymore.
25
+ */
26
+ export declare const DataNamespaceKind = "Data#DataNamespace";
27
+ /**
28
+ * @deprecated Not used anymore.
29
+ */
30
+ export declare const DataModelKind = "Data#DataModel";
31
+ /**
32
+ * @deprecated Not used anymore.
33
+ */
34
+ export declare const DataEntityKind = "Data#DataEntity";
35
+ /**
36
+ * @deprecated Not used anymore.
37
+ */
38
+ export declare const DataAssociationKind = "Data#DataAssociation";
39
+ /**
40
+ * @deprecated Not used anymore.
41
+ */
42
+ export declare const DataPropertyKind = "Data#DataProperty";
18
43
  //# sourceMappingURL=kinds.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"kinds.d.ts","sourceRoot":"","sources":["../../../src/models/kinds.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,iBAAiB,uBAAuB,CAAA;AACrD,eAAO,MAAM,YAAY,sBAAsB,CAAA;AAC/C,eAAO,MAAM,gBAAgB,sBAAsB,CAAA;AACnD,eAAO,MAAM,mBAAmB,yBAAyB,CAAA;AACzD,eAAO,MAAM,iBAAiB,uBAAuB,CAAA;AACrD,eAAO,MAAM,aAAa,mBAAmB,CAAA;AAC7C,eAAO,MAAM,cAAc,oBAAoB,CAAA;AAC/C,eAAO,MAAM,mBAAmB,yBAAyB,CAAA;AACzD,eAAO,MAAM,gBAAgB,sBAAsB,CAAA;AACnD,eAAO,MAAM,UAAU,gBAAgB,CAAA;AACvC,eAAO,MAAM,WAAW,iBAAiB,CAAA;AACzC,eAAO,MAAM,S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ACH,eAAO,MAAM,mBAAmB,yBAAyB,CAAA;AACzD;;GAEG;AACH,eAAO,MAAM,gBAAgB,sBAAsB,CAAA"}
@@ -2,17 +2,42 @@ export const ProjectFolderKind = 'Core#ProjectFolder';
2
2
  export const ResponseKind = 'Core#HttpResponse';
3
3
  export const HttpResponseKind = 'Core#HttpResponse';
4
4
  export const CertificateFileKind = 'Core#CertificateFile';
5
- export const DataNamespaceKind = 'Core#DataNamespace';
6
- export const DataModelKind = 'Core#DataModel';
7
- export const DataEntityKind = 'Core#DataEntity';
8
- export const DataAssociationKind = 'Core#DataAssociation';
9
- export const DataPropertyKind = 'Core#DataProperty';
10
5
  export const FolderKind = 'Core#Folder';
11
6
  export const ProjectKind = 'Core#Project';
12
7
  export const ThingKind = 'Core#Thing';
13
- export const DataFileKind = 'Core#DataFile';
14
8
  export const DeletionKind = 'Core#Deletion';
15
9
  export const RevisionKind = 'Core#Revision';
16
10
  export const UnresolvedDependencyKind = 'Core#UnresolvedDependency';
17
11
  export const UserKind = 'Core#User';
12
+ export const DomainFileKind = 'Data#DomainFile';
13
+ export const DataDomainKind = 'Data#Domain';
14
+ export const DomainNamespaceKind = 'Domain#Namespace';
15
+ export const DomainModelKind = 'Domain#Model';
16
+ export const DomainEntityKind = 'Domain#Entity';
17
+ export const DomainAssociationKind = 'Domain#Association';
18
+ export const DomainPropertyKind = 'Domain#Property';
19
+ /**
20
+ * @deprecated Not used anymore.
21
+ */
22
+ export const DataFileKind = 'Core#DataFile';
23
+ /**
24
+ * @deprecated Not used anymore.
25
+ */
26
+ export const DataNamespaceKind = 'Data#DataNamespace';
27
+ /**
28
+ * @deprecated Not used anymore.
29
+ */
30
+ export const DataModelKind = 'Data#DataModel';
31
+ /**
32
+ * @deprecated Not used anymore.
33
+ */
34
+ export const DataEntityKind = 'Data#DataEntity';
35
+ /**
36
+ * @deprecated Not used anymore.
37
+ */
38
+ export const DataAssociationKind = 'Data#DataAssociation';
39
+ /**
40
+ * @deprecated Not used anymore.
41
+ */
42
+ export const DataPropertyKind = 'Data#DataProperty';
18
43
  //# sourceMappingURL=kinds.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"kinds.js","sourceRoot":"","sources":["../../../src/models/kinds.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,iBAAiB,GAAG,oBAAoB,CAAA;AACrD,MAAM,CAAC,MAAM,YAAY,GAAG,mBAAmB,CAAA;AAC/C,MAAM,CAAC,MAAM,gBAAgB,GAAG,mBAAmB,CAAA;AACnD,MAAM,CAAC,MAAM,mBAAmB,GAAG,sBAAsB,CAAA;AACzD,MAAM,CAAC,MAAM,iBAAiB,GAAG,oBAAoB,CAAA;AACrD,MAAM,CAAC,MAAM,aAAa,GAAG,gBAAgB,CAAA;AAC7C,MAAM,CAAC,MAAM,cAAc,GAAG,iBAAiB,CAAA;AAC/C,MAAM,CAAC,MAAM,mBAAmB,GAAG,sBAAsB,CAAA;AACzD,MAAM,CAAC,MAAM,gBAAgB,GAAG,mBAAmB,CAAA;AACnD,MAAM,CAAC,MAAM,UAAU,GAAG,aAAa,CAAA;AACvC,MAAM,CAAC,MAAM,WAAW,GAAG,cAAc,CAAA;AACzC,MAAM,CAAC,MAAM,SAAS,GAAG,YAAY,CAAA;AACrC,MAAM,CAAC,MAAM,YAAY,GAAG,eAAe,CAAA;AAC3C,MAAM,CAAC,MAAM,YAAY,GAAG,eAAe,CAAA;AAC3C,MAAM,CAAC,MAAM,YAAY,GAAG,eAAe,CAAA;AAC3C,MAAM,CAAC,MAAM,wBAAwB,GAAG,2BAA2B,CAAA;AACnE,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAA","sourcesContent":["export const ProjectFolderKind = 'Core#ProjectFolder'\nexport const ResponseKind = 'Core#HttpResponse'\nexport const HttpResponseKind = 'Core#HttpResponse'\nexport const CertificateFileKind = 'Core#CertificateFile'\nexport const DataNamespaceKind = 'Core#DataNamespace'\nexport const DataModelKind = 'Core#DataModel'\nexport const DataEntityKind = 'Core#DataEntity'\nexport const DataAssociationKind = 'Core#DataAssociation'\nexport const DataPropertyKind = 'Core#DataProperty'\nexport const FolderKind = 'Core#Folder'\nexport const ProjectKind = 'Core#Project'\nexport const ThingKind = 'Core#Thing'\nexport const DataFileKind = 'Core#DataFile'\nexport const DeletionKind = 'Core#Deletion'\nexport const RevisionKind = 'Core#Revision'\nexport const UnresolvedDependencyKind = 'Core#UnresolvedDependency'\nexport const UserKind = 'Core#User'\n"]}
1
+ {"version":3,"file":"kinds.js","sourceRoot":"","sources":["../../../src/models/kinds.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,iBAAiB,GAAG,oBAAoB,CAAA;AACrD,MAAM,CAAC,MAAM,YAAY,GAAG,mBAAmB,CAAA;AAC/C,MAAM,CAAC,MAAM,gBAAgB,GAAG,mBAAmB,CAAA;AACnD,MAAM,CAAC,MAAM,mBAAmB,GAAG,sBAAsB,CAAA;AACzD,MAAM,CAAC,MAAM,UAAU,GAAG,aAAa,CAAA;AACvC,MAAM,CAAC,MAAM,WAAW,GAAG,cAAc,CAAA;AACzC,MAAM,CAAC,MAAM,SAAS,GAAG,YAAY,CAAA;AACrC,MAAM,CAAC,MAAM,YAAY,GAAG,eAAe,CAAA;AAC3C,MAAM,CAAC,MAAM,YAAY,GAAG,eAAe,CAAA;AAC3C,MAAM,CAAC,MAAM,wBAAwB,GAAG,2BAA2B,CAAA;AACnE,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAA;AACnC,MAAM,CAAC,MAAM,cAAc,GAAG,iBAAiB,CAAA;AAC/C,MAAM,CAAC,MAAM,cAAc,GAAG,aAAa,CAAA;AAC3C,MAAM,CAAC,MAAM,mBAAmB,GAAG,kBAAkB,CAAA;AACrD,MAAM,CAAC,MAAM,eAAe,GAAG,cAAc,CAAA;AAC7C,MAAM,CAAC,MAAM,gBAAgB,GAAG,eAAe,CAAA;AAC/C,MAAM,CAAC,MAAM,qBAAqB,GAAG,oBAAoB,CAAA;AACzD,MAAM,CAAC,MAAM,kBAAkB,GAAG,iBAAiB,CAAA;AAEnD;;GAEG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,eAAe,CAAA;AAC3C;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,oBAAoB,CAAA;AACrD;;GAEG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,gBAAgB,CAAA;AAC7C;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,iBAAiB,CAAA;AAC/C;;GAEG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,sBAAsB,CAAA;AACzD;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,mBAAmB,CAAA","sourcesContent":["export const ProjectFolderKind = 'Core#ProjectFolder'\nexport const ResponseKind = 'Core#HttpResponse'\nexport const HttpResponseKind = 'Core#HttpResponse'\nexport const CertificateFileKind = 'Core#CertificateFile'\nexport const FolderKind = 'Core#Folder'\nexport const ProjectKind = 'Core#Project'\nexport const ThingKind = 'Core#Thing'\nexport const DeletionKind = 'Core#Deletion'\nexport const RevisionKind = 'Core#Revision'\nexport const UnresolvedDependencyKind = 'Core#UnresolvedDependency'\nexport const UserKind = 'Core#User'\nexport const DomainFileKind = 'Data#DomainFile'\nexport const DataDomainKind = 'Data#Domain'\nexport const DomainNamespaceKind = 'Domain#Namespace'\nexport const DomainModelKind = 'Domain#Model'\nexport const DomainEntityKind = 'Domain#Entity'\nexport const DomainAssociationKind = 'Domain#Association'\nexport const DomainPropertyKind = 'Domain#Property'\n\n/**\n * @deprecated Not used anymore.\n */\nexport const DataFileKind = 'Core#DataFile'\n/**\n * @deprecated Not used anymore.\n */\nexport const DataNamespaceKind = 'Data#DataNamespace'\n/**\n * @deprecated Not used anymore.\n */\nexport const DataModelKind = 'Data#DataModel'\n/**\n * @deprecated Not used anymore.\n */\nexport const DataEntityKind = 'Data#DataEntity'\n/**\n * @deprecated Not used anymore.\n */\nexport const DataAssociationKind = 'Data#DataAssociation'\n/**\n * @deprecated Not used anymore.\n */\nexport const DataPropertyKind = 'Data#DataProperty'\n"]}
@@ -1,11 +1,12 @@
1
1
  import { File, IFile } from './File.js';
2
- import { DataNamespace, IDataNamespace } from '../../modeling/DataNamespace.js';
2
+ import { DataNamespace, IDataNamespace } from '../../modeling/legacy/DataNamespace.js';
3
3
  import { DataFileKind as Kind } from '../kinds.js';
4
4
  export interface IDataFile extends IFile {
5
5
  kind: typeof Kind;
6
6
  }
7
7
  /**
8
8
  * Used by the store. A file definition for the DataNamespace
9
+ * @deprecated Use DomainFile instead.
9
10
  */
10
11
  export declare class DataFile extends File {
11
12
  kind: string;
@@ -14,6 +15,7 @@ export declare class DataFile extends File {
14
15
  *
15
16
  * @param input The data namespace instance or schema.
16
17
  * @param owner Optional owner to set.
18
+ * @deprecated Use DomainFile instead.
17
19
  */
18
20
  static fromDataNamespace(input: DataNamespace | IDataNamespace, organization: string, owner?: string): DataFile;
19
21
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"DataFile.d.ts","sourceRoot":"","sources":["../../../../src/models/store/DataFile.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,WAAW,CAAA;AAEvC,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AAC/E,OAAO,EAAE,YAAY,IAAI,IAAI,EAAE,MAAM,aAAa,CAAA;AAElD,MAAM,WAAW,SAAU,SAAQ,KAAK;IACtC,IAAI,EAAE,OAAO,IAAI,CAAA;CAClB;AAED;;GAEG;AACH,qBAAa,QAAS,SAAQ,IAAI;IACvB,IAAI,SAAO;IAEpB;;;;;OAKG;IACH,MAAM,CAAC,iBAAiB,CAAC,KAAK,EAAE,aAAa,GAAG,cAAc,EAAE,YAAY,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ;IAqB/G;;;OAGG;WACa,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ;gBAI1E,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS;IAsB7B,GAAG,CAAC,IAAI,EAAE,SAAS,GAAG,IAAI;IASnC,MAAM,CAAC,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO;IAQjC,MAAM,IAAI,SAAS;CAO7B"}
1
+ {"version":3,"file":"DataFile.d.ts","sourceRoot":"","sources":["../../../../src/models/store/DataFile.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,WAAW,CAAA;AAEvC,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAA;AACtF,OAAO,EAAE,YAAY,IAAI,IAAI,EAAE,MAAM,aAAa,CAAA;AAElD,MAAM,WAAW,SAAU,SAAQ,KAAK;IACtC,IAAI,EAAE,OAAO,IAAI,CAAA;CAClB;AAED;;;GAGG;AACH,qBAAa,QAAS,SAAQ,IAAI;IACvB,IAAI,SAAO;IAEpB;;;;;;OAMG;IACH,MAAM,CAAC,iBAAiB,CAAC,KAAK,EAAE,aAAa,GAAG,cAAc,EAAE,YAAY,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ;IAqB/G;;;OAGG;WACa,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ;gBAI1E,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS;IAsB7B,GAAG,CAAC,IAAI,EAAE,SAAS,GAAG,IAAI;IASnC,MAAM,CAAC,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO;IAQjC,MAAM,IAAI,SAAS;CAO7B"}
@@ -4,6 +4,7 @@ import { Thing } from '../Thing.js';
4
4
  import { DataFileKind as Kind } from '../kinds.js';
5
5
  /**
6
6
  * Used by the store. A file definition for the DataNamespace
7
+ * @deprecated Use DomainFile instead.
7
8
  */
8
9
  export class DataFile extends File {
9
10
  kind = Kind;
@@ -12,6 +13,7 @@ export class DataFile extends File {
12
13
  *
13
14
  * @param input The data namespace instance or schema.
14
15
  * @param owner Optional owner to set.
16
+ * @deprecated Use DomainFile instead.
15
17
  */
16
18
  static fromDataNamespace(input, organization, owner) {
17
19
  let final;
@@ -1 +1 @@
1
- {"version":3,"file":"DataFile.js","sourceRoot":"","sources":["../../../../src/models/store/DataFile.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAClC,OAAO,EAAE,IAAI,EAAS,MAAM,WAAW,CAAA;AACvC,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AAEnC,OAAO,EAAE,YAAY,IAAI,IAAI,EAAE,MAAM,aAAa,CAAA;AAMlD;;GAEG;AACH,MAAM,OAAO,QAAS,SAAQ,IAAI;IACvB,IAAI,GAAG,IAAI,CAAA;IAEpB;;;;;OAKG;IACH,MAAM,CAAC,iBAAiB,CAAC,KAAqC,EAAE,YAAoB,EAAE,KAAc;QAClG,IAAI,KAAqB,CAAA;QACzB,IAAI,OAAQ,KAAuB,CAAC,MAAM,KAAK,UAAU,EAAE,CAAC;YAC1D,KAAK,GAAI,KAAuB,CAAC,MAAM,EAAE,CAAA;QAC3C,CAAC;aAAM,CAAC;YACN,KAAK,GAAG,KAAuB,CAAA;QACjC,CAAC;QACD,MAAM,IAAI,GAAc;YACtB,IAAI,EAAE,IAAI;YACV,GAAG,EAAE,KAAK,CAAC,GAAG;YACd,YAAY;YACZ,IAAI,EAAE,EAAE,GAAG,KAAK,CAAC,IAAI,EAAE;YACvB,YAAY,EAAE,EAAE,IAAI,EAAE,KAAK,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE;YACzD,KAAK;YACL,OAAO,EAAE,EAAE;YACX,aAAa,EAAE,EAAE;YACjB,WAAW,EAAE,EAAE;SAChB,CAAA;QACD,OAAO,IAAI,QAAQ,CA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AC,KAAc;QAC9B,MAAM,KAAK,GAAG,KAAkB,CAAA;QAChC,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,IAAI,KAAK,IAAI,EAAE,CAAC;YAClC,OAAO,KAAK,CAAA;QACd,CAAC;QACD,OAAO,IAAI,CAAA;IACb,CAAC;IAEQ,MAAM;QACb,MAAM,MAAM,GAAc;YACxB,GAAG,KAAK,CAAC,MAAM,EAAE;YACjB,IAAI,EAAE,IAAI;SACX,CAAA;QACD,OAAO,MAAM,CAAA;IACf,CAAC;CACF","sourcesContent":["import v4 from '../../lib/uuid.js'\nimport { File, IFile } from './File.js'\nimport { Thing } from '../Thing.js'\nimport { DataNamespace, IDataNamespace } from '../../modeling/DataNamespace.js'\nimport { DataFileKind as Kind } from '../kinds.js'\n\nexport interface IDataFile extends IFile {\n kind: typeof Kind\n}\n\n/**\n * Used by the store. A file definition for the DataNamespace\n */\nexport class DataFile extends File {\n override kind = Kind\n\n /**\n * Creates the file definition for a DataNamespace contents.\n *\n * @param input The data namespace instance or schema.\n * @param owner Optional owner to set.\n */\n static fromDataNamespace(input: DataNamespace | IDataNamespace, organization: string, owner?: string): DataFile {\n let final: IDataNamespace\n if (typeof (input as DataNamespace).toJSON === 'function') {\n final = (input as DataNamespace).toJSON()\n } else {\n final = input as IDataNamespace\n }\n const init: IDataFile = {\n kind: Kind,\n key: final.key,\n organization,\n info: { ...final.info },\n lastModified: { user: owner || '', time: 0, byMe: false },\n owner,\n parents: [],\n permissionIds: [],\n permissions: [],\n }\n return new DataFile(init)\n }\n\n /**\n * @param name The name to set.\n * @param owner The user id that is the owner of the file.\n */\n static override fromName(name: string, organization: string, owner?: string): DataFile {\n return super.fromName(name, organization, owner, Kind) as DataFile\n }\n\n constructor(input?: string | IDataFile) {\n super()\n let init: IDataFile\n if (typeof input === 'string') {\n init = JSON.parse(input)\n } else if (typeof input === 'object') {\n init = input\n } else {\n init = {\n kind: Kind,\n key: v4(),\n organization: '',\n info: Thing.fromName('').toJSON(),\n parents: [],\n permissionIds: [],\n permissions: [],\n lastModified: { user: '', time: 0, byMe: false },\n }\n }\n this.new(init)\n }\n\n override new(init: IDataFile): this {\n if (!DataFile.isDataFile(init)) {\n throw new Error(`Not a data file.`)\n }\n super.new(init)\n this.kind = Kind\n return this\n }\n\n static isDataFile(input: unknown): boolean {\n const typed = input as IDataFile\n if (!input || typed.kind !== Kind) {\n return false\n }\n return true\n }\n\n override toJSON(): IDataFile {\n const result: IDataFile = {\n ...super.toJSON(),\n kind: Kind,\n }\n return result\n }\n}\n"]}
1
+ {"version":3,"file":"DataFile.js","sourceRoot":"","sources":["../../../../src/models/store/DataFile.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAClC,OAAO,EAAE,IAAI,EAAS,MAAM,WAAW,CAAA;AACvC,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAA;AAEnC,OAAO,EAAE,YAAY,IAAI,IAAI,EAAE,MAAM,aAAa,CAAA;AAMlD;;;GAGG;AACH,MAAM,OAAO,QAAS,SAAQ,IAAI;IACvB,IAAI,GAAG,IAAI,CAAA;IAEpB;;;;;;OAMG;IACH,MAAM,CAAC,iBAAiB,CAAC,KAAqC,EAAE,YAAoB,EAAE,KAAc;QAClG,IAAI,KAAqB,CAAA;QACzB,IAAI,OAAQ,KAAuB,CAAC,MAAM,KAAK,UAAU,EAAE,CAAC;YAC1D,KAAK,GAAI,KAAuB,CAAC,MAAM,EAAE,CAAA;QAC3C,CAAC;aAAM,CAAC;YACN,KAAK,GAAG,KAAuB,CAAA;QACjC,CAAC;QACD,MAAM,IAAI,GAAc;YACtB,IAAI,EAAE,IAAI;YACV,GAAG,EAAE,KAAK,CAAC,GAAG;YACd,YAAY;YACZ,IAAI,EAAE,EAAE,GAAG,KAAK,CAAC,IAAI,EAAE;YACvB,YAAY,EAAE,EAAE,IAAI,EAAE,KAAK,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,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,CAAC,IAAI,CAAC,CAAA;QACf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAA;QAChB,OAAO,IAAI,CAAA;IACb,CAAC;IAED,MAAM,CAAC,UAAU,CAAC,KAAc;QAC9B,MAAM,KAAK,GAAG,KAAkB,CAAA;QAChC,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,IAAI,KAAK,IAAI,EAAE,CAAC;YAClC,OAAO,KAAK,CAAA;QACd,CAAC;QACD,OAAO,IAAI,CAAA;IACb,CAAC;IAEQ,MAAM;QACb,MAAM,MAAM,GAAc;YACxB,GAAG,KAAK,CAAC,MAAM,EAAE;YACjB,IAAI,EAAE,IAAI;SACX,CAAA;QACD,OAAO,MAAM,CAAA;IACf,CAAC;CACF","sourcesContent":["import v4 from '../../lib/uuid.js'\nimport { File, IFile } from './File.js'\nimport { Thing } from '../Thing.js'\nimport { DataNamespace, IDataNamespace } from '../../modeling/legacy/DataNamespace.js'\nimport { DataFileKind as Kind } from '../kinds.js'\n\nexport interface IDataFile extends IFile {\n kind: typeof Kind\n}\n\n/**\n * Used by the store. A file definition for the DataNamespace\n * @deprecated Use DomainFile instead.\n */\nexport class DataFile extends File {\n override kind = Kind\n\n /**\n * Creates the file definition for a DataNamespace contents.\n *\n * @param input The data namespace instance or schema.\n * @param owner Optional owner to set.\n * @deprecated Use DomainFile instead.\n */\n static fromDataNamespace(input: DataNamespace | IDataNamespace, organization: string, owner?: string): DataFile {\n let final: IDataNamespace\n if (typeof (input as DataNamespace).toJSON === 'function') {\n final = (input as DataNamespace).toJSON()\n } else {\n final = input as IDataNamespace\n }\n const init: IDataFile = {\n kind: Kind,\n key: final.key,\n organization,\n info: { ...final.info },\n lastModified: { user: owner || '', time: 0, byMe: false },\n owner,\n parents: [],\n permissionIds: [],\n permissions: [],\n }\n return new DataFile(init)\n }\n\n /**\n * @param name The name to set.\n * @param owner The user id that is the owner of the file.\n */\n static override fromName(name: string, organization: string, owner?: string): DataFile {\n return super.fromName(name, organization, owner, Kind) as DataFile\n }\n\n constructor(input?: string | IDataFile) {\n super()\n let init: IDataFile\n if (typeof input === 'string') {\n init = JSON.parse(input)\n } else if (typeof input === 'object') {\n init = input\n } else {\n init = {\n kind: Kind,\n key: v4(),\n organization: '',\n info: Thing.fromName('').toJSON(),\n parents: [],\n permissionIds: [],\n permissions: [],\n lastModified: { user: '', time: 0, byMe: false },\n }\n }\n this.new(init)\n }\n\n override new(init: IDataFile): this {\n if (!DataFile.isDataFile(init)) {\n throw new Error(`Not a data file.`)\n }\n super.new(init)\n this.kind = Kind\n return this\n }\n\n static isDataFile(input: unknown): boolean {\n const typed = input as IDataFile\n if (!input || typed.kind !== Kind) {\n return false\n }\n return true\n }\n\n override toJSON(): IDataFile {\n const result: IDataFile = {\n ...super.toJSON(),\n kind: Kind,\n }\n return result\n }\n}\n"]}
@@ -0,0 +1,12 @@
1
+ export interface ModelValidationOptions {
2
+ /**
3
+ * When true, the validation will perform a strict validation.
4
+ *
5
+ * This means that the validation will check for the following:
6
+ * - The `kind` property is set to the correct value.
7
+ *
8
+ * In all kinds of validation, required properties are always checked.
9
+ */
10
+ strict?: boolean;
11
+ }
12
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/models/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,sBAAsB;IACrC;;;;;;;OAOG;IACH,MAAM,CAAC,EAAE,OAAO,CAAA;CACjB"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/models/types.ts"],"names":[],"mappings":"","sourcesContent":["export interface ModelValidationOptions {\n /**\n * When true, the validation will perform a strict validation.\n *\n * This means that the validation will check for the following:\n * - The `kind` property is set to the correct value.\n *\n * In all kinds of validation, required properties are always checked.\n */\n strict?: boolean\n}\n"]}
@@ -1,7 +1,7 @@
1
1
  import { SdkBase, SdkOptions } from './SdkBase.js';
2
2
  import { IUser } from '../../models/store/User.js';
3
3
  import { FileBreadcrumb, IFile } from '../../models/store/File.js';
4
- import { FolderKind, CertificateFileKind, ProjectKind, DataFileKind } from '../../models/kinds.js';
4
+ import { FolderKind, CertificateFileKind, ProjectKind, DomainFileKind } from '../../models/kinds.js';
5
5
  import { ContextListResult, ContextChangeRecord, IBulkOperationResult, ContextListOptions } from '../../events/BaseEvents.js';
6
6
  import { PermissionRole } from '../../models/store/Permission.js';
7
7
  import { type IFolder } from '../../models/Folder.js';
@@ -22,7 +22,7 @@ export interface IMediaCreateOptions {
22
22
  }
23
23
  export interface IFileCreateOptions extends IMetaCreateOptions, IMediaCreateOptions {
24
24
  }
25
- export type ListFileKind = typeof ProjectKind | typeof FolderKind | typeof DataFileKind | typeof CertificateFileKind;
25
+ export type ListFileKind = typeof ProjectKind | typeof FolderKind | typeof DomainFileKind | typeof CertificateFileKind;
26
26
  /**
27
27
  * In the store, the file is represented by the meta and the media.
28
28
  *
@@ -1 +1 @@
1
- {"version":3,"file":"FilesSdk.d.ts","sourceRoot":"","sources":["../../../../src/runtime/store/FilesSdk.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,OAAO,EAKP,UAAU,EACX,MAAM,cAAc,CAAA;AAErB,OAAO,EAAE,KAAK,EAAE,MAAM,4BAA4B,CAAA;AAClD,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,4BAA4B,CAAA;AAClE,OAAO,EAAE,UAAU,EAAE,mBAAmB,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AAElG,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EACnB,MAAM,4BAA4B,CAAA;AACnC,OAAO,EAA+C,cAAc,EAAE,MAAM,kCAAkC,CAAA;AAE9G,OAAO,EAAU,KAAK,OAAO,EAAE,MAAM,wBAAwB,CAAA;AAC7D,OAAO,KAAK,EAAE,eAAe,EAAE,c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