node-opcua-address-space-base 2.96.0 → 2.98.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 (78) hide show
  1. package/package.json +13 -13
  2. package/source/base_node.ts +2 -0
  3. package/source/clone_options.ts +11 -2
  4. package/dist/address_space.d.ts +0 -176
  5. package/dist/address_space.js +0 -3
  6. package/dist/address_space.js.map +0 -1
  7. package/dist/base_node.d.ts +0 -186
  8. package/dist/base_node.js +0 -4
  9. package/dist/base_node.js.map +0 -1
  10. package/dist/bind_variable.d.ts +0 -52
  11. package/dist/bind_variable.js +0 -3
  12. package/dist/bind_variable.js.map +0 -1
  13. package/dist/clone_options.d.ts +0 -44
  14. package/dist/clone_options.js +0 -19
  15. package/dist/clone_options.js.map +0 -1
  16. package/dist/continuation_point.d.ts +0 -2
  17. package/dist/continuation_point.js +0 -3
  18. package/dist/continuation_point.js.map +0 -1
  19. package/dist/event_notifier_flags.d.ts +0 -7
  20. package/dist/event_notifier_flags.js +0 -12
  21. package/dist/event_notifier_flags.js.map +0 -1
  22. package/dist/i_event_data.d.ts +0 -17
  23. package/dist/i_event_data.js +0 -3
  24. package/dist/i_event_data.js.map +0 -1
  25. package/dist/index.d.ts +0 -23
  26. package/dist/index.js +0 -40
  27. package/dist/index.js.map +0 -1
  28. package/dist/instantiate_options.d.ts +0 -80
  29. package/dist/instantiate_options.js +0 -3
  30. package/dist/instantiate_options.js.map +0 -1
  31. package/dist/modelling_rule_type.d.ts +0 -1
  32. package/dist/modelling_rule_type.js +0 -3
  33. package/dist/modelling_rule_type.js.map +0 -1
  34. package/dist/namespace.d.ts +0 -287
  35. package/dist/namespace.js +0 -3
  36. package/dist/namespace.js.map +0 -1
  37. package/dist/session_context.d.ts +0 -56
  38. package/dist/session_context.js +0 -12
  39. package/dist/session_context.js.map +0 -1
  40. package/dist/ua_data_type.d.ts +0 -34
  41. package/dist/ua_data_type.js +0 -3
  42. package/dist/ua_data_type.js.map +0 -1
  43. package/dist/ua_dynamic_variable_array.d.ts +0 -14
  44. package/dist/ua_dynamic_variable_array.js +0 -3
  45. package/dist/ua_dynamic_variable_array.js.map +0 -1
  46. package/dist/ua_event_type.d.ts +0 -3
  47. package/dist/ua_event_type.js +0 -3
  48. package/dist/ua_event_type.js.map +0 -1
  49. package/dist/ua_method.d.ts +0 -41
  50. package/dist/ua_method.js +0 -5
  51. package/dist/ua_method.js.map +0 -1
  52. package/dist/ua_object.d.ts +0 -131
  53. package/dist/ua_object.js +0 -3
  54. package/dist/ua_object.js.map +0 -1
  55. package/dist/ua_object_type.d.ts +0 -29
  56. package/dist/ua_object_type.js +0 -3
  57. package/dist/ua_object_type.js.map +0 -1
  58. package/dist/ua_property.d.ts +0 -16
  59. package/dist/ua_property.js +0 -3
  60. package/dist/ua_property.js.map +0 -1
  61. package/dist/ua_reference.d.ts +0 -12
  62. package/dist/ua_reference.js +0 -3
  63. package/dist/ua_reference.js.map +0 -1
  64. package/dist/ua_reference_type.d.ts +0 -20
  65. package/dist/ua_reference_type.js +0 -4
  66. package/dist/ua_reference_type.js.map +0 -1
  67. package/dist/ua_variable.d.ts +0 -290
  68. package/dist/ua_variable.js +0 -3
  69. package/dist/ua_variable.js.map +0 -1
  70. package/dist/ua_variable_t.d.ts +0 -15
  71. package/dist/ua_variable_t.js +0 -3
  72. package/dist/ua_variable_t.js.map +0 -1
  73. package/dist/ua_variable_type.d.ts +0 -55
  74. package/dist/ua_variable_type.js +0 -4
  75. package/dist/ua_variable_type.js.map +0 -1
  76. package/dist/ua_view.d.ts +0 -7
  77. package/dist/ua_view.js +0 -3
  78. package/dist/ua_view.js.map +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-opcua-address-space-base",
