zwave-js 15.23.3 → 15.23.5

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.
@@ -9,7 +9,7 @@ export { VirtualEndpoint } from "./lib/node/VirtualEndpoint.js";
9
9
  export { VirtualNode } from "./lib/node/VirtualNode.js";
10
10
  export type { VirtualValueID } from "./lib/node/VirtualNode.js";
11
11
  export * from "./lib/node/_Types.js";
12
- export { AccessControlAPI, AssignCredentialStatus, SetCredentialStatus, SetUserStatus, } from "./lib/node/feature-apis/AccessControl.js";
12
+ export { AccessControlAPI, AssignCredentialResult, SetCredentialResult, SetUserResult, } from "./lib/node/feature-apis/AccessControl.js";
13
13
  export type { CredentialCapabilities, CredentialData, SetUserOptions, UserCapabilities, UserData, } from "./lib/node/feature-apis/AccessControl.js";
14
14
  export { FeatureAPI } from "./lib/node/feature-apis/FeatureAPI.js";
15
15
  //# sourceMappingURL=Node.d.ts.map
package/build/cjs/Node.js CHANGED
@@ -20,7 +20,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
20
20
  var Node_exports = {};
21
21
  __export(Node_exports, {
22
22
  AccessControlAPI: () => import_AccessControl.AccessControlAPI,
23
- AssignCredentialStatus: () => import_AccessControl.AssignCredentialStatus,
23
+ AssignCredentialResult: () => import_AccessControl.AssignCredentialResult,
24
24
  DeviceClass: () => import_DeviceClass.DeviceClass,
25
25
  Endpoint: () => import_Endpoint.Endpoint,
26
26
  FeatureAPI: () => import_FeatureAPI.FeatureAPI,
@@ -30,8 +30,8 @@ __export(Node_exports, {
30
30
  NodeType: () => import_core.NodeType,
31
31
  ProtocolDataRate: () => import_core.ProtocolDataRate,
32
32
  ProtocolVersion: () => import_core.ProtocolVersion,
33
- SetCredentialStatus: () => import_AccessControl.SetCredentialStatus,
34
- SetUserStatus: () => import_AccessControl.SetUserStatus,
33
+ SetCredentialResult: () => import_AccessControl.SetCredentialResult,
34
+ SetUserResult: () => import_AccessControl.SetUserResult,
35
35
  VirtualEndpoint: () => import_VirtualEndpoint.VirtualEndpoint,
36
36
  VirtualNode: () => import_VirtualNode.VirtualNode,
37
37
  ZWaveNode: () => import_Node.ZWaveNode
@@ -49,7 +49,7 @@ var import_FeatureAPI = require("./lib/node/feature-apis/FeatureAPI.js");
49
49
  // Annotate the CommonJS export names for ESM import in node:
50
50
  0 && (module.exports = {
51
51
  AccessControlAPI,
52
- AssignCredentialStatus,
52
+ AssignCredentialResult,
53
53
  DeviceClass,
54
54
  Endpoint,
55
55
  FeatureAPI,
@@ -59,8 +59,8 @@ var import_FeatureAPI = require("./lib/node/feature-apis/FeatureAPI.js");
59
59
  NodeType,
60
60
  ProtocolDataRate,
61
61
  ProtocolVersion,
62
- SetCredentialStatus,
63
- SetUserStatus,
62
+ SetCredentialResult,
63
+ SetUserResult,
64
64
  VirtualEndpoint,
65
65
  VirtualNode,
66
66
  ZWaveNode,
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Node.ts"],
4
- "sourcesContent": ["export {\n\tNODE_ID_BROADCAST,\n\tNODE_ID_BROADCAST_LR,\n\tNODE_ID_MAX,\n\tNodeType,\n\tProtocolDataRate,\n\tProtocolVersion,\n} from \"@zwave-js/core\";\nexport type { DataRate, FLiRS } from \"@zwave-js/core\";\nexport { DeviceClass } from \"./lib/node/DeviceClass.js\";\nexport type { NodeDump } from \"./lib/node/Dump.js\";\nexport { Endpoint } from \"./lib/node/Endpoint.js\";\nexport { ZWaveNode } from \"./lib/node/Node.js\";\nexport type {\n\tNodeStatistics,\n\tRouteStatistics,\n} from \"./lib/node/NodeStatistics.js\";\nexport { VirtualEndpoint } from \"./lib/node/VirtualEndpoint.js\";\nexport { VirtualNode } from \"./lib/node/VirtualNode.js\";\nexport type { VirtualValueID } from \"./lib/node/VirtualNode.js\";\nexport * from \"./lib/node/_Types.js\";\nexport {\n\tAccessControlAPI,\n\tAssignCredentialStatus,\n\tSetCredentialStatus,\n\tSetUserStatus,\n} from \"./lib/node/feature-apis/AccessControl.js\";\nexport type {\n\tCredentialCapabilities,\n\tCredentialData,\n\tSetUserOptions,\n\tUserCapabilities,\n\tUserData,\n} from \"./lib/node/feature-apis/AccessControl.js\";\nexport { FeatureAPI } from \"./lib/node/feature-apis/FeatureAPI.js\";\n"],
4
+ "sourcesContent": ["export {\n\tNODE_ID_BROADCAST,\n\tNODE_ID_BROADCAST_LR,\n\tNODE_ID_MAX,\n\tNodeType,\n\tProtocolDataRate,\n\tProtocolVersion,\n} from \"@zwave-js/core\";\nexport type { DataRate, FLiRS } from \"@zwave-js/core\";\nexport { DeviceClass } from \"./lib/node/DeviceClass.js\";\nexport type { NodeDump } from \"./lib/node/Dump.js\";\nexport { Endpoint } from \"./lib/node/Endpoint.js\";\nexport { ZWaveNode } from \"./lib/node/Node.js\";\nexport type {\n\tNodeStatistics,\n\tRouteStatistics,\n} from \"./lib/node/NodeStatistics.js\";\nexport { VirtualEndpoint } from \"./lib/node/VirtualEndpoint.js\";\nexport { VirtualNode } from \"./lib/node/VirtualNode.js\";\nexport type { VirtualValueID } from \"./lib/node/VirtualNode.js\";\nexport * from \"./lib/node/_Types.js\";\nexport {\n\tAccessControlAPI,\n\tAssignCredentialResult,\n\tSetCredentialResult,\n\tSetUserResult,\n} from \"./lib/node/feature-apis/AccessControl.js\";\nexport type {\n\tCredentialCapabilities,\n\tCredentialData,\n\tSetUserOptions,\n\tUserCapabilities,\n\tUserData,\n} from \"./lib/node/feature-apis/AccessControl.js\";\nexport { FeatureAPI } from \"./lib/node/feature-apis/FeatureAPI.js\";\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;;;;;;;AAAA,kBAOO;AAEP,yBAA4B;AAE5B,sBAAyB;AACzB,kBAA0B;AAK1B,6BAAgC;AAChC,yBAA4B;AAE5B,yBAAc,iCApBd;AAqBA,2BAKO;AAQP,wBAA2B;",
6
6
  "names": []
7
7
  }
@@ -1,3 +1,3 @@
1
- export declare const PACKAGE_VERSION = "15.23.3";
1
+ export declare const PACKAGE_VERSION = "15.23.5";
2
2
  export declare const PACKAGE_NAME = "zwave-js";
3
3
  //# sourceMappingURL=_version.d.ts.map
@@ -22,7 +22,7 @@ __export(version_exports, {
22
22
  PACKAGE_VERSION: () => PACKAGE_VERSION
23
23
  });
24
24
  module.exports = __toCommonJS(version_exports);
25
- const PACKAGE_VERSION = "15.23.3";
25
+ const PACKAGE_VERSION = "15.23.5";
26
26
  const PACKAGE_NAME = "zwave-js";
27
27
  // Annotate the CommonJS export names for ESM import in node:
28
28
  0 && (module.exports = {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/lib/_version.ts"],
4
- "sourcesContent": ["// This file is auto-generated by the codegen maintenance script\nexport const PACKAGE_VERSION = \"15.23.3\";\nexport const PACKAGE_NAME = \"zwave-js\";\n"],
4
+ "sourcesContent": ["// This file is auto-generated by the codegen maintenance script\nexport const PACKAGE_VERSION = \"15.23.5\";\nexport const PACKAGE_NAME = \"zwave-js\";\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;AAAA;;;;;;AACO,MAAM,kBAAkB;AACxB,MAAM,eAAe;",
6
6
  "names": []
7
7
  }
@@ -38,15 +38,15 @@ export interface SetUserOptions {
38
38
  credentialRule?: UserCredentialRule;
39
39
  expiringTimeoutMinutes?: number;
40
40
  }
41
- /** Result status of a setUser / deleteUser / deleteAllUsers call */
42
- export declare enum SetUserStatus {
41
+ /** Result of a setUser / deleteUser / deleteAllUsers call */
42
+ export declare enum SetUserResult {
43
43
  OK = 0,
44
44
  Error_AddRejectedLocationOccupied = 1,
45
45
  Error_ModifyRejectedLocationEmpty = 2,
46
46
  Error_Unknown = 255
47
47
  }
48
- /** Result status of a setCredential / deleteCredential call */
49
- export declare enum SetCredentialStatus {
48
+ /** Result of a setCredential / deleteCredential call */
49
+ export declare enum SetCredentialResult {
50
50
  OK = 0,
51
51
  Error_AddRejectedLocationOccupied = 1,
52
52
  Error_ModifyRejectedLocationEmpty = 2,
@@ -56,8 +56,8 @@ export declare enum SetCredentialStatus {
56
56
  Error_WrongUserUniqueIdentifier = 6,
57
57
  Error_Unknown = 255
58
58
  }
59
- /** Result status of an assignCredential call */
60
- export declare enum AssignCredentialStatus {
59
+ /** Result of an assignCredential call */
60
+ export declare enum AssignCredentialResult {
61
61
  OK = 0,
62
62
  /** Spec statuses 0x01 / 0x02 / 0x03 — credential type / slot invalid or empty */
63
63
  Error_InvalidCredential = 1,
@@ -102,17 +102,17 @@ export declare class AccessControlAPI extends FeatureAPI {
102
102
  * Creates or updates the user with the given ID.
103
103
  * This communicates with the node.
104
104
  */
105
- setUser(userId: number, options: SetUserOptions): Promise<SetUserStatus>;
105
+ setUser(userId: number, options: SetUserOptions): Promise<SetUserResult>;
106
106
  /**
107
107
  * Deletes the user with the given ID and all of their credentials.
108
108
  * This communicates with the node.
109
109
  */
110
- deleteUser(userId: number): Promise<SetUserStatus>;
110
+ deleteUser(userId: number): Promise<SetUserResult>;
111
111
  /**
112
112
  * Deletes all users and their credentials.
113
113
  * This communicates with the node.
114
114
  */
115
- deleteAllUsers(): Promise<SetUserStatus>;
115
+ deleteAllUsers(): Promise<SetUserResult>;
116
116
  /**
117
117
  * Returns the data for a specific credential type and slot.
118
118
  * This communicates with the node to retrieve fresh information.
@@ -157,12 +157,12 @@ export declare class AccessControlAPI extends FeatureAPI {
157
157
  * Creates or updates a credential for the given user.
158
158
  * This communicates with the node.
159
159
  */
160
- setCredential(userId: number, type: UserCredentialType, slot: number, data: string | Uint8Array): Promise<SetCredentialStatus>;
160
+ setCredential(userId: number, type: UserCredentialType, slot: number, data: string | Uint8Array): Promise<SetCredentialResult>;
161
161
  /**
162
162
  * Deletes the given credential.
163
163
  * This communicates with the node.
164
164
  */
165
- deleteCredential(userId: number, type: UserCredentialType, slot: number): Promise<SetCredentialStatus>;
165
+ deleteCredential(userId: number, type: UserCredentialType, slot: number): Promise<SetCredentialResult>;
166
166
  /**
167
167
  * Assigns an existing credential to a different user, without re-enrolling
168
168
  * it. Useful for credentials that were added locally on the device (e.g. a
@@ -175,7 +175,7 @@ export declare class AccessControlAPI extends FeatureAPI {
175
175
  *
176
176
  * This communicates with the node.
177
177
  */
178
- assignCredential(type: UserCredentialType, slot: number, destinationUserId: number): Promise<AssignCredentialStatus>;
178
+ assignCredential(type: UserCredentialType, slot: number, destinationUserId: number): Promise<AssignCredentialResult>;
179
179
  /**
180
180
  * Starts a learn process for the given credential slot, allowing a user
181
181
  * to input a credential directly on the device.
@@ -20,9 +20,9 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
20
20
  var AccessControl_exports = {};
21
21
  __export(AccessControl_exports, {
22
22
  AccessControlAPI: () => AccessControlAPI,
23
- AssignCredentialStatus: () => AssignCredentialStatus,
24
- SetCredentialStatus: () => SetCredentialStatus,
25
- SetUserStatus: () => SetUserStatus
23
+ AssignCredentialResult: () => AssignCredentialResult,
24
+ SetCredentialResult: () => SetCredentialResult,
25
+ SetUserResult: () => SetUserResult
26
26
  });
27
27
  module.exports = __toCommonJS(AccessControl_exports);
28
28
  var import_cc = require("@zwave-js/cc");
@@ -31,93 +31,93 @@ var import_UserCredentialCC = require("@zwave-js/cc/UserCredentialCC");
31
31
  var import_core = require("@zwave-js/core");
32
32
  var import_shared = require("@zwave-js/shared");
33
33
  var import_FeatureAPI = require("./FeatureAPI.js");
34
- var SetUserStatus;
35
- (function(SetUserStatus2) {
36
- SetUserStatus2[SetUserStatus2["OK"] = 0] = "OK";
37
- SetUserStatus2[SetUserStatus2["Error_AddRejectedLocationOccupied"] = 1] = "Error_AddRejectedLocationOccupied";
38
- SetUserStatus2[SetUserStatus2["Error_ModifyRejectedLocationEmpty"] = 2] = "Error_ModifyRejectedLocationEmpty";
39
- SetUserStatus2[SetUserStatus2["Error_Unknown"] = 255] = "Error_Unknown";
40
- })(SetUserStatus || (SetUserStatus = {}));
41
- var SetCredentialStatus;
42
- (function(SetCredentialStatus2) {
43
- SetCredentialStatus2[SetCredentialStatus2["OK"] = 0] = "OK";
44
- SetCredentialStatus2[SetCredentialStatus2["Error_AddRejectedLocationOccupied"] = 1] = "Error_AddRejectedLocationOccupied";
45
- SetCredentialStatus2[SetCredentialStatus2["Error_ModifyRejectedLocationEmpty"] = 2] = "Error_ModifyRejectedLocationEmpty";
46
- SetCredentialStatus2[SetCredentialStatus2["Error_DuplicateCredential"] = 3] = "Error_DuplicateCredential";
47
- SetCredentialStatus2[SetCredentialStatus2["Error_ManufacturerSecurityRules"] = 4] = "Error_ManufacturerSecurityRules";
48
- SetCredentialStatus2[SetCredentialStatus2["Error_DuplicateAdminPINCode"] = 5] = "Error_DuplicateAdminPINCode";
49
- SetCredentialStatus2[SetCredentialStatus2["Error_WrongUserUniqueIdentifier"] = 6] = "Error_WrongUserUniqueIdentifier";
50
- SetCredentialStatus2[SetCredentialStatus2["Error_Unknown"] = 255] = "Error_Unknown";
51
- })(SetCredentialStatus || (SetCredentialStatus = {}));
52
- var AssignCredentialStatus;
53
- (function(AssignCredentialStatus2) {
54
- AssignCredentialStatus2[AssignCredentialStatus2["OK"] = 0] = "OK";
55
- AssignCredentialStatus2[AssignCredentialStatus2["Error_InvalidCredential"] = 1] = "Error_InvalidCredential";
56
- AssignCredentialStatus2[AssignCredentialStatus2["Error_InvalidUser"] = 2] = "Error_InvalidUser";
57
- AssignCredentialStatus2[AssignCredentialStatus2["Error_Unknown"] = 255] = "Error_Unknown";
58
- })(AssignCredentialStatus || (AssignCredentialStatus = {}));
59
- function u3cUserSetResultToStatus(report) {
60
- if (!report)
61
- return SetUserStatus.Error_Unknown;
62
- switch (report.reportType) {
34
+ var SetUserResult;
35
+ (function(SetUserResult2) {
36
+ SetUserResult2[SetUserResult2["OK"] = 0] = "OK";
37
+ SetUserResult2[SetUserResult2["Error_AddRejectedLocationOccupied"] = 1] = "Error_AddRejectedLocationOccupied";
38
+ SetUserResult2[SetUserResult2["Error_ModifyRejectedLocationEmpty"] = 2] = "Error_ModifyRejectedLocationEmpty";
39
+ SetUserResult2[SetUserResult2["Error_Unknown"] = 255] = "Error_Unknown";
40
+ })(SetUserResult || (SetUserResult = {}));
41
+ var SetCredentialResult;
42
+ (function(SetCredentialResult2) {
43
+ SetCredentialResult2[SetCredentialResult2["OK"] = 0] = "OK";
44
+ SetCredentialResult2[SetCredentialResult2["Error_AddRejectedLocationOccupied"] = 1] = "Error_AddRejectedLocationOccupied";
45
+ SetCredentialResult2[SetCredentialResult2["Error_ModifyRejectedLocationEmpty"] = 2] = "Error_ModifyRejectedLocationEmpty";
46
+ SetCredentialResult2[SetCredentialResult2["Error_DuplicateCredential"] = 3] = "Error_DuplicateCredential";
47
+ SetCredentialResult2[SetCredentialResult2["Error_ManufacturerSecurityRules"] = 4] = "Error_ManufacturerSecurityRules";
48
+ SetCredentialResult2[SetCredentialResult2["Error_DuplicateAdminPINCode"] = 5] = "Error_DuplicateAdminPINCode";
49
+ SetCredentialResult2[SetCredentialResult2["Error_WrongUserUniqueIdentifier"] = 6] = "Error_WrongUserUniqueIdentifier";
50
+ SetCredentialResult2[SetCredentialResult2["Error_Unknown"] = 255] = "Error_Unknown";
51
+ })(SetCredentialResult || (SetCredentialResult = {}));
52
+ var AssignCredentialResult;
53
+ (function(AssignCredentialResult2) {
54
+ AssignCredentialResult2[AssignCredentialResult2["OK"] = 0] = "OK";
55
+ AssignCredentialResult2[AssignCredentialResult2["Error_InvalidCredential"] = 1] = "Error_InvalidCredential";
56
+ AssignCredentialResult2[AssignCredentialResult2["Error_InvalidUser"] = 2] = "Error_InvalidUser";
57
+ AssignCredentialResult2[AssignCredentialResult2["Error_Unknown"] = 255] = "Error_Unknown";
58
+ })(AssignCredentialResult || (AssignCredentialResult = {}));
59
+ function u3cUserReportTypeToSetUserResult(reportType) {
60
+ if (reportType == void 0)
61
+ return SetUserResult.Error_Unknown;
62
+ switch (reportType) {
63
63
  case import_cc.UserCredentialUserReportType.UserAdded:
64
64
  case import_cc.UserCredentialUserReportType.UserModified:
65
65
  case import_cc.UserCredentialUserReportType.UserDeleted:
66
66
  case import_cc.UserCredentialUserReportType.UserUnchanged:
67
- return SetUserStatus.OK;
67
+ return SetUserResult.OK;
68
68
  case import_cc.UserCredentialUserReportType.UserAddRejectedLocationOccupied:
69
- return SetUserStatus.Error_AddRejectedLocationOccupied;
69
+ return SetUserResult.Error_AddRejectedLocationOccupied;
70
70
  case import_cc.UserCredentialUserReportType.UserModifyRejectedLocationEmpty:
71
- return SetUserStatus.Error_ModifyRejectedLocationEmpty;
71
+ return SetUserResult.Error_ModifyRejectedLocationEmpty;
72
72
  default:
73
- return SetUserStatus.Error_Unknown;
73
+ return SetUserResult.Error_Unknown;
74
74
  }
75
75
  }
76
- __name(u3cUserSetResultToStatus, "u3cUserSetResultToStatus");
77
- function u3cCredentialSetResultToStatus(report) {
78
- if (!report)
79
- return SetCredentialStatus.Error_Unknown;
80
- switch (report.reportType) {
76
+ __name(u3cUserReportTypeToSetUserResult, "u3cUserReportTypeToSetUserResult");
77
+ function u3cCredentialReportTypeToSetCredentialResult(reportType) {
78
+ if (reportType == void 0)
79
+ return SetCredentialResult.Error_Unknown;
80
+ switch (reportType) {
81
81
  case import_cc.UserCredentialCredentialReportType.CredentialAdded:
82
82
  case import_cc.UserCredentialCredentialReportType.CredentialModified:
83
83
  case import_cc.UserCredentialCredentialReportType.CredentialDeleted:
84
84
  case import_cc.UserCredentialCredentialReportType.CredentialUnchanged:
85
- return SetCredentialStatus.OK;
85
+ return SetCredentialResult.OK;
86
86
  case import_cc.UserCredentialCredentialReportType.CredentialAddRejectedLocationOccupied:
87
- return SetCredentialStatus.Error_AddRejectedLocationOccupied;
87
+ return SetCredentialResult.Error_AddRejectedLocationOccupied;
88
88
  case import_cc.UserCredentialCredentialReportType.CredentialModifyRejectedLocationEmpty:
89
- return SetCredentialStatus.Error_ModifyRejectedLocationEmpty;
89
+ return SetCredentialResult.Error_ModifyRejectedLocationEmpty;
90
90
  case import_cc.UserCredentialCredentialReportType.DuplicateCredential:
91
- return SetCredentialStatus.Error_DuplicateCredential;
91
+ return SetCredentialResult.Error_DuplicateCredential;
92
92
  case import_cc.UserCredentialCredentialReportType.ManufacturerSecurityRules:
93
- return SetCredentialStatus.Error_ManufacturerSecurityRules;
93
+ return SetCredentialResult.Error_ManufacturerSecurityRules;
94
94
  case import_cc.UserCredentialCredentialReportType.DuplicateAdminPINCode:
95
- return SetCredentialStatus.Error_DuplicateAdminPINCode;
95
+ return SetCredentialResult.Error_DuplicateAdminPINCode;
96
96
  case import_cc.UserCredentialCredentialReportType.WrongUserUniqueIdentifier:
97
- return SetCredentialStatus.Error_WrongUserUniqueIdentifier;
97
+ return SetCredentialResult.Error_WrongUserUniqueIdentifier;
98
98
  default:
99
- return SetCredentialStatus.Error_Unknown;
99
+ return SetCredentialResult.Error_Unknown;
100
100
  }
101
101
  }
102
- __name(u3cCredentialSetResultToStatus, "u3cCredentialSetResultToStatus");
103
- function u3cAssociationResultToStatus(report) {
104
- if (!report)
105
- return AssignCredentialStatus.Error_Unknown;
106
- switch (report.status) {
102
+ __name(u3cCredentialReportTypeToSetCredentialResult, "u3cCredentialReportTypeToSetCredentialResult");
103
+ function u3cAssociationStatusToAssignCredentialResult(status) {
104
+ if (status == void 0)
105
+ return AssignCredentialResult.Error_Unknown;
106
+ switch (status) {
107
107
  case 0:
108
- return AssignCredentialStatus.OK;
108
+ return AssignCredentialResult.OK;
109
109
  case 1:
110
110
  case 2:
111
111
  case 3:
112
- return AssignCredentialStatus.Error_InvalidCredential;
112
+ return AssignCredentialResult.Error_InvalidCredential;
113
113
  case 4:
114
114
  case 5:
115
- return AssignCredentialStatus.Error_InvalidUser;
115
+ return AssignCredentialResult.Error_InvalidUser;
116
116
  default:
117
- return AssignCredentialStatus.Error_Unknown;
117
+ return AssignCredentialResult.Error_Unknown;
118
118
  }
119
119
  }
120
- __name(u3cAssociationResultToStatus, "u3cAssociationResultToStatus");
120
+ __name(u3cAssociationStatusToAssignCredentialResult, "u3cAssociationStatusToAssignCredentialResult");
121
121
  const NON_PIN_CHARS = /[^0-9]/;
122
122
  function supportsNonPINChars(supportedASCIIChars) {
123
123
  return supportedASCIIChars != void 0 && NON_PIN_CHARS.test(supportedASCIIChars);
@@ -355,7 +355,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
355
355
  }
356
356
  if (result)
357
357
  await this.endpoint.tryGetNode()?.handleCommand(result);
358
- return u3cUserSetResultToStatus(result);
358
+ return u3cUserReportTypeToSetUserResult(result?.reportType);
359
359
  } else {
360
360
  const api = this.#ucAPI();
361
361
  const existing = this.#getUserCached_UC(userId);
@@ -390,7 +390,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
390
390
  node.emit(existing ? "user modified" : "user added", this.endpoint, userData);
391
391
  }
392
392
  }
393
- return succeeded ? SetUserStatus.OK : SetUserStatus.Error_Unknown;
393
+ return succeeded ? SetUserResult.OK : SetUserResult.Error_Unknown;
394
394
  }
395
395
  }
396
396
  /**
@@ -406,8 +406,8 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
406
406
  });
407
407
  if (raw)
408
408
  await this.endpoint.tryGetNode()?.handleCommand(raw);
409
- const status = u3cUserSetResultToStatus(raw);
410
- if (status === SetUserStatus.OK) {
409
+ const status = u3cUserReportTypeToSetUserResult(raw?.reportType);
410
+ if (status === SetUserResult.OK) {
411
411
  this.#purgeCachedCredentials(userId);
412
412
  }
413
413
  return status;
@@ -434,7 +434,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
434
434
  });
435
435
  }
436
436
  }
437
- return succeeded ? SetUserStatus.OK : SetUserStatus.Error_Unknown;
437
+ return succeeded ? SetUserResult.OK : SetUserResult.Error_Unknown;
438
438
  }
439
439
  }
440
440
  /**
@@ -450,8 +450,8 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
450
450
  });
451
451
  if (raw)
452
452
  await this.endpoint.tryGetNode()?.handleCommand(raw);
453
- const status = u3cUserSetResultToStatus(raw);
454
- if (status === SetUserStatus.OK) {
453
+ const status = u3cUserReportTypeToSetUserResult(raw?.reportType);
454
+ if (status === SetUserResult.OK) {
455
455
  this.#purgeAllCachedUsersAndCredentials();
456
456
  }
457
457
  return status;
@@ -462,7 +462,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
462
462
  if (succeeded) {
463
463
  this.#purgeAllCachedUserCodes();
464
464
  }
465
- return succeeded ? SetUserStatus.OK : SetUserStatus.Error_Unknown;
465
+ return succeeded ? SetUserResult.OK : SetUserResult.Error_Unknown;
466
466
  }
467
467
  }
468
468
  /**
@@ -612,7 +612,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
612
612
  });
613
613
  if (raw)
614
614
  await this.endpoint.tryGetNode()?.handleCommand(raw);
615
- return u3cCredentialSetResultToStatus(raw);
615
+ return u3cCredentialReportTypeToSetCredentialResult(raw?.reportType);
616
616
  } else {
617
617
  this.#assertValidSlot(type, userId);
618
618
  const api = this.#ucAPI();
@@ -639,7 +639,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
639
639
  });
640
640
  }
641
641
  }
642
- return succeeded ? SetCredentialStatus.OK : SetCredentialStatus.Error_Unknown;
642
+ return succeeded ? SetCredentialResult.OK : SetCredentialResult.Error_Unknown;
643
643
  }
644
644
  }
645
645
  /**
@@ -658,7 +658,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
658
658
  });
659
659
  if (raw)
660
660
  await this.endpoint.tryGetNode()?.handleCommand(raw);
661
- return u3cCredentialSetResultToStatus(raw);
661
+ return u3cCredentialReportTypeToSetCredentialResult(raw?.reportType);
662
662
  } else {
663
663
  this.#assertValidSlot(type, userId);
664
664
  const existed = this.#getCredentialCached_UC(type, userId) != void 0;
@@ -682,7 +682,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
682
682
  node.emit("user deleted", this.endpoint, { userId });
683
683
  }
684
684
  }
685
- return succeeded ? SetCredentialStatus.OK : SetCredentialStatus.Error_Unknown;
685
+ return succeeded ? SetCredentialResult.OK : SetCredentialResult.Error_Unknown;
686
686
  }
687
687
  }
688
688
  /**
@@ -711,7 +711,7 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
711
711
  if (response) {
712
712
  await this.endpoint.tryGetNode()?.handleCommand(response);
713
713
  }
714
- return u3cAssociationResultToStatus(response);
714
+ return u3cAssociationStatusToAssignCredentialResult(response?.status);
715
715
  }
716
716
  /**
717
717
  * Starts a learn process for the given credential slot, allowing a user
@@ -1032,8 +1032,8 @@ class AccessControlAPI extends import_FeatureAPI.FeatureAPI {
1032
1032
  // Annotate the CommonJS export names for ESM import in node:
1033
1033
  0 && (module.exports = {
1034
1034
  AccessControlAPI,
1035
- AssignCredentialStatus,
1036
- SetCredentialStatus,
1037
- SetUserStatus
1035
+ AssignCredentialResult,
1036
+ SetCredentialResult,
1037
+ SetUserResult
1038
1038
  });
1039
1039
  //# sourceMappingURL=AccessControl.js.map