node-opcua-client 2.133.0 → 2.134.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/client_base.d.ts +1 -1
- package/dist/client_session.d.ts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/private/client_base_impl.d.ts +1 -1
- package/dist/private/client_base_impl.js +9 -9
- package/dist/private/client_base_impl.js.map +1 -1
- package/dist/private/client_monitored_item_base_impl.d.ts +1 -0
- package/dist/private/client_monitored_item_base_impl.js +1 -0
- package/dist/private/client_monitored_item_base_impl.js.map +1 -1
- package/dist/private/client_session_impl.d.ts +1 -1
- package/dist/private/opcua_client_impl.js +6 -6
- package/dist/private/opcua_client_impl.js.map +1 -1
- package/dist/verify.d.ts +1 -1
- package/dist/verify.js +4 -4
- package/dist/verify.js.map +1 -1
- package/package.json +35 -35
- package/source/client_base.ts +1 -1
- package/source/client_session.ts +1 -1
- package/source/index.ts +1 -1
- package/source/private/client_base_impl.ts +1 -1
- package/source/private/client_session_impl.ts +1 -1
- package/source/private/opcua_client_impl.ts +1 -1
- package/source/verify.ts +1 -1
- package/dist/alarms_and_conditions/client_alarm.d.ts +0 -49
- package/dist/alarms_and_conditions/client_alarm.js +0 -97
- package/dist/alarms_and_conditions/client_alarm.js.map +0 -1
- package/dist/alarms_and_conditions/client_alarm_list.d.ts +0 -25
- package/dist/alarms_and_conditions/client_alarm_list.js +0 -98
- package/dist/alarms_and_conditions/client_alarm_list.js.map +0 -1
- package/dist/alarms_and_conditions/client_alarm_tools_acknowledge_all_conditions.d.ts +0 -18
- package/dist/alarms_and_conditions/client_alarm_tools_acknowledge_all_conditions.js +0 -175
- package/dist/alarms_and_conditions/client_alarm_tools_acknowledge_all_conditions.js.map +0 -1
- package/dist/alarms_and_conditions/client_alarm_tools_dump_event.d.ts +0 -9
- package/dist/alarms_and_conditions/client_alarm_tools_dump_event.js +0 -60
- package/dist/alarms_and_conditions/client_alarm_tools_dump_event.js.map +0 -1
- package/dist/alarms_and_conditions/client_alarm_tools_extractConditionFields.d.ts +0 -3
- package/dist/alarms_and_conditions/client_alarm_tools_extractConditionFields.js +0 -15
- package/dist/alarms_and_conditions/client_alarm_tools_extractConditionFields.js.map +0 -1
- package/dist/reconnection.d.ts +0 -9
- package/dist/reconnection.js +0 -453
- package/dist/reconnection.js.map +0 -1
package/dist/verify.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verify.js","sourceRoot":"","sources":["../source/verify.ts"],"names":[],"mappings":";;AAiBA,sEAsGC;AAED,sEA8CC;AApKD
|
|
1
|
+
{"version":3,"file":"verify.js","sourceRoot":"","sources":["../source/verify.ts"],"names":[],"mappings":";;AAiBA,sEAsGC;AAED,sEA8CC;AApKD,+CAK+B;AAC/B,uDAAiG;AAGjG,MAAM,OAAO,GAAG,IAAA,iCAAc,EAAC,UAAU,CAAC,CAAC;AAC3C,MAAM,QAAQ,GAAG,IAAA,gCAAa,EAAC,UAAU,CAAC,CAAC;AAC3C,MAAM,QAAQ,GAAG,IAAA,gCAAa,EAAC,UAAU,CAAC,CAAC;AAC3C,MAAM,UAAU,GAAG,IAAA,kCAAe,EAAC,UAAU,CAAC,CAAC;AAE/C,SAAgB,6BAA6B,CACzC,WAAwB,EACxB,eAAuB,EACvB,IAAyB,EACzB,cAAsB;IAEtB,MAAM,eAAe,GAAG,IAAA,wBAAkB,EAAC,WAAW,CAAC,CAAC;IACxD,MAAM,GAAG,GAAG,IAAI,IAAI,EAAE,CAAC;IAEvB,IAAI,eAAe,CAAC,cAAc,CAAC,QAAQ,CAAC,SAAS,CAAC,OAAO,EAAE,GAAG,GAAG,CAAC,OAAO,EAAE,EAAE,CAAC;QAC9E,mCAAmC;QACnC,gCAAgC;QAChC,UAAU,CACN,sDAAsD;YAClD,mBAAmB,eAAe,CAAC,cAAc,CAAC,QAAQ,CAAC,SAAS,CAAC,WAAW,EAAE,IAA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O,GAAG,MAAM,kBAAkB,CAAC,gBAAgB,CAAC,WAAW,CAAC,CAAC;IAEvE,MAAM,OAAO,GAA6B;QACtC,yBAAyB,EAAE,KAAK;QAChC,+BAA+B,EAAE,KAAK;QACtC,wBAAwB,EAAE,KAAK;KAClC,CAAC;IAEF,MAAM,MAAM,GAAG,MAAM,kBAAkB,CAAC,iBAAiB,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC;IAEhF,IAAI,MAAM,KAAK,MAAM,EAAE,CAAC;QACpB,UAAU,CAAC,wDAAwD,EAAE,MAAM,EAAE,UAAU,EAAE,YAAY,CAAC,eAAe,CAAC,CAAC;IAC3H,CAAC;IAED,6BAA6B,CAAC,WAAW,EAAE,YAAY,CAAC,eAAe,EAAE,cAAc,EAAE,cAAc,CAAC,CAAC;AAC7G,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "node-opcua-client",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.134.0",
|
|
4
4
|
"description": "pure nodejs OPCUA SDK - module client",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"clean": "npx rimraf node_modules dist *.tsbuildinfo certificates",
|
|
@@ -17,53 +17,53 @@
|
|
|
17
17
|
"@types/async": "^3.2.24",
|
|
18
18
|
"async": "^3.2.6",
|
|
19
19
|
"chalk": "4.1.2",
|
|
20
|
-
"node-opcua-alarm-condition": "2.
|
|
20
|
+
"node-opcua-alarm-condition": "2.134.0",
|
|
21
21
|
"node-opcua-assert": "2.120.0",
|
|
22
|
-
"node-opcua-basic-types": "2.
|
|
22
|
+
"node-opcua-basic-types": "2.134.0",
|
|
23
23
|
"node-opcua-buffer-utils": "2.133.0",
|
|
24
|
-
"node-opcua-certificate-manager": "2.
|
|
25
|
-
"node-opcua-client-dynamic-extension-object": "2.
|
|
26
|
-
"node-opcua-common": "2.
|
|
24
|
+
"node-opcua-certificate-manager": "2.134.0",
|
|
25
|
+
"node-opcua-client-dynamic-extension-object": "2.134.0",
|
|
26
|
+
"node-opcua-common": "2.134.0",
|
|
27
27
|
"node-opcua-constants": "2.125.0",
|
|
28
|
-
"node-opcua-crypto": "4.
|
|
29
|
-
"node-opcua-data-model": "2.
|
|
30
|
-
"node-opcua-data-value": "2.
|
|
31
|
-
"node-opcua-date-time": "2.
|
|
28
|
+
"node-opcua-crypto": "4.12.0",
|
|
29
|
+
"node-opcua-data-model": "2.134.0",
|
|
30
|
+
"node-opcua-data-value": "2.134.0",
|
|
31
|
+
"node-opcua-date-time": "2.134.0",
|
|
32
32
|
"node-opcua-debug": "2.133.0",
|
|
33
|
-
"node-opcua-extension-object": "2.
|
|
33
|
+
"node-opcua-extension-object": "2.134.0",
|
|
34
34
|
"node-opcua-hostname": "2.128.0",
|
|
35
35
|
"node-opcua-nodeid": "2.133.0",
|
|
36
36
|
"node-opcua-object-registry": "2.133.0",
|
|
37
|
-
"node-opcua-pki": "4.
|
|
38
|
-
"node-opcua-pseudo-session": "2.
|
|
39
|
-
"node-opcua-schemas": "2.
|
|
40
|
-
"node-opcua-secure-channel": "2.
|
|
41
|
-
"node-opcua-service-browse": "2.
|
|
42
|
-
"node-opcua-service-call": "2.
|
|
43
|
-
"node-opcua-service-discovery": "2.
|
|
44
|
-
"node-opcua-service-endpoints": "2.
|
|
45
|
-
"node-opcua-service-filter": "2.
|
|
46
|
-
"node-opcua-service-history": "2.
|
|
47
|
-
"node-opcua-service-query": "2.
|
|
48
|
-
"node-opcua-service-read": "2.
|
|
49
|
-
"node-opcua-service-register-node": "2.
|
|
50
|
-
"node-opcua-service-secure-channel": "2.
|
|
51
|
-
"node-opcua-service-session": "2.
|
|
52
|
-
"node-opcua-service-subscription": "2.
|
|
53
|
-
"node-opcua-service-translate-browse-path": "2.
|
|
54
|
-
"node-opcua-service-write": "2.
|
|
37
|
+
"node-opcua-pki": "4.16.0",
|
|
38
|
+
"node-opcua-pseudo-session": "2.134.0",
|
|
39
|
+
"node-opcua-schemas": "2.134.0",
|
|
40
|
+
"node-opcua-secure-channel": "2.134.0",
|
|
41
|
+
"node-opcua-service-browse": "2.134.0",
|
|
42
|
+
"node-opcua-service-call": "2.134.0",
|
|
43
|
+
"node-opcua-service-discovery": "2.134.0",
|
|
44
|
+
"node-opcua-service-endpoints": "2.134.0",
|
|
45
|
+
"node-opcua-service-filter": "2.134.0",
|
|
46
|
+
"node-opcua-service-history": "2.134.0",
|
|
47
|
+
"node-opcua-service-query": "2.134.0",
|
|
48
|
+
"node-opcua-service-read": "2.134.0",
|
|
49
|
+
"node-opcua-service-register-node": "2.134.0",
|
|
50
|
+
"node-opcua-service-secure-channel": "2.134.0",
|
|
51
|
+
"node-opcua-service-session": "2.134.0",
|
|
52
|
+
"node-opcua-service-subscription": "2.134.0",
|
|
53
|
+
"node-opcua-service-translate-browse-path": "2.134.0",
|
|
54
|
+
"node-opcua-service-write": "2.134.0",
|
|
55
55
|
"node-opcua-status-code": "2.133.0",
|
|
56
|
-
"node-opcua-types": "2.
|
|
56
|
+
"node-opcua-types": "2.134.0",
|
|
57
57
|
"node-opcua-utils": "2.133.0",
|
|
58
|
-
"node-opcua-variant": "2.
|
|
58
|
+
"node-opcua-variant": "2.134.0",
|
|
59
59
|
"thenify": "^3.3.1"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
|
-
"@types/underscore": "^1.
|
|
62
|
+
"@types/underscore": "^1.13.0",
|
|
63
63
|
"dequeue": "^1.0.5",
|
|
64
|
-
"node-opcua-address-space": "2.
|
|
64
|
+
"node-opcua-address-space": "2.134.0",
|
|
65
65
|
"node-opcua-binary-stream": "2.133.0",
|
|
66
|
-
"node-opcua-factory": "2.
|
|
66
|
+
"node-opcua-factory": "2.134.0",
|
|
67
67
|
"node-opcua-leak-detector": "2.133.0",
|
|
68
68
|
"node-opcua-nodesets": "2.121.0",
|
|
69
69
|
"underscore": "^1.13.7"
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"internet of things"
|
|
89
89
|
],
|
|
90
90
|
"homepage": "http://node-opcua.github.io/",
|
|
91
|
-
"gitHead": "
|
|
91
|
+
"gitHead": "ccb34926a3c195f6a7e66fca58a2f101858e78be",
|
|
92
92
|
"files": [
|
|
93
93
|
"dist",
|
|
94
94
|
"source"
|
package/source/client_base.ts
CHANGED
|
@@ -6,7 +6,7 @@ import { EventEmitter } from "events";
|
|
|
6
6
|
import { LocaleId } from "node-opcua-basic-types";
|
|
7
7
|
import { OPCUACertificateManager } from "node-opcua-certificate-manager";
|
|
8
8
|
import { OPCUASecureObject } from "node-opcua-common";
|
|
9
|
-
import { Certificate } from "node-opcua-crypto";
|
|
9
|
+
import { Certificate } from "node-opcua-crypto/web";
|
|
10
10
|
import { ObjectRegistry } from "node-opcua-object-registry";
|
|
11
11
|
import { ClientSecureChannelLayer, ConnectionStrategy, ConnectionStrategyOptions, SecurityPolicy } from "node-opcua-secure-channel";
|
|
12
12
|
import { FindServersOnNetworkRequestOptions, FindServersRequestOptions, ServerOnNetwork } from "node-opcua-service-discovery";
|
package/source/client_session.ts
CHANGED
|
@@ -6,7 +6,7 @@ import { EventEmitter } from "events";
|
|
|
6
6
|
|
|
7
7
|
import { DateTime, UInt8 } from "node-opcua-basic-types";
|
|
8
8
|
import { ServerState } from "node-opcua-common";
|
|
9
|
-
import { Certificate } from "node-opcua-crypto";
|
|
9
|
+
import { Certificate } from "node-opcua-crypto/web";
|
|
10
10
|
import { LocalizedTextLike } from "node-opcua-data-model";
|
|
11
11
|
import { DataValue, TimestampsToReturn } from "node-opcua-data-value";
|
|
12
12
|
import { NodeId, NodeIdLike } from "node-opcua-nodeid";
|
package/source/index.ts
CHANGED
|
@@ -31,7 +31,7 @@ export { SecurityPolicy, ClientSecureChannelLayer, ConnectionStrategyOptions } f
|
|
|
31
31
|
import * as utils1 from "node-opcua-utils";
|
|
32
32
|
export const utils = utils1;
|
|
33
33
|
|
|
34
|
-
import * as crypto_util1 from "node-opcua-crypto";
|
|
34
|
+
import * as crypto_util1 from "node-opcua-crypto/web";
|
|
35
35
|
export const crypto_utils = crypto_util1;
|
|
36
36
|
|
|
37
37
|
export { hexDump, LogLevel, setLogLevel, setDebugLogger, setWarningLogger, setErrorLogger } from "node-opcua-debug";
|
|
@@ -9,7 +9,7 @@ import chalk from "chalk";
|
|
|
9
9
|
import { withLock } from "@ster5/global-mutex";
|
|
10
10
|
import { assert } from "node-opcua-assert";
|
|
11
11
|
import { IOPCUASecureObjectOptions, OPCUASecureObject } from "node-opcua-common";
|
|
12
|
-
import { Certificate, makeSHA1Thumbprint, Nonce, split_der } from "node-opcua-crypto";
|
|
12
|
+
import { Certificate, makeSHA1Thumbprint, Nonce, split_der } from "node-opcua-crypto/web";
|
|
13
13
|
import { installPeriodicClockAdjustment, periodicClockAdjustment, uninstallPeriodicClockAdjustment } from "node-opcua-date-time";
|
|
14
14
|
import { checkDebugFlag, make_debugLog, make_errorLog, make_warningLog } from "node-opcua-debug";
|
|
15
15
|
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
promoteOpaqueStructure,
|
|
16
16
|
PseudoDataValue
|
|
17
17
|
} from "node-opcua-client-dynamic-extension-object";
|
|
18
|
-
import { Certificate, Nonce } from "node-opcua-crypto";
|
|
18
|
+
import { Certificate, Nonce } from "node-opcua-crypto/web";
|
|
19
19
|
import { BrowseDirection, LocalizedTextLike } from "node-opcua-data-model";
|
|
20
20
|
import { DataValue } from "node-opcua-data-value";
|
|
21
21
|
import { checkDebugFlag, make_debugLog, make_errorLog, make_warningLog } from "node-opcua-debug";
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
PrivateKey,
|
|
16
16
|
Nonce,
|
|
17
17
|
toPem
|
|
18
|
-
} from "node-opcua-crypto";
|
|
18
|
+
} from "node-opcua-crypto/web";
|
|
19
19
|
|
|
20
20
|
import { LocalizedText } from "node-opcua-data-model";
|
|
21
21
|
import { checkDebugFlag, make_debugLog, make_errorLog, make_warningLog } from "node-opcua-debug";
|
package/source/verify.ts
CHANGED
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
exploreCertificate,
|
|
7
7
|
explorePrivateKey,
|
|
8
8
|
publicKeyAndPrivateKeyMatches
|
|
9
|
-
} from "node-opcua-crypto";
|
|
9
|
+
} from "node-opcua-crypto/web";
|
|
10
10
|
import { checkDebugFlag, make_debugLog, make_errorLog, make_warningLog } from "node-opcua-debug";
|
|
11
11
|
import { VerifyCertificateOptions } from "node-opcua-pki";
|
|
12
12
|
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
/// <reference types="node" />
|
|
3
|
-
import { EventEmitter } from "events";
|
|
4
|
-
import { NodeId } from "node-opcua-nodeid";
|
|
5
|
-
import { StatusCode } from "node-opcua-status-code";
|
|
6
|
-
import { Variant } from "node-opcua-variant";
|
|
7
|
-
import { ClientSession } from "../client_session";
|
|
8
|
-
export interface TVariant<T> extends Variant {
|
|
9
|
-
value: T;
|
|
10
|
-
}
|
|
11
|
-
export interface TTwoStateStatus extends TVariant<string> {
|
|
12
|
-
id: TVariant<boolean>;
|
|
13
|
-
}
|
|
14
|
-
export interface EventStuff {
|
|
15
|
-
conditionId: TVariant<NodeId>;
|
|
16
|
-
eventType: TVariant<NodeId>;
|
|
17
|
-
eventId: TVariant<Buffer>;
|
|
18
|
-
retain: TVariant<boolean>;
|
|
19
|
-
activeState: TTwoStateStatus;
|
|
20
|
-
ackedState: TTwoStateStatus;
|
|
21
|
-
confirmedState: TTwoStateStatus;
|
|
22
|
-
conditionName?: TVariant<string>;
|
|
23
|
-
}
|
|
24
|
-
export interface ClientAlarm {
|
|
25
|
-
conditionId: NodeId;
|
|
26
|
-
eventType: NodeId;
|
|
27
|
-
fields: EventStuff;
|
|
28
|
-
on(eventName: "changed", eventHandler: () => void): this;
|
|
29
|
-
acknowledge(session: ClientSession, comment: string): Promise<StatusCode>;
|
|
30
|
-
getField(fieldName: string): Variant | null;
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* describes a OPCUA Alarm as seen in the client side
|
|
34
|
-
*/
|
|
35
|
-
export declare class ClientAlarm extends EventEmitter {
|
|
36
|
-
conditionId: NodeId;
|
|
37
|
-
eventType: NodeId;
|
|
38
|
-
eventId: Buffer;
|
|
39
|
-
fields: EventStuff;
|
|
40
|
-
constructor(eventFields: EventStuff);
|
|
41
|
-
confirm(session: ClientSession, comment: string): Promise<StatusCode>;
|
|
42
|
-
update(eventFields: EventStuff): void;
|
|
43
|
-
getRetain(): boolean;
|
|
44
|
-
toString(): string;
|
|
45
|
-
}
|
|
46
|
-
/**
|
|
47
|
-
* @private
|
|
48
|
-
*/
|
|
49
|
-
export declare function fieldsToJson(fields: string[], eventFields: Variant[], flat?: boolean): EventStuff;
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.fieldsToJson = exports.ClientAlarm = void 0;
|
|
4
|
-
const events_1 = require("events");
|
|
5
|
-
const node_opcua_assert_1 = require("node-opcua-assert");
|
|
6
|
-
const node_opcua_debug_1 = require("node-opcua-debug");
|
|
7
|
-
const node_opcua_nodeid_1 = require("node-opcua-nodeid");
|
|
8
|
-
const node_opcua_utils_1 = require("node-opcua-utils");
|
|
9
|
-
const node_opcua_variant_1 = require("node-opcua-variant");
|
|
10
|
-
const warningLog = (0, node_opcua_debug_1.make_warningLog)(__filename);
|
|
11
|
-
/**
|
|
12
|
-
* describes a OPCUA Alarm as seen in the client side
|
|
13
|
-
*/
|
|
14
|
-
class ClientAlarm extends events_1.EventEmitter {
|
|
15
|
-
constructor(eventFields) {
|
|
16
|
-
super();
|
|
17
|
-
this.conditionId = (0, node_opcua_nodeid_1.resolveNodeId)(eventFields.conditionId.value);
|
|
18
|
-
this.eventType = (0, node_opcua_nodeid_1.resolveNodeId)(eventFields.eventType.value);
|
|
19
|
-
this.eventId = eventFields.eventId.value;
|
|
20
|
-
this.fields = eventFields;
|
|
21
|
-
this.update(eventFields);
|
|
22
|
-
}
|
|
23
|
-
async acknowledge(session, comment) {
|
|
24
|
-
return await session.acknowledgeCondition(this.conditionId, this.eventId, comment);
|
|
25
|
-
}
|
|
26
|
-
async confirm(session, comment) {
|
|
27
|
-
return await session.confirmCondition(this.conditionId, this.eventId, comment);
|
|
28
|
-
}
|
|
29
|
-
update(eventFields) {
|
|
30
|
-
(0, node_opcua_assert_1.assert)(this.conditionId.toString() === (0, node_opcua_nodeid_1.resolveNodeId)(eventFields.conditionId.value).toString());
|
|
31
|
-
(0, node_opcua_assert_1.assert)(this.eventType.toString() === (0, node_opcua_nodeid_1.resolveNodeId)(eventFields.eventType.value).toString());
|
|
32
|
-
this.eventId = eventFields.eventId.value;
|
|
33
|
-
this.fields = eventFields;
|
|
34
|
-
}
|
|
35
|
-
getRetain() {
|
|
36
|
-
return this.fields.retain.value;
|
|
37
|
-
}
|
|
38
|
-
toString() {
|
|
39
|
-
return (this.constructor.name +
|
|
40
|
-
": " +
|
|
41
|
-
this.conditionId.toString() +
|
|
42
|
-
" " +
|
|
43
|
-
this.eventType.toString() +
|
|
44
|
-
" " +
|
|
45
|
-
Object.entries(this.fields)
|
|
46
|
-
.filter(([key, value]) => value.dataType !== node_opcua_variant_1.DataType.Null)
|
|
47
|
-
.map(([key, value]) => key.padEnd(30) + "=" + value.toString())
|
|
48
|
-
.join("\n") +
|
|
49
|
-
"\n\n");
|
|
50
|
-
}
|
|
51
|
-
getField(fieldName) {
|
|
52
|
-
return this.fields[fieldName] || null;
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
exports.ClientAlarm = ClientAlarm;
|
|
56
|
-
/**
|
|
57
|
-
* @private
|
|
58
|
-
*/
|
|
59
|
-
function fieldsToJson(fields, eventFields, flat) {
|
|
60
|
-
function setProperty(_data, fieldName, value) {
|
|
61
|
-
let name;
|
|
62
|
-
if (!fieldName || value === null) {
|
|
63
|
-
return;
|
|
64
|
-
}
|
|
65
|
-
if (!flat) {
|
|
66
|
-
const f = fieldName.split(".");
|
|
67
|
-
if (f.length === 1) {
|
|
68
|
-
fieldName = (0, node_opcua_utils_1.lowerFirstLetter)(fieldName);
|
|
69
|
-
_data[fieldName] = value;
|
|
70
|
-
}
|
|
71
|
-
else {
|
|
72
|
-
for (let i = 0; i < f.length - 1; i++) {
|
|
73
|
-
name = (0, node_opcua_utils_1.lowerFirstLetter)(f[i]);
|
|
74
|
-
_data[name] = _data[name] || {};
|
|
75
|
-
_data = _data[name];
|
|
76
|
-
}
|
|
77
|
-
name = (0, node_opcua_utils_1.lowerFirstLetter)(f[f.length - 1]);
|
|
78
|
-
_data[name] = value;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
else {
|
|
82
|
-
const name = fieldName.split(".").map(node_opcua_utils_1.lowerFirstLetter).join(".");
|
|
83
|
-
_data[name] = value;
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
if (fields.length > eventFields.length) {
|
|
87
|
-
warningLog("warning fields.length !== eventFields.length", fields.length, eventFields.length);
|
|
88
|
-
}
|
|
89
|
-
const data = {};
|
|
90
|
-
for (let index = 0; index < fields.length; index++) {
|
|
91
|
-
const variant = eventFields[index];
|
|
92
|
-
setProperty(data, fields[index], variant);
|
|
93
|
-
}
|
|
94
|
-
return data;
|
|
95
|
-
}
|
|
96
|
-
exports.fieldsToJson = fieldsToJson;
|
|
97
|
-
//# sourceMappingURL=client_alarm.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"client_alarm.js","sourceRoot":"","sources":["../../source/alarms_and_conditions/client_alarm.ts"],"names":[],"mappings":";;;AAAA,mCAAsC;AACtC,yDAA2C;AAC3C,uDAAmD;AACnD,yDAA0D;AAE1D,uDAAoD;AACpD,2DAAuD;AAGvD,MAAM,UAAU,GAAG,IAAA,kCAAe,EAAC,UAAU,CAAC,CAAC;AA4B/C;;GAEG;AACH,MAAa,WAAY,SAAQ,qBAAY;IAMzC,YAAmB,WAAuB;QACtC,KAAK,EA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{ ClientAlarm, EventStuff } from "./client_alarm";
|
|
4
|
-
export interface ClientAlarmList {
|
|
5
|
-
on(eventName: "alarmChanged", handler: (alarm: ClientAlarm) => void): this;
|
|
6
|
-
on(eventName: "alarmDeleted", handler: (alarm: ClientAlarm) => void): this;
|
|
7
|
-
on(eventName: "newAlarm", handler: (alarm: ClientAlarm) => void): this;
|
|
8
|
-
emit(eventName: "alarmChanged", alarm: ClientAlarm): boolean;
|
|
9
|
-
emit(eventName: "newAlarm", alarm: ClientAlarm): boolean;
|
|
10
|
-
emit(eventName: "alarmDeleted", alarm: ClientAlarm): boolean;
|
|
11
|
-
}
|
|
12
|
-
export declare class ClientAlarmList extends EventEmitter implements Iterable<ClientAlarm> {
|
|
13
|
-
private _map;
|
|
14
|
-
constructor();
|
|
15
|
-
[Symbol.iterator](): Iterator<ClientAlarm>;
|
|
16
|
-
alarms(): ClientAlarm[];
|
|
17
|
-
update(eventField: EventStuff): void;
|
|
18
|
-
removeAlarm(eventField: EventStuff): void;
|
|
19
|
-
get length(): number;
|
|
20
|
-
purgeUnusedAlarms(): void;
|
|
21
|
-
private _removeAlarm;
|
|
22
|
-
private makeKey;
|
|
23
|
-
private findAlarm;
|
|
24
|
-
private deleteAlarm;
|
|
25
|
-
}
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ClientAlarmList = void 0;
|
|
4
|
-
const events_1 = require("events");
|
|
5
|
-
const node_opcua_assert_1 = require("node-opcua-assert");
|
|
6
|
-
const client_alarm_1 = require("./client_alarm");
|
|
7
|
-
// maintain a set of alarm list for a client
|
|
8
|
-
class ClientAlarmList extends events_1.EventEmitter {
|
|
9
|
-
constructor() {
|
|
10
|
-
super();
|
|
11
|
-
this._map = {};
|
|
12
|
-
}
|
|
13
|
-
[Symbol.iterator]() {
|
|
14
|
-
let pointer = 0;
|
|
15
|
-
const components = Object.values(this._map);
|
|
16
|
-
return {
|
|
17
|
-
next() {
|
|
18
|
-
if (pointer >= components.length) {
|
|
19
|
-
return {
|
|
20
|
-
done: true,
|
|
21
|
-
value: components[pointer++]
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
else {
|
|
25
|
-
return {
|
|
26
|
-
done: false,
|
|
27
|
-
value: components[pointer++]
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
}
|
|
33
|
-
alarms() {
|
|
34
|
-
return Object.values(this._map);
|
|
35
|
-
}
|
|
36
|
-
update(eventField) {
|
|
37
|
-
// Spec says:
|
|
38
|
-
// Clients shall check for multiple Event Notifications for a ConditionBranch to avoid
|
|
39
|
-
// overwriting a new state delivered together with an older state from the Refresh
|
|
40
|
-
// process.
|
|
41
|
-
const { conditionId, eventType } = eventField;
|
|
42
|
-
(0, node_opcua_assert_1.assert)(conditionId, "must have a valid conditionId ( verify that event is a acknodweldgeable type");
|
|
43
|
-
const alarm = this.findAlarm(conditionId.value, eventType.value);
|
|
44
|
-
if (!alarm) {
|
|
45
|
-
const key = this.makeKey(conditionId.value, eventType.value);
|
|
46
|
-
const newAlarm = new client_alarm_1.ClientAlarm(eventField);
|
|
47
|
-
this._map[key] = newAlarm;
|
|
48
|
-
this.emit("newAlarm", newAlarm);
|
|
49
|
-
this.emit("alarmChanged", newAlarm);
|
|
50
|
-
}
|
|
51
|
-
else {
|
|
52
|
-
alarm.update(eventField);
|
|
53
|
-
this.emit("alarmChanged", alarm);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
removeAlarm(eventField) {
|
|
57
|
-
const { conditionId, eventType } = eventField;
|
|
58
|
-
const alarm = this.findAlarm(conditionId.value, eventType.value);
|
|
59
|
-
if (alarm) {
|
|
60
|
-
alarm.update(eventField);
|
|
61
|
-
this._removeAlarm(alarm);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
get length() {
|
|
65
|
-
return Object.keys(this._map).length;
|
|
66
|
-
}
|
|
67
|
-
purgeUnusedAlarms() {
|
|
68
|
-
const alarms = this.alarms();
|
|
69
|
-
for (const alarm of alarms) {
|
|
70
|
-
if (!alarm.getRetain()) {
|
|
71
|
-
this._removeAlarm(alarm);
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
_removeAlarm(alarm) {
|
|
76
|
-
this.emit("alarmDeleted", alarm);
|
|
77
|
-
this.deleteAlarm(alarm.conditionId, alarm.eventType);
|
|
78
|
-
}
|
|
79
|
-
makeKey(conditionId, eventType) {
|
|
80
|
-
return conditionId.toString() + "|" + eventType.toString();
|
|
81
|
-
}
|
|
82
|
-
findAlarm(conditionId, eventType) {
|
|
83
|
-
const key = this.makeKey(conditionId, eventType);
|
|
84
|
-
const _c = this._map[key];
|
|
85
|
-
return _c || null;
|
|
86
|
-
}
|
|
87
|
-
deleteAlarm(conditionId, eventType) {
|
|
88
|
-
const key = this.makeKey(conditionId, eventType);
|
|
89
|
-
const _c = this._map[key];
|
|
90
|
-
if (_c) {
|
|
91
|
-
delete this._map[key];
|
|
92
|
-
return true;
|
|
93
|
-
}
|
|
94
|
-
return false;
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
exports.ClientAlarmList = ClientAlarmList;
|
|
98
|
-
//# sourceMappingURL=client_alarm_list.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"client_alarm_list.js","sourceRoot":"","sources":["../../source/alarms_and_conditions/client_alarm_list.ts"],"names":[],"mappings":";;;AAAA,mCAAsC;AACtC,yDAA2C;AAG3C,iDAAyD;AAWzD,4CAA4C;AAC5C,MAAa,eAAgB,SAAQ,qBAAY;IAG7C;QACI,KAAK,EAAE,CAAC;QAHJ,SAAI,GAAmC,EAAE,CAAC;IAIlD,CAAC;IAEM,CAAC,MAAM,CAAC,QAAQ,CAAC;QACpB,IAAI,OAAO,GAAG,CAAC,CAAC;QAChB,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,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ACtB,CAAC;IACO,WAAW,CAAC,WAAmB,EAAE,SAAiB;QACtD,MAAM,GAAG,GAAG,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;QACjD,MAAM,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAC1B,IAAI,EAAE,EAAE;YACJ,OAAO,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACtB,OAAO,IAAI,CAAC;SACf;QACD,OAAO,KAAK,CAAC;IACjB,CAAC;CACJ;AA/FD,0CA+FC"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { StatusCode } from "node-opcua-status-code";
|
|
2
|
-
import { ClientSession } from "../client_session";
|
|
3
|
-
import { EventStuff } from "./client_alarm";
|
|
4
|
-
/**
|
|
5
|
-
*
|
|
6
|
-
* @param session
|
|
7
|
-
* @param eventStuff
|
|
8
|
-
* @param comment
|
|
9
|
-
*/
|
|
10
|
-
export declare function acknowledgeCondition(session: ClientSession, eventStuff: EventStuff, comment: string): Promise<StatusCode>;
|
|
11
|
-
export declare function confirmCondition(session: ClientSession, eventStuff: EventStuff, comment: string): Promise<StatusCode>;
|
|
12
|
-
/**
|
|
13
|
-
* Enumerate all events
|
|
14
|
-
* @param session
|
|
15
|
-
*/
|
|
16
|
-
export declare function findActiveConditions(session: ClientSession): Promise<EventStuff[]>;
|
|
17
|
-
export declare function acknowledgeAllConditions(session: ClientSession, message: string): Promise<void>;
|
|
18
|
-
export declare function confirmAllConditions(session: ClientSession, message: string): Promise<void>;
|