3
- "version": "2.96.0",
3
+ "version": "2.98.0",
4
4
  "description": "pure nodejs OPCUA SDK - module -address-space",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -16,19 +16,19 @@
16
16
  "c": "mocha --version"
17
17
  },
18
18
  "dependencies": {
19
- "node-opcua-basic-types": "2.92.0",
19
+ "node-opcua-basic-types": "2.98.0",
20
20
  "node-opcua-constants": "2.88.0",
21
21
  "node-opcua-crypto": "^2.1.2",
22
- "node-opcua-data-model": "2.95.0",
23
- "node-opcua-data-value": "2.95.0",
24
- "node-opcua-date-time": "2.90.1",
25
- "node-opcua-extension-object": "2.95.0",
26
- "node-opcua-nodeid": "2.90.1",
27
- "node-opcua-numeric-range": "2.95.0",
28
- "node-opcua-schemas": "2.96.0",
29
- "node-opcua-status-code": "2.90.1",
30
- "node-opcua-types": "2.96.0",
31
- "node-opcua-variant": "2.95.0"
22
+ "node-opcua-data-model": "2.98.0",
23
+ "node-opcua-data-value": "2.98.0",
24
+ "node-opcua-date-time": "2.98.0",
25
+ "node-opcua-extension-object": "2.98.0",
26
+ "node-opcua-nodeid": "2.98.0",
27
+ "node-opcua-numeric-range": "2.98.0",
28
+ "node-opcua-schemas": "2.98.0",
29
+ "node-opcua-status-code": "2.98.0",
30
+ "node-opcua-types": "2.98.0",
31
+ "node-opcua-variant": "2.98.0"
32
32
  },
33
33
  "author": "Etienne Rossignon",
34
34
  "license": "MIT",
@@ -45,5 +45,5 @@
45
45
  "internet of things"
46
46
  ],
47
47
  "homepage": "http://node-opcua.github.io/",
48
- "gitHead": "43642e4aaa1ca2a3938b044cc2237544dfff764a"
48
+ "gitHead": "07dcdd8e8c7f2b55544c6e23023093e35674829c"
49
49
  }
