node-opcua-address-space 2.79.0 → 2.80.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/source/index.d.ts +2 -0
- package/dist/source/index.js +2 -0
- package/dist/source/index.js.map +1 -1
- package/dist/source/interfaces/extension_object_constructor.d.ts +10 -0
- package/dist/source/interfaces/extension_object_constructor.js +3 -0
- package/dist/source/interfaces/extension_object_constructor.js.map +1 -0
- package/dist/source/interfaces/nodeset_loader_options.d.ts +4 -0
- package/dist/source/interfaces/nodeset_loader_options.js +3 -0
- package/dist/source/interfaces/nodeset_loader_options.js.map +1 -0
- package/dist/source/loader/generateAddressSpaceRaw.d.ts +1 -1
- package/dist/source/loader/generateAddressSpaceRaw.js.map +1 -1
- package/dist/source/loader/load_nodeset2.d.ts +1 -4
- package/dist/source/loader/load_nodeset2.js.map +1 -1
- package/dist/source/namespace_data_access.d.ts +2 -2
- package/dist/src/address_space.d.ts +3 -4
- package/dist/src/address_space.js +11 -10
- package/dist/src/address_space.js.map +1 -1
- package/dist/src/address_space_private.d.ts +1 -1
- package/dist/src/historical_access/address_space_historical_data_node.d.ts +1 -1
- package/dist/src/historical_access/address_space_historical_data_node.js +32 -21
- package/dist/src/historical_access/address_space_historical_data_node.js.map +1 -1
- package/dist/src/index_current.d.ts +1 -0
- package/dist/src/index_current.js +1 -0
- package/dist/src/index_current.js.map +1 -1
- package/dist/src/ua_data_type_impl.d.ts +1 -9
- package/dist/src/ua_data_type_impl.js +4 -9
- package/dist/src/ua_data_type_impl.js.map +1 -1
- package/distNodeJS/generate_address_space.d.ts +1 -1
- package/distNodeJS/generate_address_space.js.map +1 -1
- package/package.json +6 -6
- package/source/index.ts +3 -0
- package/source/interfaces/extension_object_constructor.ts +12 -0
- package/source/interfaces/nodeset_loader_options.ts +4 -0
- package/source/loader/generateAddressSpaceRaw.ts +2 -1
- package/source/loader/load_nodeset2.ts +2 -4
- package/source/namespace_data_access.ts +2 -2
- package/source_nodejs/generate_address_space.ts +2 -1
- package/src/address_space.ts +19 -16
- package/src/address_space_private.ts +2 -3
- package/src/historical_access/address_space_historical_data_node.ts +1 -1
- package/src/index_current.ts +2 -0
- package/src/ua_data_type_impl.ts +5 -17
package/src/ua_data_type_impl.ts
CHANGED
|
@@ -7,7 +7,6 @@ import { assert } from "node-opcua-assert";
|
|
|
7
7
|
import { NodeClass, QualifiedNameLike } from "node-opcua-data-model";
|
|
8
8
|
import { AttributeIds } from "node-opcua-data-model";
|
|
9
9
|
import { DataValue, DataValueLike } from "node-opcua-data-value";
|
|
10
|
-
import { ExtensionObject } from "node-opcua-extension-object";
|
|
11
10
|
import { ExpandedNodeId, NodeId } from "node-opcua-nodeid";
|
|
12
11
|
import { NumericRange } from "node-opcua-numeric-range";
|
|
13
12
|
import { StatusCodes } from "node-opcua-status-code";
|
|
@@ -22,9 +21,9 @@ import {
|
|
|
22
21
|
import { DataType } from "node-opcua-variant";
|
|
23
22
|
import { UAObject, ISessionContext, UADataType, UAVariable, BaseNode } from "node-opcua-address-space-base";
|
|
24
23
|
import { DataTypeIds } from "node-opcua-constants";
|
|
25
|
-
import { IStructuredTypeSchema } from "node-opcua-factory";
|
|
26
24
|
|
|
27
25
|
import { SessionContext } from "../source/session_context";
|
|
26
|
+
import { ExtensionObjectConstructorFuncWithSchema } from "../source/interfaces/extension_object_constructor";
|
|
28
27
|
import { BaseNodeImpl, InternalBaseNodeOptions } from "./base_node_impl";
|
|
29
28
|
import { BaseNode_References_toString, BaseNode_toString, ToStringBuilder, ToStringOption } from "./base_node_private";
|
|
30
29
|
import * as tools from "./tool_isSupertypeOf";
|
|
@@ -32,13 +31,6 @@ import { get_subtypeOf } from "./tool_isSupertypeOf";
|
|
|
32
31
|
import { get_subtypeOfObj } from "./tool_isSupertypeOf";
|
|
33
32
|
import { BaseNode_getCache } from "./base_node_private";
|
|
34
33
|
|
|
35
|
-
export type ExtensionObjectConstructor = new (options: any) => ExtensionObject;
|
|
36
|
-
export interface ExtensionObjectConstructorFuncWithSchema extends ExtensionObjectConstructor {
|
|
37
|
-
schema: IStructuredTypeSchema;
|
|
38
|
-
possibleFields: string[];
|
|
39
|
-
encodingDefaultBinary: ExpandedNodeId;
|
|
40
|
-
encodingDefaultXml: ExpandedNodeId;
|
|
41
|
-
}
|
|
42
34
|
|
|
43
35
|
export interface UADataTypeImpl {
|
|
44
36
|
_extensionObjectConstructor: ExtensionObjectConstructorFuncWithSchema;
|
|
@@ -123,15 +115,11 @@ export class UADataTypeImpl extends BaseNodeImpl implements UADataType {
|
|
|
123
115
|
break;
|
|
124
116
|
case AttributeIds.DataTypeDefinition:
|
|
125
117
|
{
|
|
126
|
-
|
|
127
|
-
|
|
118
|
+
const _definition = this._getDefinition()?.clone();
|
|
119
|
+
if (_definition) {
|
|
120
|
+
options.value = { dataType: DataType.ExtensionObject, value: _definition };
|
|
128
121
|
} else {
|
|
129
|
-
|
|
130
|
-
if (_definition !== null) {
|
|
131
|
-
options.value = { dataType: DataType.ExtensionObject, value: _definition };
|
|
132
|
-
} else {
|
|
133
|
-
options.statusCode = StatusCodes.BadAttributeIdInvalid;
|
|
134
|
-
}
|
|
122
|
+
options.statusCode = StatusCodes.BadAttributeIdInvalid;
|
|
135
123
|
}
|
|
136
124
|
}
|
|
137
125
|
break;
|