node-opcua-extension-object 2.97.0 → 2.98.1

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.
@@ -1,16 +1,16 @@
1
- /// <reference types="node" />
2
- import { BinaryStream, OutputBinaryStream } from "node-opcua-binary-stream";
3
- import { BaseUAObject, IStructuredTypeSchema } from "node-opcua-factory";
4
- import { NodeId } from "node-opcua-nodeid";
5
- export declare class ExtensionObject extends BaseUAObject {
6
- static schema: IStructuredTypeSchema;
7
- constructor(options?: null | Record<string, any>);
8
- }
9
- export declare function encodeExtensionObject(object: BaseUAObject | null, stream: OutputBinaryStream): void;
10
- export declare class OpaqueStructure extends ExtensionObject {
11
- nodeId: NodeId;
12
- buffer: Buffer;
13
- constructor(nodeId: NodeId, buffer: Buffer);
14
- toString(): string;
15
- }
16
- export declare function decodeExtensionObject(stream: BinaryStream, _value?: ExtensionObject | null): ExtensionObject | null;
1
+ /// <reference types="node" />
2
+ import { BinaryStream, OutputBinaryStream } from "node-opcua-binary-stream";
3
+ import { BaseUAObject, IStructuredTypeSchema } from "node-opcua-factory";
4
+ import { NodeId } from "node-opcua-nodeid";
5
+ export declare class ExtensionObject extends BaseUAObject {
6
+ static schema: IStructuredTypeSchema;
7
+ constructor(options?: null | Record<string, any>);
8
+ }
9
+ export declare function encodeExtensionObject(object: BaseUAObject | null, stream: OutputBinaryStream): void;
10
+ export declare class OpaqueStructure extends ExtensionObject {
11
+ nodeId: NodeId;
12
+ buffer: Buffer;
13
+ constructor(nodeId: NodeId, buffer: Buffer);
14
+ toString(): string;
15
+ }
16
+ export declare function decodeExtensionObject(stream: BinaryStream, _value?: ExtensionObject | null): ExtensionObject | null;
@@ -1,184 +1,184 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.decodeExtensionObject = exports.OpaqueStructure = exports.encodeExtensionObject = exports.ExtensionObject = void 0;
4
- /**
5
- * @module node-opcua-extension-object
6
- */
7
- const node_opcua_basic_types_1 = require("node-opcua-basic-types");
8
- const node_opcua_debug_1 = require("node-opcua-debug");
9
- const node_opcua_factory_1 = require("node-opcua-factory");
10
- const node_opcua_nodeid_1 = require("node-opcua-nodeid");
11
- const debugLog = (0, node_opcua_debug_1.make_debugLog)(__filename);
12
- const warningLog = (0, node_opcua_debug_1.make_warningLog)(__filename);
13
- const chalk = require("chalk");
14
- /* tslint:disable:no-empty */
15
- class ExtensionObject extends node_opcua_factory_1.BaseUAObject {
16
- constructor(options) {
17
- super();
18
- }
19
- }
20
- exports.ExtensionObject = ExtensionObject;
21
- ExtensionObject.schema = new node_opcua_factory_1.StructuredTypeSchema({
22
- baseType: "",
23
- documentation: "",
24
- fields: [],
25
- name: "ExtensionObject",
26
- dataTypeFactory: (0, node_opcua_factory_1.getStandardDataTypeFactory)()
27
- });
28
- ExtensionObject.prototype.schema = ExtensionObject.schema;
29
- // OPC-UA Part 6 - $5.2.2.15 ExtensionObject
30
- // An ExtensionObject is encoded as sequence of bytes prefixed by the NodeId of its
31
- // DataTypeEncoding and the number of bytes encoded.
32
- // what the specs say: OCC/UA part 6 $5.2.2.15 ExtensionObject
33
- //
34
- // TypeId | NodeId | The identifier for the DataTypeEncoding node in the Server's AddressSpace.
35
- // | ExtensionObjects defined by the OPC UA specification have a numeric node
36
- // | identifier assigned to them with a NamespaceIndex of 0. The numeric
37
- // | identifiers are defined in A.1.
38
- //
39
- // Encoding | Byte | An enumeration that indicates how the body is encoded.
40
- // | The parameter may have the following values:
41
- // | 0x00 No body is encoded.
42
- // | 0x01 The body is encoded as a ByteString.
43
- // | 0x02 The body is encoded as a XmlElement.
44
- //
45
- // Length | Int32 | The length of the object body.
46
- // | The length shall be specified if the body is encoded. <<<<<<<( WTF ?)
47
- //
48
- // Body | Byte[*] | The object body
49
- // | This field contains the raw bytes for ByteString bodies.
50
- // | For XmlElement bodies this field contains the XML encoded as a UTF-8
51
- // | string without any null terminator.
52
- //
53
- function encodeExtensionObject(object, stream) {
54
- if (!object) {
55
- (0, node_opcua_basic_types_1.encodeNodeId)((0, node_opcua_nodeid_1.makeNodeId)(0), stream);
56
- stream.writeUInt8(0x00); // no body is encoded
57
- // note : Length shall not hbe specified, end of the job!
58
- }
59
- else {
60
- if (object instanceof OpaqueStructure) {
61
- // Writing raw Opaque buffer as Opaque Structure ...
62
- (0, node_opcua_basic_types_1.encodeNodeId)(object.nodeId, stream);
63
- stream.writeUInt8(0x01); // 0x01 The body is encoded as a ByteString.
64
- stream.writeByteStream(object.buffer);
65
- return;
66
- }
67
- /* istanbul ignore next */
68
- if (!(object instanceof node_opcua_factory_1.BaseUAObject)) {
69
- throw new Error("Expecting a extension object");
70
- }
71
- // ensure we have a valid encoding Default Binary ID !!!
72
- /* istanbul ignore next */
73
- if (!object.schema) {
74
- debugLog(" object = ", object);
75
- throw new Error("object has no schema " + object.constructor.name);
76
- }
77
- const encodingDefaultBinary = object.schema.encodingDefaultBinary;
78
- /* istanbul ignore next */
79
- if (!encodingDefaultBinary) {
80
- debugLog(chalk.yellow("encoding ExtObj "), object);
81
- throw new Error("Cannot find encodingDefaultBinary for this object : " + object.schema.name);
82
- }
83
- /* istanbul ignore next */
84
- if (encodingDefaultBinary.isEmpty()) {
85
- debugLog(chalk.yellow("encoding ExtObj "), object.constructor.encodingDefaultBinary.toString());
86
- throw new Error("Cannot find encodingDefaultBinary for this object : " + object.schema.name);
87
- }
88
- /* istanbul ignore next */
89
- if ((0, node_opcua_factory_1.is_internal_id)(encodingDefaultBinary.value)) {
90
- debugLog(chalk.yellow("encoding ExtObj "), object.constructor.encodingDefaultBinary.toString(), object.schema.name);
91
- throw new Error("Cannot find valid OPCUA encodingDefaultBinary for this object : " + object.schema.name);
92
- }
93
- (0, node_opcua_basic_types_1.encodeNodeId)(encodingDefaultBinary, stream);
94
- stream.writeUInt8(0x01); // 0x01 The body is encoded as a ByteString.
95
- stream.writeUInt32(object.binaryStoreSize());
96
- object.encode(stream);
97
- }
98
- }
99
- exports.encodeExtensionObject = encodeExtensionObject;
100
- // tslint:disable:max-classes-per-file
101
- class OpaqueStructure extends ExtensionObject {
102
- constructor(nodeId, buffer) {
103
- super();
104
- this.nodeId = nodeId;
105
- this.buffer = buffer;
106
- }
107
- toString() {
108
- const str = "/* OpaqueStructure */ { \n" +
109
- "nodeId " +
110
- this.nodeId.toString() +
111
- "\n" +
112
- "buffer = \n" +
113
- (0, node_opcua_debug_1.hexDump)(this.buffer) +
114
- "\n" +
115
- "}";
116
- return str;
117
- }
118
- }
119
- exports.OpaqueStructure = OpaqueStructure;
120
- function decodeExtensionObject(stream, _value) {
121
- const nodeId = (0, node_opcua_basic_types_1.decodeNodeId)(stream);
122
- const encodingType = stream.readUInt8();
123
- if (encodingType === 0) {
124
- return null;
125
- }
126
- const length = stream.readUInt32();
127
- /* istanbul ignore next */
128
- if (nodeId.value === 0 || encodingType === 0) {
129
- return {};
130
- }
131
- // let verify that decode will use the expected number of bytes
132
- const streamLengthBefore = stream.length;
133
- let object;
134
- if (nodeId.namespace !== 0) {
135
- // this is a extension object define in a other namespace
136
- // we can only threat it as an opaque object for the time being
137
- // the caller that may now more about the namespace Array and type
138
- // definition will be able to turn the opaque object into a meaningful
139
- // structure
140
- // lets rewind before the length
141
- stream.length -= 4;
142
- object = new OpaqueStructure(nodeId, stream.readByteStream());
143
- }
144
- else {
145
- try {
146
- object = (0, node_opcua_factory_1.getStandardDataTypeFactory)().constructObject(nodeId);
147
- }
148
- catch (err) {
149
- warningLog("cannot construct object with dataType nodeId", nodeId.toString());
150
- }
151
- /* istanbul ignore next */
152
- if (object === null) {
153
- // this object is unknown to us ..
154
- stream.length -= 4;
155
- object = new OpaqueStructure(nodeId, stream.readByteStream());
156
- }
157
- else {
158
- try {
159
- object.decode(stream);
160
- }
161
- catch (err) {
162
- debugLog("Cannot decode object ", err);
163
- }
164
- }
165
- }
166
- if (streamLengthBefore + length !== stream.length) {
167
- // this may happen if the server or client do have a different OPCUA version
168
- // for instance SubscriptionDiagnostics structure has been changed between OPCUA version 1.01 and 1.04
169
- // causing 2 extra member to be added.
170
- debugLog(chalk.bgWhiteBright.red("========================================="));
171
- warningLog("WARNING => decodeExtensionObject: Extension object decoding error on ", object === null || object === void 0 ? void 0 : object.constructor.name, " expected size was", length, "but only this amount of bytes have been read :", stream.length - streamLengthBefore, "\n encoding nodeId = ", nodeId.toString(), "encodingType = ", encodingType);
172
- stream.length = streamLengthBefore + length;
173
- }
174
- return object;
175
- }
176
- exports.decodeExtensionObject = decodeExtensionObject;
177
- (0, node_opcua_factory_1.registerBuiltInType)({
178
- name: "ExtensionObject",
179
- subType: "",
180
- encode: encodeExtensionObject,
181
- decode: decodeExtensionObject,
182
- defaultValue: () => null
183
- });
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.decodeExtensionObject = exports.OpaqueStructure = exports.encodeExtensionObject = exports.ExtensionObject = void 0;
4
+ /**
5
+ * @module node-opcua-extension-object
6
+ */
7
+ const node_opcua_basic_types_1 = require("node-opcua-basic-types");
8
+ const node_opcua_debug_1 = require("node-opcua-debug");
9
+ const node_opcua_factory_1 = require("node-opcua-factory");
10
+ const node_opcua_nodeid_1 = require("node-opcua-nodeid");
11
+ const debugLog = (0, node_opcua_debug_1.make_debugLog)(__filename);
12
+ const warningLog = (0, node_opcua_debug_1.make_warningLog)(__filename);
13
+ const chalk = require("chalk");
14
+ /* tslint:disable:no-empty */
15
+ class ExtensionObject extends node_opcua_factory_1.BaseUAObject {
16
+ constructor(options) {
17
+ super();
18
+ }
19
+ }
20
+ ExtensionObject.schema = new node_opcua_factory_1.StructuredTypeSchema({
21
+ baseType: "",
22
+ documentation: "",
23
+ fields: [],
24
+ name: "ExtensionObject",
25
+ dataTypeFactory: (0, node_opcua_factory_1.getStandardDataTypeFactory)()
26
+ });
27
+ exports.ExtensionObject = ExtensionObject;
28
+ ExtensionObject.prototype.schema = ExtensionObject.schema;
29
+ // OPC-UA Part 6 - $5.2.2.15 ExtensionObject
30
+ // An ExtensionObject is encoded as sequence of bytes prefixed by the NodeId of its
31
+ // DataTypeEncoding and the number of bytes encoded.
32
+ // what the specs say: OCC/UA part 6 $5.2.2.15 ExtensionObject
33
+ //
34
+ // TypeId | NodeId | The identifier for the DataTypeEncoding node in the Server's AddressSpace.
35
+ // | ExtensionObjects defined by the OPC UA specification have a numeric node
36
+ // | identifier assigned to them with a NamespaceIndex of 0. The numeric
37
+ // | identifiers are defined in A.1.
38
+ //
39
+ // Encoding | Byte | An enumeration that indicates how the body is encoded.
40
+ // | The parameter may have the following values:
41
+ // | 0x00 No body is encoded.
42
+ // | 0x01 The body is encoded as a ByteString.
43
+ // | 0x02 The body is encoded as a XmlElement.
44
+ //
45
+ // Length | Int32 | The length of the object body.
46
+ // | The length shall be specified if the body is encoded. <<<<<<<( WTF ?)
47
+ //
48
+ // Body | Byte[*] | The object body
49
+ // | This field contains the raw bytes for ByteString bodies.
50
+ // | For XmlElement bodies this field contains the XML encoded as a UTF-8
51
+ // | string without any null terminator.
52
+ //
53
+ function encodeExtensionObject(object, stream) {
54
+ if (!object) {
55
+ (0, node_opcua_basic_types_1.encodeNodeId)((0, node_opcua_nodeid_1.makeNodeId)(0), stream);
56
+ stream.writeUInt8(0x00); // no body is encoded
57
+ // note : Length shall not hbe specified, end of the job!
58
+ }
59
+ else {
60
+ if (object instanceof OpaqueStructure) {
61
+ // Writing raw Opaque buffer as Opaque Structure ...
62
+ (0, node_opcua_basic_types_1.encodeNodeId)(object.nodeId, stream);
63
+ stream.writeUInt8(0x01); // 0x01 The body is encoded as a ByteString.
64
+ stream.writeByteStream(object.buffer);
65
+ return;
66
+ }
67
+ /* istanbul ignore next */
68
+ if (!(object instanceof node_opcua_factory_1.BaseUAObject)) {
69
+ throw new Error("Expecting a extension object");
70
+ }
71
+ // ensure we have a valid encoding Default Binary ID !!!
72
+ /* istanbul ignore next */
73
+ if (!object.schema) {
74
+ debugLog(" object = ", object);
75
+ throw new Error("object has no schema " + object.constructor.name);
76
+ }
77
+ const encodingDefaultBinary = object.schema.encodingDefaultBinary;
78
+ /* istanbul ignore next */
79
+ if (!encodingDefaultBinary) {
80
+ debugLog(chalk.yellow("encoding ExtObj "), object);
81
+ throw new Error("Cannot find encodingDefaultBinary for this object : " + object.schema.name);
82
+ }
83
+ /* istanbul ignore next */
84
+ if (encodingDefaultBinary.isEmpty()) {
85
+ debugLog(chalk.yellow("encoding ExtObj "), object.constructor.encodingDefaultBinary.toString());
86
+ throw new Error("Cannot find encodingDefaultBinary for this object : " + object.schema.name);
87
+ }
88
+ /* istanbul ignore next */
89
+ if ((0, node_opcua_factory_1.is_internal_id)(encodingDefaultBinary.value)) {
90
+ debugLog(chalk.yellow("encoding ExtObj "), object.constructor.encodingDefaultBinary.toString(), object.schema.name);
91
+ throw new Error("Cannot find valid OPCUA encodingDefaultBinary for this object : " + object.schema.name);
92
+ }
93
+ (0, node_opcua_basic_types_1.encodeNodeId)(encodingDefaultBinary, stream);
94
+ stream.writeUInt8(0x01); // 0x01 The body is encoded as a ByteString.
95
+ stream.writeUInt32(object.binaryStoreSize());
96
+ object.encode(stream);
97
+ }
98
+ }
99
+ exports.encodeExtensionObject = encodeExtensionObject;
100
+ // tslint:disable:max-classes-per-file
101
+ class OpaqueStructure extends ExtensionObject {
102
+ constructor(nodeId, buffer) {
103
+ super();
104
+ this.nodeId = nodeId;
105
+ this.buffer = buffer;
106
+ }
107
+ toString() {
108
+ const str = "/* OpaqueStructure */ { \n" +
109
+ "nodeId " +
110
+ this.nodeId.toString() +
111
+ "\n" +
112
+ "buffer = \n" +
113
+ (0, node_opcua_debug_1.hexDump)(this.buffer) +
114
+ "\n" +
115
+ "}";
116
+ return str;
117
+ }
118
+ }
119
+ exports.OpaqueStructure = OpaqueStructure;
120
+ function decodeExtensionObject(stream, _value) {
121
+ const nodeId = (0, node_opcua_basic_types_1.decodeNodeId)(stream);
122
+ const encodingType = stream.readUInt8();
123
+ if (encodingType === 0) {
124
+ return null;
125
+ }
126
+ const length = stream.readUInt32();
127
+ /* istanbul ignore next */
128
+ if (nodeId.value === 0 || encodingType === 0) {
129
+ return {};
130
+ }
131
+ // let verify that decode will use the expected number of bytes
132
+ const streamLengthBefore = stream.length;
133
+ let object;
134
+ if (nodeId.namespace !== 0) {
135
+ // this is a extension object define in a other namespace
136
+ // we can only threat it as an opaque object for the time being
137
+ // the caller that may now more about the namespace Array and type
138
+ // definition will be able to turn the opaque object into a meaningful
139
+ // structure
140
+ // lets rewind before the length
141
+ stream.length -= 4;
142
+ object = new OpaqueStructure(nodeId, stream.readByteStream());
143
+ }
144
+ else {
145
+ try {
146
+ object = (0, node_opcua_factory_1.getStandardDataTypeFactory)().constructObject(nodeId);
147
+ }
148
+ catch (err) {
149
+ warningLog("cannot construct object with dataType nodeId", nodeId.toString());
150
+ }
151
+ /* istanbul ignore next */
152
+ if (object === null) {
153
+ // this object is unknown to us ..
154
+ stream.length -= 4;
155
+ object = new OpaqueStructure(nodeId, stream.readByteStream());
156
+ }
157
+ else {
158
+ try {
159
+ object.decode(stream);
160
+ }
161
+ catch (err) {
162
+ debugLog("Cannot decode object ", err);
163
+ }
164
+ }
165
+ }
166
+ if (streamLengthBefore + length !== stream.length) {
167
+ // this may happen if the server or client do have a different OPCUA version
168
+ // for instance SubscriptionDiagnostics structure has been changed between OPCUA version 1.01 and 1.04
169
+ // causing 2 extra member to be added.
170
+ debugLog(chalk.bgWhiteBright.red("========================================="));
171
+ warningLog("WARNING => decodeExtensionObject: Extension object decoding error on ", object === null || object === void 0 ? void 0 : object.constructor.name, " expected size was", length, "but only this amount of bytes have been read :", stream.length - streamLengthBefore, "\n encoding nodeId = ", nodeId.toString(), "encodingType = ", encodingType);
172
+ stream.length = streamLengthBefore + length;
173
+ }
174
+ return object;
175
+ }
176
+ exports.decodeExtensionObject = decodeExtensionObject;
177
+ (0, node_opcua_factory_1.registerBuiltInType)({
178
+ name: "ExtensionObject",
179
+ subType: "",
180
+ encode: encodeExtensionObject,
181
+ decode: decodeExtensionObject,
182
+ defaultValue: () => null
183
+ });
184
184
  //# sourceMappingURL=extension_object.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"extension_object.js","sourceRoot":"","sources":["../source/extension_object.ts"],"names":[],"mappings":";;;AAAA;;GAEG;AACH,mEAAoE;AAEpE,uDAA2F;AAC3F,2DAO4B;AAC5B,yDAAuE;AAEvE,MAAM,QAAQ,GAAG,IAAA,gCAAa,EAAC,UAAU,CAAC,CAAC;AAC3C,MAAM,UAAU,GAAG,IAAA,kCAAe,EAAC,UAAU,CAAC,CAAC;AAE/C,+BAA+B;AAE/B,6BAA6B;AAC7B,MAAa,eAAgB,SAAQ,iCAAY;IAS7C,YAAY,OAAoC;QAC5C,KAAK,EAAE,CAAC;IACZ,CAAC;;AAXL,0CAYC;AAXiB,sBAAM,GAA0B,IAAI,yCAAoB,CAAC;IACnE,QAAQ,EAAE,EAAE;IACZ,aAAa,EAAE,EAAE;IACjB,MAAM,EAAE,EAAE;IACV,IAAI,EAAE,iBAAiB;IACvB,eAAe,EAAE,IAAA,+CAA0B,GAAE;CAChD,CAAC,CAAC;AAOP,eAAe,CAAC,SAAS,CAAC,MAAM,GAAG,eAAe,CAAC,MAAM,CAAC;AAE1D,4CAA4C;AAC5C,oFAAoF;AACpF,oDAAoD;AAEpD,+DAA+D;AAC/D,EAAE;AACF,mGAAmG;AACnG,iGAAiG;AACjG,4FAA4F;AAC5F,wDAAwD;AACxD,EAAE;AACF,+EAA+E;AAC/E,qEAAqE;AACrE,sDAAsD;AACtD,uEAAuE;AACvE,uEAAuE;AACvE,EAAE;AACF,uDAAuD;AACvD,kGAAkG;AAClG,EAAE;AACF,wCAAwC;AACxC,iFAAiF;AACjF,6FAA6F;AAC7F,4DAA4D;AAC5D,EAAE;AAEF,SAAgB,qBAAqB,CAAC,MAA2B,EAAE,MAA0B;IACzF,IAAI,CAAC,MAAM,EAAE;QACT,IAAA,qCAAY,EAAC,IAAA,8BAAU,EAAC,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;QACpC,MAAM,CAA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G,EAAE,CAAC,IAAI;CAC3B,CAAC,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- /**
