basyx-typescript-sdk 1.1.2 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -8
- package/bundle/index.cjs +64 -51
- package/bundle/index.cjs.map +1 -1
- package/bundle/index.mjs +40 -27
- package/bundle/index.mjs.map +1 -1
- package/dist/clients/AasDiscoveryClient.d.ts +1 -1
- package/dist/clients/AasRepositoryClient.d.ts +1 -1
- package/dist/clients/ConceptDescriptionRepositoryClient.d.ts +1 -1
- package/dist/clients/SubmodelRepositoryClient.d.ts +1 -1
- package/dist/lib/aas-dataformat-xml/xmlization.js +44 -67
- package/dist/lib/convertAasDiscoveryTypes.d.ts +1 -1
- package/dist/lib/convertAasDiscoveryTypes.js +2 -2
- package/dist/lib/convertAasTypes.d.ts +1 -1
- package/dist/lib/convertAasTypes.js +2 -2
- package/dist/lib/convertConceptDescriptionTypes.d.ts +1 -1
- package/dist/lib/convertConceptDescriptionTypes.js +2 -2
- package/dist/lib/convertSubmodelTypes.d.ts +1 -1
- package/dist/lib/convertSubmodelTypes.js +2 -2
- package/dist/lib/descriptorJsonization.d.ts +2 -2
- package/dist/lib/descriptorJsonization.js +3 -3
- package/dist/models/BaSyxEnvironment.d.ts +1 -1
- package/dist/models/BaSyxEnvironment.js +1 -1
- package/dist/models/Descriptors.d.ts +1 -1
- package/dist/services/AasService.d.ts +1 -1
- package/dist/services/AasService.js +1 -1
- package/dist/services/SubmodelService.d.ts +1 -1
- package/dist/services/SubmodelService.js +1 -1
- package/dist/utils/KeyTypesUtil.d.ts +1 -1
- package/dist/utils/KeyTypesUtil.js +1 -1
- package/dist/utils/MultiLanguagePropertyUtils.d.ts +1 -1
- package/dist/utils/MultiLanguagePropertyUtils.js +1 -1
- package/dist/utils/ReferableUtils.d.ts +1 -1
- package/dist/utils/ReferableUtils.js +1 -1
- package/dist/utils/ReferenceUtil.d.ts +1 -1
- package/dist/utils/SemanticIdUtils.d.ts +1 -1
- package/dist/utils/SemanticIdUtils.js +1 -1
- package/package.json +4 -4
package/bundle/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsonization, common } from '@aas-core-works/aas-core3.
|
|
1
|
+
import { jsonization, common } from '@aas-core-works/aas-core3.1-typescript';
|
|
2
2
|
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
@@ -6379,7 +6379,8 @@ function base64Decode(urlSafeBase64String) {
|
|
|
6379
6379
|
}
|
|
6380
6380
|
|
|
6381
6381
|
/**
|
|
6382
|
-
*
|
|
6382
|
+
* --- WORK IN PROGRESS ---
|
|
6383
|
+
* Provide an implementation of the Asset Administration Shell (AAS) V3.1.
|
|
6383
6384
|
*
|
|
6384
6385
|
* @remarks
|
|
6385
6386
|
* The presented version of the Metamodel is related to the work of
|
|
@@ -6688,9 +6689,8 @@ return 3;// AssetAdministrationShell
|
|
|
6688
6689
|
* optional.
|
|
6689
6690
|
*
|
|
6690
6691
|
* Constraint `AASd-116`:
|
|
6691
|
-
* `globalAssetId` is a reserved key
|
|
6692
|
-
*
|
|
6693
|
-
* identical to {@link AssetInformation.globalAssetId}.
|
|
6692
|
+
* `globalAssetId` is a reserved key for {@link SpecificAssetId.name} with the
|
|
6693
|
+
* semantics as defined in {@link AssetInformation.globalAssetId}.
|
|
6694
6694
|
*
|
|
6695
6695
|
* **Note**:
|
|
6696
6696
|
* Constraint AASd-116 is important to enable a generic search across
|
|
@@ -6716,8 +6716,9 @@ return 3;// AssetAdministrationShell
|
|
|
6716
6716
|
// which do not provide JIT compilation of hot paths.
|
|
6717
6717
|
return 4;// AssetInformation
|
|
6718
6718
|
}/**
|
|
6719
|
-
* Denotes whether the Asset is of kind {@link AssetKind.Type}
|
|
6720
|
-
* {@link AssetKind.Instance}.
|
|
6719
|
+
* Denotes whether the Asset is of kind {@link AssetKind.Type},
|
|
6720
|
+
* {@link AssetKind.Instance}, {@link AssetKind.Role}, or
|
|
6721
|
+
* {@link AssetKind.NotApplicable}.
|
|
6721
6722
|
*/ /**
|
|
6722
6723
|
* Yield from {@link specificAssetIds} if it is set, or yield nothing.
|
|
6723
6724
|
*/*overSpecificAssetIdsOrEmpty(){if(this.specificAssetIds!==null){yield*this.specificAssetIds;}return;}/**
|
|
@@ -6755,8 +6756,9 @@ return 4;// AssetInformation
|
|
|
6755
6756
|
* @paramType T - type of the transformation result
|
|
6756
6757
|
* @paramType ContextT - type of the transformation context
|
|
6757
6758
|
*/transformWithContext(transformer,context){return transformer.transformAssetInformationWithContext(this,context);}constructor(assetKind,globalAssetId=null,specificAssetIds=null,assetType=null,defaultThumbnail=null){super();this.assetKind=assetKind;this.globalAssetId=globalAssetId;this.specificAssetIds=specificAssetIds;this.assetType=assetType;this.defaultThumbnail=defaultThumbnail;}}/**
|
|
6758
|
-
* Enumeration for denoting whether an asset is a type asset or an instance
|
|
6759
|
-
|
|
6759
|
+
* Enumeration for denoting whether an asset is a type asset or an instance
|
|
6760
|
+
* asset or is a role or whether this kind of classification is not applicable.
|
|
6761
|
+
*/let AssetKind=/*#__PURE__*/function(AssetKind){AssetKind[AssetKind["Type"]=0]="Type";AssetKind[AssetKind["Instance"]=1]="Instance";AssetKind[AssetKind["Role"]=2]="Role";AssetKind[AssetKind["NotApplicable"]=3]="NotApplicable";return AssetKind;}({});/**
|
|
6760
6762
|
* A specific asset ID describes a generic supplementary identifying attribute of the
|
|
6761
6763
|
* asset.
|
|
6762
6764
|
*
|
|
@@ -6927,8 +6929,6 @@ return 12;// MultiLanguageProperty
|
|
|
6927
6929
|
*/*overEmbeddedDataSpecificationsOrEmpty(){if(this.embeddedDataSpecifications!==null){yield*this.embeddedDataSpecifications;}return;}/**
|
|
6928
6930
|
* Yield from {@link value} if it is set, or yield nothing.
|
|
6929
6931
|
*/*overValueOrEmpty(){if(this.value!==null){yield*this.value;}return;}/**
|
|
6930
|
-
* @returns {@link category} if set or the default value otherwise.
|
|
6931
|
-
*/categoryOrDefault(){return this.category!==null?this.category:"VARIABLE";}/**
|
|
6932
6932
|
* Iterate over the instances referenced from this instance.
|
|
6933
6933
|
*
|
|
6934
6934
|
* We do not recurse into the referenced instances.
|
|
@@ -7509,11 +7509,11 @@ return 32;// ValueReferencePair
|
|
|
7509
7509
|
* We do not recurse into the referenced instances.
|
|
7510
7510
|
*
|
|
7511
7511
|
* @returns Iterator over the referenced instances
|
|
7512
|
-
*/*descendOnce(){yield this.valueId;}/**
|
|
7512
|
+
*/*descendOnce(){if(this.valueId!==null){yield this.valueId;}}/**
|
|
7513
7513
|
* Iterate recursively over the instances referenced from this instance.
|
|
7514
7514
|
*
|
|
7515
7515
|
* @returns Iterator over the referenced instances
|
|
7516
|
-
*/*descend(){yield this.valueId;yield*this.valueId.descend();}/**
|
|
7516
|
+
*/*descend(){if(this.valueId!==null){yield this.valueId;yield*this.valueId.descend();}}/**
|
|
7517
7517
|
* Dispatch `visitor` on this instance.
|
|
7518
7518
|
*
|
|
7519
7519
|
* @param visitor - to visit this instance
|
|
@@ -7537,7 +7537,7 @@ return 32;// ValueReferencePair
|
|
|
7537
7537
|
* @returns transformation of this instance
|
|
7538
7538
|
* @paramType T - type of the transformation result
|
|
7539
7539
|
* @paramType ContextT - type of the transformation context
|
|
7540
|
-
*/transformWithContext(transformer,context){return transformer.transformValueReferencePairWithContext(this,context);}constructor(value,valueId){super();this.value=value;this.valueId=valueId;}}/**
|
|
7540
|
+
*/transformWithContext(transformer,context){return transformer.transformValueReferencePairWithContext(this,context);}constructor(value,valueId=null){super();this.value=value;this.valueId=valueId;}}/**
|
|
7541
7541
|
* A set of value reference pairs.
|
|
7542
7542
|
*/class ValueList extends Class{/**
|
|
7543
7543
|
* Indicate the runtime model type of the instance.
|
|
@@ -8233,7 +8233,7 @@ function mustQualifierKindToString(value) {
|
|
|
8233
8233
|
}
|
|
8234
8234
|
return result;
|
|
8235
8235
|
}
|
|
8236
|
-
const ASSET_KIND_FROM_STRING = new Map([["Type", AssetKind.Type], ["Instance", AssetKind.Instance], ["NotApplicable", AssetKind.NotApplicable]]);
|
|
8236
|
+
const ASSET_KIND_FROM_STRING = new Map([["Type", AssetKind.Type], ["Instance", AssetKind.Instance], ["Role", AssetKind.Role], ["NotApplicable", AssetKind.NotApplicable]]);
|
|
8237
8237
|
|
|
8238
8238
|
/**
|
|
8239
8239
|
* Parse `text` as a string representation of {@link types!AssetKind}.
|
|
@@ -8245,7 +8245,7 @@ function assetKindFromString(text) {
|
|
|
8245
8245
|
const result = ASSET_KIND_FROM_STRING.get(text);
|
|
8246
8246
|
return result !== undefined ? result : null;
|
|
8247
8247
|
}
|
|
8248
|
-
const ASSET_KIND_TO_STRING = new Map([[AssetKind.Type, "Type"], [AssetKind.Instance, "Instance"], [AssetKind.NotApplicable, "NotApplicable"]]);
|
|
8248
|
+
const ASSET_KIND_TO_STRING = new Map([[AssetKind.Type, "Type"], [AssetKind.Instance, "Instance"], [AssetKind.Role, "Role"], [AssetKind.NotApplicable, "NotApplicable"]]);
|
|
8249
8249
|
|
|
8250
8250
|
/**
|
|
8251
8251
|
* Translate {@link types!AssetKind} to a string.
|
|
@@ -9897,9 +9897,6 @@ function valueReferencePairFromJsonable(jsonable) {
|
|
|
9897
9897
|
if (setter.value === null) {
|
|
9898
9898
|
return newDeserializationError("The required property 'value' is missing");
|
|
9899
9899
|
}
|
|
9900
|
-
if (setter.valueId === null) {
|
|
9901
|
-
return newDeserializationError("The required property 'valueId' is missing");
|
|
9902
|
-
}
|
|
9903
9900
|
return new Either(new ValueReferencePair(setter.value, setter.valueId), null);
|
|
9904
9901
|
}
|
|
9905
9902
|
|
|
@@ -10959,8 +10956,12 @@ class Serializer extends AbstractTransformer {
|
|
|
10959
10956
|
}
|
|
10960
10957
|
jsonable["embeddedDataSpecifications"] = embeddedDataSpecificationsArray;
|
|
10961
10958
|
}
|
|
10962
|
-
|
|
10963
|
-
|
|
10959
|
+
if (that.first !== null) {
|
|
10960
|
+
jsonable["first"] = this.transform(that.first);
|
|
10961
|
+
}
|
|
10962
|
+
if (that.second !== null) {
|
|
10963
|
+
jsonable["second"] = this.transform(that.second);
|
|
10964
|
+
}
|
|
10964
10965
|
jsonable["modelType"] = "RelationshipElement";
|
|
10965
10966
|
return jsonable;
|
|
10966
10967
|
}
|
|
@@ -11456,7 +11457,9 @@ class Serializer extends AbstractTransformer {
|
|
|
11456
11457
|
if (that.value !== null) {
|
|
11457
11458
|
jsonable["value"] = base64Encode(that.value);
|
|
11458
11459
|
}
|
|
11459
|
-
|
|
11460
|
+
if (that.contentType !== null) {
|
|
11461
|
+
jsonable["contentType"] = that.contentType;
|
|
11462
|
+
}
|
|
11460
11463
|
jsonable["modelType"] = "Blob";
|
|
11461
11464
|
return jsonable;
|
|
11462
11465
|
}
|
|
@@ -11523,7 +11526,9 @@ class Serializer extends AbstractTransformer {
|
|
|
11523
11526
|
if (that.value !== null) {
|
|
11524
11527
|
jsonable["value"] = that.value;
|
|
11525
11528
|
}
|
|
11526
|
-
|
|
11529
|
+
if (that.contentType !== null) {
|
|
11530
|
+
jsonable["contentType"] = that.contentType;
|
|
11531
|
+
}
|
|
11527
11532
|
jsonable["modelType"] = "File";
|
|
11528
11533
|
return jsonable;
|
|
11529
11534
|
}
|
|
@@ -11587,8 +11592,12 @@ class Serializer extends AbstractTransformer {
|
|
|
11587
11592
|
}
|
|
11588
11593
|
jsonable["embeddedDataSpecifications"] = embeddedDataSpecificationsArray;
|
|
11589
11594
|
}
|
|
11590
|
-
|
|
11591
|
-
|
|
11595
|
+
if (that.first !== null) {
|
|
11596
|
+
jsonable["first"] = this.transform(that.first);
|
|
11597
|
+
}
|
|
11598
|
+
if (that.second !== null) {
|
|
11599
|
+
jsonable["second"] = this.transform(that.second);
|
|
11600
|
+
}
|
|
11592
11601
|
if (that.annotations !== null) {
|
|
11593
11602
|
const annotationsArray = new Array();
|
|
11594
11603
|
for (const item of that.annotations) {
|
|
@@ -11666,7 +11675,9 @@ class Serializer extends AbstractTransformer {
|
|
|
11666
11675
|
}
|
|
11667
11676
|
jsonable["statements"] = statementsArray;
|
|
11668
11677
|
}
|
|
11669
|
-
|
|
11678
|
+
if (that.entityType !== null) {
|
|
11679
|
+
jsonable["entityType"] = mustEntityTypeToString(that.entityType);
|
|
11680
|
+
}
|
|
11670
11681
|
if (that.globalAssetId !== null) {
|
|
11671
11682
|
jsonable["globalAssetId"] = that.globalAssetId;
|
|
11672
11683
|
}
|
|
@@ -12135,7 +12146,9 @@ class Serializer extends AbstractTransformer {
|
|
|
12135
12146
|
transformValueReferencePair(that) {
|
|
12136
12147
|
const jsonable = {};
|
|
12137
12148
|
jsonable["value"] = that.value;
|
|
12138
|
-
|
|
12149
|
+
if (that.valueId !== null) {
|
|
12150
|
+
jsonable["valueId"] = this.transform(that.valueId);
|
|
12151
|
+
}
|
|
12139
12152
|
return jsonable;
|
|
12140
12153
|
}
|
|
12141
12154
|
|