@@ -100,6 +100,8 @@ export declare class BaseNode extends EventEmitter {
100
100
  public get namespaceUri(): string;
101
101
  public get namespace(): INamespace;
102
102
 
103
+ public isDisposed(): boolean;
104
+
103
105
  public onFirstBrowseAction?: (this: BaseNode) => Promise<void>;
104
106
 
105
107
  /**
@@ -26,14 +26,23 @@ export interface CloneExtraInfo {
26
26
  level: number;
27
27
  pad(): string;
28
28
  registerClonedObject(clonedObject: BaseNode, originalObject: BaseNode): void;
29
+ getCloned(node: BaseNode): BaseNode | null;
29
30
  }
30
- export const defaultCloneExtraInfo: CloneExtraInfo = {
31
+ interface CloneExtraInfoEx extends CloneExtraInfo {
32
+ _cloned: Map<BaseNode, BaseNode>;
33
+ }
34
+ export const defaultCloneExtraInfo: CloneExtraInfoEx = {
31
35
  level: 0,
36
+ _cloned: new Map<BaseNode, BaseNode>(),
32
37
  pad(this: CloneExtraInfo) {
33
38
  return " ".padEnd(this.level * 2);
34
39
  },
35
40
  registerClonedObject(_clonedObject: BaseNode, _originalObject: BaseNode): void {
36
- // nothing to do
41
+ if(this.getCloned(_originalObject)) throw new Error("cloned object is already registered.");
42
+ this._cloned.set(_originalObject, _clonedObject);
43
+ },
44
+ getCloned(node: BaseNode): BaseNode | null {
45
+ return this._cloned.get(node) || null;
37
46
  }
38
47
  };
39
48
 
@@ -1,176 +0,0 @@
1
- import { ExtensionObject } from "node-opcua-extension-object";
2
- import { NodeId, NodeIdLike } from "node-opcua-nodeid";
3
- import { AnyConstructorFunc } from "node-opcua-schemas";
4
- import { BrowseDescription, BrowsePath, BrowsePathResult, BrowseResult } from "node-opcua-types";
5
- import { DataType, VariantByteString } from "node-opcua-variant";
6
- import { AddReferenceOpts, BaseNode } from "./base_node";
7
- import { INamespace } from "./namespace";
8
- import { ISessionContext } from "./session_context";
9
- import { UADataType } from "./ua_data_type";
10
- import { IEventData } from "./i_event_data";
11
- import { UAMethod } from "./ua_method";
12
- import { UAObject } from "./ua_object";
13
- import { UAEventType } from "./ua_event_type";
14
- import { UAObjectType } from "./ua_object_type";
15
- import { UAReference } from "./ua_reference";
16
- import { UAReferenceType } from "./ua_reference_type";
17
- import { IHistoricalDataNodeOptions, UAVariable } from "./ua_variable";
18
- import { UAVariableType } from "./ua_variable_type";
19
- import { UAView } from "./ua_view";
20
- export declare type ShutdownTask = ((this: IAddressSpace) => void) | ((this: IAddressSpace) => Promise<void>);
21
- interface UARootFolder_Objects extends UAObject {
22
- server: UAObject;
23
- }
24
- export interface IAddressSpace {
25
- rootFolder: {
26
- objects: UARootFolder_Objects;
27
- views: UAObject;
28
- types: UAObject;
29
- };
30
- historizingNodes?: {
31
- [key: string]: UAVariable;
32
- };
33
- /**
34
- * when this flag is set, properties and components are not added as javascript
35
- * member of the UAObject/UAVariable node
36
- */
37
- isFrugal: boolean;
38
- resolveNodeId(nodeIdLike: NodeIdLike): NodeId;
39
- findNode(node: NodeIdLike): BaseNode | null;
40
- /**
41
- *
42
- * @example
43
- *
44
- * ```javascript
45
- * const variableType = addressSpace.findVariableType("ns=0;i=62");
46
- * variableType.browseName.toString().should.eql("BaseVariableType");
47
- *
48
- * const variableType = addressSpace.findVariableType("BaseVariableType");
49
- * variableType.browseName.toString().should.eql("BaseVariableType");
50
- *
51
- * const variableType = addressSpace.findVariableType(resolveNodeId("ns=0;i=62"));
52
- * variableType.browseName.toString().should.eql("BaseVariableType");
53
- * ```
54
- */
55
- findVariableType(variableTypeId: NodeIdLike, namespaceIndex?: number): UAVariableType | null;
56
- findMethod(nodeId: NodeIdLike): UAMethod | null;
57
- /**
58
- * find an EventType node in the address space
59
- *
60
- * @param objectTypeId the eventType to find
61
- * @param namespaceIndex an optional index to restrict the search in a given namespace
62
- * @return the EventType found or null.
63
- *
64
- * notes:
65
- *
66
- * - if objectTypeId is of type NodeId, the namespaceIndex shall not be specified
67
- * @example
68
- *
69
- * ```ts
70
- * const objectType = addressSpace.findObjectType("ns=0;i=58");
71
- * objectType.browseName.toString().should.eql("BaseObjectType");
72
- *
73
- * const objectType = addressSpace.findObjectType("BaseObjectType");
74
- * objectType.browseName.toString().should.eql("BaseObjectType");
75
- *
76
- * const objectType = addressSpace.findObjectType(resolveNodeId("ns=0;i=58"));
77
- * objectType.browseName.toString().should.eql("BaseObjectType");
78
- *
79
- * const objectType = addressSpace.findObjectType("CustomObjectType",36);
80
- * objectType.nodeId.namespace.should.eql(36);
81
- * objectType.browseName.toString().should.eql("BaseObjectType");
82
- *
83
- * const objectType = addressSpace.findObjectType("36:CustomObjectType");
84
- * objectType.nodeId.namespace.should.eql(36);
85
- * objectType.browseName.toString().should.eql("BaseObjectType");
86
- * ```
87
- */
88
- findObjectType(objectTypeId: NodeIdLike, namespaceIndex?: number): UAObjectType | null;
89
- /**
90
- * find an EventType node in the address space
91
- *
92
- * @param eventTypeId the eventType to find
93
- * @param namespaceIndex an optional index to restrict the search in a given namespace
94
- * @return the EventType found or null.
95
- *
96
- * note:
97
- * - the method with throw an exception if a node is found
98
- * that is not a BaseEventType or a subtype of it.
99
- * - if eventTypeId is of type NodeId, the namespaceIndex shall not be specified
100
- *
101
- * @example
102
- *
103
- * ```javascript
104
- * const evtType = addressSpace.findEventType("AuditEventType");
105
- * ```
106
- *
107
- */
108
- findEventType(eventTypeId: NodeIdLike | UAObjectType, namespaceIndex?: number): UAObjectType | null;
109
- findReferenceType(referenceTypeId: NodeIdLike | UAReferenceType, namespaceIndex?: number): UAReferenceType | null;
110
- /**
111
- * find a ReferenceType by its inverse name.
112
- * @param inverseName the inverse name of the ReferenceType to find
113
- */
114
- findReferenceTypeFromInverseName(inverseName: string): UAReferenceType | null;
115
- findDataType(dataType: string | NodeId | UADataType | DataType, namespaceIndex?: number): UADataType | null;
116
- findCorrespondingBasicDataType(dataType: NodeIdLike | UADataType): DataType;
117
- deleteNode(node: NodeId | BaseNode): void;
118
- getDefaultNamespace(): INamespace;
119
- getOwnNamespace(): INamespace;
120
- getNamespace(indexOrName: number | string): INamespace;
121
- registerNamespace(namespaceUri: string): INamespace;
122
- getNamespaceIndex(namespaceUri: string): number;
123
- getNamespaceUri(namespaceIndex: number): string;
124
- getNamespaceArray(): INamespace[];
125
- browseSingleNode(nodeId: NodeIdLike, browseDescription: BrowseDescription, context?: ISessionContext): BrowseResult;
126
- browsePath(browsePath: BrowsePath): BrowsePathResult;
127
- inverseReferenceType(referenceType: string): string;
128
- /**
129
- * get the extension object constructor from a DataType nodeID or UADataType object
130
- */
131
- getExtensionObjectConstructor(dataType: NodeId | UADataType): AnyConstructorFunc;
132
- /**
133
- * construct an extension object constructor from a DataType nodeID or UADataType object
134
- *
135
- */
136
- constructExtensionObject(dataType: UADataType | NodeId, options?: Record<string, unknown>): ExtensionObject;
137
- /***
138
- * construct a simple javascript object with all the default properties of the event
139
- *
140
- * @return result.$eventDataSource the event type node
141
- * @return result.eventId the
142
- * ...
143
- *
144
- *
145
- * eventTypeId can be a UAObjectType deriving from EventType
146
- * or an instance of a ConditionType
147
- *
148
- */
149
- constructEventData(eventTypeId: UAEventType, data: any): IEventData;
150
- /**
151
- * walk up the hierarchy of objects until a view is found
152
- * objects may belong to multiples views.
153
- * Note: this method doesn't return the main view => Server object.
154
- * @param node
155
- * @internal
156
- */
157
- extractRootViews(node: UAObject | UAVariable): UAView[];
158
- installHistoricalDataNode(variableNode: UAVariable, options?: IHistoricalDataNodeOptions): void;
159
- /**
160
- * register a task that will be executed just before the address space is disposed.
161
- */
162
- registerShutdownTask(task: ShutdownTask): void;
163
- /**
164
- * shutdown the address space by executingthe registered shutdown tasks.
165
- * @see registerShutdownTask, dispose
166
- */
167
- shutdown(): Promise<void>;
168
- dispose(): void;
169
- installAlarmsAndConditionsService(): void;
170
- normalizeReferenceType(params: AddReferenceOpts | UAReference): UAReference;
171
- /**
172
- * EventId is generated by the Server to uniquely identify a particular Event Notification.
173
- */
174
- generateEventId(): VariantByteString;
175
- }
176
- export {};
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=address_space.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"address_space.js","sourceRoot":"","sources":["../source/address_space.ts"],"names":[],"mappings":""}
@@ -1,186 +0,0 @@
1
- /// <reference types="node" />
2
- import { EventEmitter } from "events";
3
- export declare type Duration = number;
4
- import { AccessRestrictionsFlag, AttributeIds, BrowseDirection, LocalizedText, NodeClass, QualifiedName, QualifiedNameLike, QualifiedNameOptions } from "node-opcua-data-model";
5
- import { DataType } from "node-opcua-variant";
6
- import { DataValue } from "node-opcua-data-value";
7
- import { NodeId, NodeIdLike } from "node-opcua-nodeid";
8
- import { NumericRange } from "node-opcua-numeric-range";
9
- import { StatusCode } from "node-opcua-status-code";
10
- import { BrowseDescriptionOptions, ReferenceDescription, RelativePathElement, RolePermissionType, RolePermissionTypeOptions, WriteValueOptions } from "node-opcua-types";
11
- import { UAString, UInt32 } from "node-opcua-basic-types";
12
- import { ReferenceTypeIds } from "node-opcua-constants";
13
- import { INamespace } from "./namespace";
14
- import { IAddressSpace } from "./address_space";
15
- import { ModellingRuleType } from "./modelling_rule_type";
16
- import { ISessionContext } from "./session_context";
17
- import { UAObject } from "./ua_object";
18
- import { UAReferenceType } from "./ua_reference_type";
19
- import { UAVariable } from "./ua_variable";
20
- import { UAVariableT } from "./ua_variable_t";
21
- import { UAReference } from "./ua_reference";
22
- export declare interface AddReferenceOpts {
23
- referenceType: keyof ReferenceTypeIds | NodeIdLike | UAReferenceType;
24
- nodeId: NodeIdLike | BaseNode;
25
- /**
26
- * default = true
27
- */
28
- isForward?: boolean;
29
- _referenceType?: UAReferenceType;
30
- node?: BaseNode;
31
- }
32
- export interface ConstructNodeIdOptions {
33
- nodeId?: NodeIdLike | null;
34
- browseName: QualifiedName;
35
- nodeClass: NodeClass;
36
- references?: UAReference[];
37
- }
38
- export interface IPropertyAndComponentHolder {
39
- getComponentByName(componentName: QualifiedNameOptions): UAObject | UAVariable | null;
40
- getComponentByName(componentName: string, namespaceIndex?: number): UAObject | UAVariable | null;
41
- getPropertyByName(propertyName: QualifiedNameOptions): UAVariable | null;
42
- getPropertyByName(propertyName: string, namespaceIndex?: number): UAVariable | null;
43
- getAggregates(): BaseNode[];
44
- getComponents(): BaseNode[];
45
- getProperties(): BaseNode[];
46
- getNotifiers(): BaseNode[];
47
- }
48
- export interface BrowseDescriptionOptions2 extends BrowseDescriptionOptions {
49
- browseDirection?: BrowseDirection;
50
- referenceTypeId?: NodeIdLike;
51
- includeSubtypes?: boolean;
52
- nodeClassMask: UInt32;
53
- resultMask: UInt32;
54
- }
55
- export declare class BaseNode extends EventEmitter {
56
- get addressSpace(): IAddressSpace;
57
- readonly browseName: QualifiedName;
58
- get displayName(): LocalizedText[];
59
- get description(): LocalizedText;
60
- readonly nodeClass: NodeClass;
61
- readonly nodeId: NodeId;
62
- get modellingRule(): ModellingRuleType | undefined;
63
- get parentNodeId(): NodeId | undefined;
64
- get accessRestrictions(): AccessRestrictionsFlag | undefined;
65
- get rolePermissions(): RolePermissionType[] | undefined;
66
- get namespaceIndex(): number;
67
- get namespaceUri(): string;
68
- get namespace(): INamespace;
69
- onFirstBrowseAction?: (this: BaseNode) => Promise<void>;
70
- /**
71
- * return a complete name of this object by pre-pending
72
- * name of its parent(s) to its own name
73
- */
74
- fullName(): string;
75
- addReference(options: AddReferenceOpts): void;
76
- removeReference(referenceOpts: AddReferenceOpts): void;
77
- readAttribute(context: ISessionContext | null, attributeId: AttributeIds, indexRange?: NumericRange, dataEncoding?: QualifiedNameLike | null): DataValue;
78
- writeAttribute(context: ISessionContext | null, writeValue: WriteValueOptions, callback: (err: Error | null, statusCode?: StatusCode) => void): void;
79
- /**
80
- * return a array with the event source of this object.
81
- * self = HasEventSource => nodes
82
- */
83
- getEventSources(): BaseNode[];
84
- /**
85
- * return a array of the objects for which this node is an EventSource
86
- * nodes = HasEventSource => self
87
- */
88
- getEventSourceOfs(): BaseNode[];
89
- /**
90
- *
91
- * @param locale the locale of the text to return (e.g. en-EN)
92
- */
93
- getDisplayName(locale?: string): string;
94
- /**
95
- * private
96
- */
97
- install_extra_properties(): void;
98
- browseNodeByTargetName(relativePathElement: RelativePathElement, isLast: boolean): NodeId[];
99
- /**
100
- * find all the references that are of type **`reference`** or a sub type of **`reference`**, in the
101
- * direction specified by **`browseDirection`**
102
- *
103
- * * BrowseDirection.Forward direction is implied if browseDirection flags is omitted.
104
- */
105
- findReferencesEx(referenceType: string | NodeId | UAReferenceType, browseDirection?: BrowseDirection): UAReference[];
106
- /**
107
- * find all the references that are strictly of type **`reference`**.
108
- * The isForward boolean flag specifies the direction of the references to be looked for.
109
- *
110
- * Forward direction is implied if omitted.
111
- */
112
- findReferences(referenceType: string | NodeId | UAReferenceType, isForward?: boolean): UAReference[];
113
- /**
114
- * find the the references that are strictly of type **`reference`**.
115
- *
116
- * The isForward boolean flag specifies the direction of the references to be looked for.
117
- *
118
- * Forward direction is implied if omitted.
119
- *
120
- * * will throw an exception if more than one reference exists with the referenceType.
121
- * * will return null if no reference exists.
122
- */
123
- findReference(referenceType: string | NodeId | UAReferenceType, isForward?: boolean): UAReference | null;
124
- /**
125
- * find all the nodes that are referenced by references of type **`reference`** or a sub type of **`reference`**, in the
126
- * direction specified by **`browseDirection`**
127
- *
128
- * * BrowseDirection.Forward direction is implied if browseDirection flags is omitted.
129
- */
130
- findReferencesExAsObject(referenceType: string | NodeId | UAReferenceType, browseDirection?: BrowseDirection): BaseNode[];
131
- /**
132
- * find all the nodes that are referenced by references strictly of type **`reference`**.
133
- *
134
- * The isForward boolean flag specifies the direction of the references to be looked for.
135
- *
136
- * Forward direction is implied if omitted.
137
- *
138
- * * will throw an exception if more than one reference exists with the referenceType.
139
- * * will return null if no reference exists.
140
- */
141
- findReferencesAsObject(referenceType: string | NodeId | UAReferenceType, isForward?: boolean): BaseNode[];
142
- allReferences(): UAReference[];
143
- getChildByName(browseName: QualifiedNameOptions): BaseNode | null;
144
- getChildByName(browseName: string, namespaceIndex?: number): BaseNode | null;
145
- /**
146
- * this methods propagates the forward references to the pointed node
147
- * by inserting backward references to the counter part node
148
- *
149
- * @private
150
- */
151
- propagate_back_references(): void;
152
- /**
153
- * browse the node to extract information requested in browseDescription
154
- */
155
- browseNode(browseDescription: BrowseDescriptionOptions2, session?: ISessionContext): ReferenceDescription[];
156
- /**
157
- *
158
- * @param rolePermissions
159
- */
160
- setRolePermissions(rolePermissions: RolePermissionTypeOptions[]): void;
161
- getRolePermissions(inherited: boolean): RolePermissionType[] | null;
162
- /**
163
- * setAccessRestriction
164
- */
165
- setAccessRestrictions(accessRestrictions: AccessRestrictionsFlag): void;
166
- /**
167
- * get effective accessRestrictions
168
- * if (inherited is true) and node has no accessRestrictions, then
169
- * default accessRestriction from namespace is returned
170
- * if (inherited is false) and node has no accessRestrictions, then
171
- * AccessRestrictionsFlag.None is returned
172
- *
173
- */
174
- getAccessRestrictions(inherited: boolean): AccessRestrictionsFlag;
175
- /**
176
- * NodeVersion (Optional) String The NodeVersion Property is used to indicate the version of a Node.
177
- * The NodeVersion Property is updated each time a Reference is added or deleted to the Node the Property
178
- * belongs to. Attribute value changes do not cause the NodeVersion to change.
179
- * Clients may read the NodeVersion Property or subscribe to it to determine when the structure of a Node has changed.
180
- */
181
- nodeVersion?: UAVariableT<UAString, DataType.String>;
182
- /**
183
- *
184
- */
185
- getAggregates(): BaseNode[];
186
- }
package/dist/base_node.js DELETED
@@ -1,4 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const events_1 = require("events");
4
- //# sourceMappingURL=base_node.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base_node.js","sourceRoot":"","sources":["../source/base_node.ts"],"names":[],"mappings":";;AAAA,mCAAsC"}
@@ -1,52 +0,0 @@
1
- import { Variant, VariantLike } from "node-opcua-variant";
2
- import { CallbackT, StatusCode } from "node-opcua-status-code";
3
- import { HistoryReadResult, ReadAtTimeDetails, ReadEventDetails, ReadProcessedDetails, ReadRawModifiedDetails } from "node-opcua-types";
4
- import { NumericRange } from "node-opcua-numeric-range";
5
- import { QualifiedNameLike } from "node-opcua-data-model";
6
- import { DataValue } from "node-opcua-data-value";
7
- import { UAVariable } from "./ua_variable";
8
- import { ContinuationData, ISessionContext } from "./session_context";
9
- export declare type VariableSetterVariation1 = (this: UAVariable, value: Variant) => StatusCode;
10
- export declare type VariableSetterVariation2 = (this: UAVariable, value: Variant, callback: CallbackT<StatusCode>) => void;
11
- export declare type VariableSetter = VariableSetterVariation1 | VariableSetterVariation2;
12
- export declare type HistoryReadFunc = (context: ISessionContext, historyReadDetails: ReadRawModifiedDetails | ReadEventDetails | ReadProcessedDetails | ReadAtTimeDetails, indexRange: NumericRange | null, dataEncoding: QualifiedNameLike | null, continuationData: ContinuationData, callback: CallbackT<HistoryReadResult>) => void;
13
- export declare type GetFunc = (this: UAVariable) => Variant;
14
- export declare type SetFunc = VariableSetter | null;
15
- export declare type VariableDataValueGetterSync = (this: UAVariable) => DataValue;
16
- export declare type VariableDataValueGetterPromise = (this: UAVariable) => Promise<DataValue>;
17
- export declare type VariableDataValueGetterCallback = (this: UAVariable, callback: CallbackT<DataValue>) => void;
18
- export declare type VariableDataValueSetterWithCallback = (this: UAVariable, dataValue: DataValue, callback: CallbackT<StatusCode>) => void;
19
- export declare type VariableDataValueSetterWithPromise = (this: UAVariable, dataValue: DataValue) => Promise<StatusCode>;
20
- export declare type TimestampGetFunc = VariableDataValueGetterSync | VariableDataValueGetterPromise | VariableDataValueGetterCallback;
21
- export declare type TimestampSetFunc = VariableDataValueSetterWithCallback | VariableDataValueSetterWithPromise;
22
- export interface BindVariableOptionsVariation1 {
23
- get: GetFunc;
24
- set?: SetFunc;
25
- timestamped_get?: undefined;
26
- timestamped_set?: undefined;
27
- historyRead?: HistoryReadFunc;
28
- }
29
- export interface BindVariableOptionsVariation2 {
30
- set?: undefined;
31
- get?: undefined;
32
- timestamped_get: TimestampGetFunc;
33
- timestamped_set?: TimestampSetFunc;
34
- historyRead?: HistoryReadFunc;
35
- }
36
- export interface BindVariableOptionsVariation3 {
37
- set?: undefined;
38
- get?: undefined;
39
- timestamped_get?: undefined;
40
- timestamp_set?: undefined;
41
- refreshFunc?: (callback: CallbackT<DataValue>) => void;
42
- historyRead?: HistoryReadFunc;
43
- }
44
- export interface BindVariableOptionsVariation4 extends VariantLike {
45
- set?: undefined;
46
- get?: undefined;
47
- timestamped_get?: undefined;
48
- timestamp_set?: undefined;
49
- refreshFunc?: (callback: CallbackT<DataValue>) => void;
50
- historyRead?: HistoryReadFunc;
51
- }
52
- export declare type BindVariableOptions = BindVariableOptionsVariation1 | BindVariableOptionsVariation2 | BindVariableOptionsVariation3 | BindVariableOptionsVariation4;
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=bind_variable.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"bind_variable.js","sourceRoot":"","sources":["../source/bind_variable.ts"],"names":[],"mappings":""}
@@ -1,44 +0,0 @@
1
- import { NodeId, NodeIdLike } from "node-opcua-nodeid";
2
- import { LocalizedText, NodeClass, QualifiedName } from "node-opcua-data-model";
3
- import { BaseNode } from "./base_node";
4
- import { ModellingRuleType } from "./modelling_rule_type";
5
- import { INamespace } from "./namespace";
6
- import { UAMethod } from "./ua_method";
7
- import { UAObject } from "./ua_object";
8
- import { UAObjectType } from "./ua_object_type";
9
- import { UAReference } from "./ua_reference";
10
- import { UAVariable } from "./ua_variable";
11
- export interface CloneFilter {
12
- shouldKeep(node: BaseNode): boolean;
13
- filterFor(childInstance: UAVariable | UAObject | UAMethod): CloneFilter;
14
- }
15
- export declare const defaultCloneFilter: CloneFilter;
16
- export interface CloneExtraInfo {
17
- level: number;
18
- pad(): string;
19
- registerClonedObject(clonedObject: BaseNode, originalObject: BaseNode): void;
20
- }
21
- export declare const defaultCloneExtraInfo: CloneExtraInfo;
22
- export interface CloneOptions {
23
- namespace: INamespace;
24
- references?: UAReference[];
25
- nodeId?: string | NodeIdLike | null;
26
- nodeClass?: NodeClass;
27
- browseName?: QualifiedName;
28
- descriptions?: LocalizedText;
29
- modellingRule?: ModellingRuleType;
30
- accessLevel?: number;
31
- arrayDimensions?: number[] | null;
32
- dataType?: NodeId;
33
- historizing?: boolean;
34
- minimumSamplingInterval?: number;
35
- userAccessLevel?: number;
36
- valueRank?: number;
37
- eventNotifier?: number;
38
- symbolicName?: string;
39
- executable?: boolean;
40
- methodDeclarationId?: NodeId;
41
- componentOf?: UAObjectType | UAObject;
42
- copyAlsoModellingRules?: boolean;
43
- ignoreChildren?: boolean;
44
- }
@@ -1,19 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.defaultCloneExtraInfo = exports.defaultCloneFilter = void 0;
4
- exports.defaultCloneFilter = {
5
- shouldKeep: () => true,
6
- filterFor(node) {
7
- return this;
8
- }
9
- };
10
- exports.defaultCloneExtraInfo = {
11
- level: 0,
12
- pad() {
13
- return " ".padEnd(this.level * 2);
14
- },
15
- registerClonedObject(_clonedObject, _originalObject) {
16
- // nothing to do
17
- }
18
- };
19
- //# sourceMappingURL=clone_options.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"clone_options.js","sourceRoot":"","sources":["../source/clone_options.ts"],"names":[],"mappings":";;;AAgBa,QAAA,kBAAkB,GAAgB;IAC3C,UAAU,EAAE,GAAG,EAAE,CAAC,IAAI;IACtB,SAAS,CAAC,IAAc;QACpB,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ,CAAC;AAQW,QAAA,qBAAqB,GAAmB;IACjD,KAAK,EAAE,CAAC;IACR,GAAG;QACC,OAAO,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC;IACtC,CAAC;IACD,oBAAoB,CAAC,aAAuB,EAAE,eAAyB;QACnE,gBAAgB;IACpB,CAAC;CACJ,CAAC"}
@@ -1,2 +0,0 @@
1
- import { ByteString } from "node-opcua-basic-types";
2
- export declare type ContinuationPoint = ByteString;
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=continuation_point.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"continuation_point.js","sourceRoot":"","sources":["../source/continuation_point.ts"],"names":[],"mappings":""}
@@ -1,7 +0,0 @@
1
- export declare enum EventNotifierFlags {
2
- SubscribeToEvents = 1,
3
- Reserved = 2,
4
- HistoryRead = 4,
5
- HistoryWrite = 8,
6
- None = 0
7
- }
@@ -1,12 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EventNotifierFlags = void 0;
4
- var EventNotifierFlags;
5
- (function (EventNotifierFlags) {
6
- EventNotifierFlags[EventNotifierFlags["SubscribeToEvents"] = 1] = "SubscribeToEvents";
7
- EventNotifierFlags[EventNotifierFlags["Reserved"] = 2] = "Reserved";
8
- EventNotifierFlags[EventNotifierFlags["HistoryRead"] = 4] = "HistoryRead";
9
- EventNotifierFlags[EventNotifierFlags["HistoryWrite"] = 8] = "HistoryWrite";
10
- EventNotifierFlags[EventNotifierFlags["None"] = 0] = "None";
11
- })(EventNotifierFlags = exports.EventNotifierFlags || (exports.EventNotifierFlags = {}));
12
- //# sourceMappingURL=event_notifier_flags.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"event_notifier_flags.js","sourceRoot":"","sources":["../source/event_notifier_flags.ts"],"names":[],"mappings":";;;AAAA,IAAY,kBAMX;AAND,WAAY,kBAAkB;IAC1B,qFAA0B,CAAA;IAC1B,mEAAiB,CAAA;IACjB,yEAAoB,CAAA;IACpB,2EAAqB,CAAA;IACrB,2DAAU,CAAA;AACd,CAAC,EANW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAM7B"}
@@ -1,17 +0,0 @@
1
- import { NodeId } from "node-opcua-nodeid";
2
- import { BrowsePath, BrowsePathResult } from "node-opcua-types";
3
- import { Variant, VariantLike } from "node-opcua-variant";
4
- import { BaseNode } from "./base_node";
5
- export interface IEventData {
6
- /**
7
- * the event type node
8
- */
9
- $eventDataSource?: BaseNode;
10
- /**
11
- *
12
- */
13
- eventId: NodeId;
14
- _createValue(fullBrowsePath: string, node: BaseNode, variant: VariantLike): void;
15
- _readValue(nodeId: NodeId): Variant | null;
16
- _browse(browsePath: BrowsePath): BrowsePathResult | null;
17
- }
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=i_event_data.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"i_event_data.js","sourceRoot":"","sources":["../source/i_event_data.ts"],"names":[],"mappings":""}