2
- * @module node-opcua-extension-object
3
- */
4
- export * from "./extension_object";
1
+ /**
2
+ * @module node-opcua-extension-object
3
+ */
4
+ export * from "./extension_object";
package/dist/index.js CHANGED
@@ -1,21 +1,21 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- /**
18
- * @module node-opcua-extension-object
19
- */
20
- __exportStar(require("./extension_object"), exports);
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ /**
18
+ * @module node-opcua-extension-object
19
+ */
20
+ __exportStar(require("./extension_object"), exports);
21
21
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "node-opcua-extension-object",
3
- "version": "2.97.0",
4
- "description": "pure nodejs OPCUA SDK - module -extension-object",
3
+ "version": "2.98.1",
4
+ "description": "pure nodejs OPCUA SDK - module extension-object",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
7
7
  "scripts": {
@@ -13,11 +13,11 @@
13
13
  },
14
14
  "dependencies": {
15
15
  "chalk": "4.1.2",
16
- "node-opcua-basic-types": "2.97.0",
17
- "node-opcua-binary-stream": "2.90.1",
18
- "node-opcua-debug": "2.90.1",
19
- "node-opcua-factory": "2.97.0",
20
- "node-opcua-nodeid": "2.97.0"
16
+ "node-opcua-basic-types": "2.98.1",
17
+ "node-opcua-binary-stream": "2.98.1",
18
+ "node-opcua-debug": "2.98.1",
19
+ "node-opcua-factory": "2.98.1",
20
+ "node-opcua-nodeid": "2.98.1"
21
21
  },
22
22
  "author": "Etienne Rossignon",
23
23
  "license": "MIT",
@@ -34,5 +34,9 @@
34
34
  "internet of things"
35
35
  ],
36
36
  "homepage": "http://node-opcua.github.io/",
37
- "gitHead": "19c96bda0810d2dec73dd1c2427546be40908646"
37
+ "gitHead": "07dcdd8e8c7f2b55544c6e23023093e35674829c",
38
+ "files": [
39
+ "dist",
40
+ "source"
41
+ ]
38
42
  }