@azure/arm-hardwaresecuritymodules 2.0.0-alpha.20240118.1 → 2.0.0-beta.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.
Files changed (174) hide show
  1. package/CHANGELOG.md +82 -1
  2. package/LICENSE +1 -1
  3. package/README.md +14 -14
  4. package/dist/index.js +2215 -425
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.js +1 -1
  7. package/dist/index.min.js.map +1 -1
  8. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsCreateSample.d.ts +2 -0
  9. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsCreateSample.d.ts.map +1 -0
  10. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsCreateSample.js +46 -0
  11. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsCreateSample.js.map +1 -0
  12. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsDeleteSample.d.ts +2 -0
  13. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsDeleteSample.d.ts.map +1 -0
  14. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsDeleteSample.js +40 -0
  15. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsDeleteSample.js.map +1 -0
  16. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsGetSample.d.ts +2 -0
  17. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsGetSample.d.ts.map +1 -0
  18. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsGetSample.js +40 -0
  19. package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsGetSample.js.map +1 -0
  20. package/dist-esm/samples-dev/cloudHsmClusterPrivateLinkResourcesListByCloudHsmClusterSample.d.ts +2 -0
  21. package/dist-esm/samples-dev/cloudHsmClusterPrivateLinkResourcesListByCloudHsmClusterSample.d.ts.map +1 -0
  22. package/dist-esm/samples-dev/cloudHsmClusterPrivateLinkResourcesListByCloudHsmClusterSample.js +39 -0
  23. package/dist-esm/samples-dev/cloudHsmClusterPrivateLinkResourcesListByCloudHsmClusterSample.js.map +1 -0
  24. package/dist-esm/samples-dev/cloudHsmClustersCreateOrUpdateSample.d.ts +2 -0
  25. package/dist-esm/samples-dev/cloudHsmClustersCreateOrUpdateSample.d.ts.map +1 -0
  26. package/dist-esm/samples-dev/cloudHsmClustersCreateOrUpdateSample.js +53 -0
  27. package/dist-esm/samples-dev/cloudHsmClustersCreateOrUpdateSample.js.map +1 -0
  28. package/dist-esm/samples-dev/cloudHsmClustersDeleteSample.d.ts +2 -0
  29. package/dist-esm/samples-dev/cloudHsmClustersDeleteSample.d.ts.map +1 -0
  30. package/dist-esm/samples-dev/cloudHsmClustersDeleteSample.js +39 -0
  31. package/dist-esm/samples-dev/cloudHsmClustersDeleteSample.js.map +1 -0
  32. package/dist-esm/samples-dev/cloudHsmClustersGetSample.d.ts +2 -0
  33. package/dist-esm/samples-dev/cloudHsmClustersGetSample.d.ts.map +1 -0
  34. package/dist-esm/samples-dev/cloudHsmClustersGetSample.js +39 -0
  35. package/dist-esm/samples-dev/cloudHsmClustersGetSample.js.map +1 -0
  36. package/dist-esm/samples-dev/cloudHsmClustersListByResourceGroupSample.d.ts +2 -0
  37. package/dist-esm/samples-dev/cloudHsmClustersListByResourceGroupSample.d.ts.map +1 -0
  38. package/dist-esm/samples-dev/cloudHsmClustersListByResourceGroupSample.js +54 -0
  39. package/dist-esm/samples-dev/cloudHsmClustersListByResourceGroupSample.js.map +1 -0
  40. package/dist-esm/samples-dev/cloudHsmClustersListBySubscriptionSample.d.ts +2 -0
  41. package/dist-esm/samples-dev/cloudHsmClustersListBySubscriptionSample.d.ts.map +1 -0
  42. package/dist-esm/samples-dev/cloudHsmClustersListBySubscriptionSample.js +53 -0
  43. package/dist-esm/samples-dev/cloudHsmClustersListBySubscriptionSample.js.map +1 -0
  44. package/dist-esm/samples-dev/cloudHsmClustersUpdateSample.d.ts +2 -0
  45. package/dist-esm/samples-dev/cloudHsmClustersUpdateSample.d.ts.map +1 -0
  46. package/dist-esm/samples-dev/cloudHsmClustersUpdateSample.js +47 -0
  47. package/dist-esm/samples-dev/cloudHsmClustersUpdateSample.js.map +1 -0
  48. package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.js +23 -13
  49. package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.js.map +1 -1
  50. package/dist-esm/samples-dev/dedicatedHsmDeleteSample.js +13 -5
  51. package/dist-esm/samples-dev/dedicatedHsmDeleteSample.js.map +1 -1
  52. package/dist-esm/samples-dev/dedicatedHsmGetSample.js +23 -13
  53. package/dist-esm/samples-dev/dedicatedHsmGetSample.js.map +1 -1
  54. package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.js +18 -9
  55. package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.js.map +1 -1
  56. package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.js +16 -7
  57. package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.js.map +1 -1
  58. package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.js +13 -5
  59. package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.js.map +1 -1
  60. package/dist-esm/samples-dev/dedicatedHsmUpdateSample.js +18 -9
  61. package/dist-esm/samples-dev/dedicatedHsmUpdateSample.js.map +1 -1
  62. package/dist-esm/samples-dev/operationsListSample.js +16 -7
  63. package/dist-esm/samples-dev/operationsListSample.js.map +1 -1
  64. package/dist-esm/samples-dev/privateEndpointConnectionsListByCloudHsmClusterSample.d.ts +2 -0
  65. package/dist-esm/samples-dev/privateEndpointConnectionsListByCloudHsmClusterSample.d.ts.map +1 -0
  66. package/dist-esm/samples-dev/privateEndpointConnectionsListByCloudHsmClusterSample.js +55 -0
  67. package/dist-esm/samples-dev/privateEndpointConnectionsListByCloudHsmClusterSample.js.map +1 -0
  68. package/dist-esm/src/azureHSMResourceProvider.d.ts +22 -0
  69. package/dist-esm/src/azureHSMResourceProvider.d.ts.map +1 -0
  70. package/dist-esm/src/{azureDedicatedHSMResourceProvider.js → azureHSMResourceProvider.js} +10 -37
  71. package/dist-esm/src/azureHSMResourceProvider.js.map +1 -0
  72. package/dist-esm/src/index.d.ts +1 -1
  73. package/dist-esm/src/index.d.ts.map +1 -1
  74. package/dist-esm/src/index.js +1 -1
  75. package/dist-esm/src/index.js.map +1 -1
  76. package/dist-esm/src/lroImpl.d.ts +6 -11
  77. package/dist-esm/src/lroImpl.d.ts.map +1 -1
  78. package/dist-esm/src/lroImpl.js +12 -20
  79. package/dist-esm/src/lroImpl.js.map +1 -1
  80. package/dist-esm/src/models/index.d.ts +538 -8
  81. package/dist-esm/src/models/index.d.ts.map +1 -1
  82. package/dist-esm/src/models/index.js +72 -0
  83. package/dist-esm/src/models/index.js.map +1 -1
  84. package/dist-esm/src/models/mappers.d.ts +28 -2
  85. package/dist-esm/src/models/mappers.d.ts.map +1 -1
  86. package/dist-esm/src/models/mappers.js +692 -7
  87. package/dist-esm/src/models/mappers.js.map +1 -1
  88. package/dist-esm/src/models/parameters.d.ts +27 -5
  89. package/dist-esm/src/models/parameters.d.ts.map +1 -1
  90. package/dist-esm/src/models/parameters.js +161 -29
  91. package/dist-esm/src/models/parameters.js.map +1 -1
  92. package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.d.ts +55 -0
  93. package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.d.ts.map +1 -0
  94. package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.js +193 -0
  95. package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.js.map +1 -0
  96. package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.d.ts +21 -0
  97. package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.d.ts.map +1 -0
  98. package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.js +54 -0
  99. package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.js.map +1 -0
  100. package/dist-esm/src/operations/cloudHsmClusters.d.ts +114 -0
  101. package/dist-esm/src/operations/cloudHsmClusters.d.ts.map +1 -0
  102. package/dist-esm/src/operations/cloudHsmClusters.js +580 -0
  103. package/dist-esm/src/operations/cloudHsmClusters.js.map +1 -0
  104. package/dist-esm/src/operations/dedicatedHsmOperations.d.ts +6 -6
  105. package/dist-esm/src/operations/dedicatedHsmOperations.d.ts.map +1 -1
  106. package/dist-esm/src/operations/dedicatedHsmOperations.js +51 -39
  107. package/dist-esm/src/operations/dedicatedHsmOperations.js.map +1 -1
  108. package/dist-esm/src/operations/index.d.ts +4 -0
  109. package/dist-esm/src/operations/index.d.ts.map +1 -1
  110. package/dist-esm/src/operations/index.js +4 -0
  111. package/dist-esm/src/operations/index.js.map +1 -1
  112. package/dist-esm/src/operations/operations.d.ts +2 -2
  113. package/dist-esm/src/operations/operations.d.ts.map +1 -1
  114. package/dist-esm/src/operations/operations.js +1 -1
  115. package/dist-esm/src/operations/operations.js.map +1 -1
  116. package/dist-esm/src/operations/privateEndpointConnections.d.ts +43 -0
  117. package/dist-esm/src/operations/privateEndpointConnections.d.ts.map +1 -0
  118. package/dist-esm/src/operations/privateEndpointConnections.js +155 -0
  119. package/dist-esm/src/operations/privateEndpointConnections.js.map +1 -0
  120. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.d.ts +47 -0
  121. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.d.ts.map +1 -0
  122. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.js +9 -0
  123. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.js.map +1 -0
  124. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.d.ts +13 -0
  125. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.d.ts.map +1 -0
  126. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.js +9 -0
  127. package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.js.map +1 -0
  128. package/dist-esm/src/operationsInterfaces/cloudHsmClusters.d.ts +77 -0
  129. package/dist-esm/src/operationsInterfaces/cloudHsmClusters.d.ts.map +1 -0
  130. package/dist-esm/src/operationsInterfaces/cloudHsmClusters.js +9 -0
  131. package/dist-esm/src/operationsInterfaces/cloudHsmClusters.js.map +1 -0
  132. package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.d.ts +4 -4
  133. package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.d.ts.map +1 -1
  134. package/dist-esm/src/operationsInterfaces/index.d.ts +4 -0
  135. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -1
  136. package/dist-esm/src/operationsInterfaces/index.js +4 -0
  137. package/dist-esm/src/operationsInterfaces/index.js.map +1 -1
  138. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts +15 -0
  139. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts.map +1 -0
  140. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.js +9 -0
  141. package/dist-esm/src/operationsInterfaces/privateEndpointConnections.js.map +1 -0
  142. package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.d.ts +4 -0
  143. package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.d.ts.map +1 -0
  144. package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.js +73 -0
  145. package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.js.map +1 -0
  146. package/package.json +15 -12
  147. package/review/arm-hardwaresecuritymodules.api.md +426 -19
  148. package/src/{azureDedicatedHSMResourceProvider.ts → azureHSMResourceProvider.ts} +35 -46
  149. package/src/index.ts +1 -1
  150. package/src/lroImpl.ts +31 -23
  151. package/src/models/index.ts +599 -8
  152. package/src/models/mappers.ts +751 -7
  153. package/src/models/parameters.ts +187 -30
  154. package/src/operations/cloudHsmClusterPrivateEndpointConnections.ts +263 -0
  155. package/src/operations/cloudHsmClusterPrivateLinkResources.ts +74 -0
  156. package/src/operations/cloudHsmClusters.ts +750 -0
  157. package/src/operations/dedicatedHsmOperations.ts +69 -59
  158. package/src/operations/index.ts +4 -0
  159. package/src/operations/operations.ts +4 -4
  160. package/src/operations/privateEndpointConnections.ts +208 -0
  161. package/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.ts +83 -0
  162. package/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.ts +28 -0
  163. package/src/operationsInterfaces/cloudHsmClusters.ts +142 -0
  164. package/src/operationsInterfaces/dedicatedHsmOperations.ts +6 -6
  165. package/src/operationsInterfaces/index.ts +4 -0
  166. package/src/operationsInterfaces/privateEndpointConnections.ts +31 -0
  167. package/types/arm-hardwaresecuritymodules.d.ts +773 -34
  168. package/dist-esm/src/azureDedicatedHSMResourceProvider.d.ts +0 -22
  169. package/dist-esm/src/azureDedicatedHSMResourceProvider.d.ts.map +0 -1
  170. package/dist-esm/src/azureDedicatedHSMResourceProvider.js.map +0 -1
  171. package/dist-esm/test/sampleTest.d.ts +0 -2
  172. package/dist-esm/test/sampleTest.d.ts.map +0 -1
  173. package/dist-esm/test/sampleTest.js +0 -38
  174. package/dist-esm/test/sampleTest.js.map +0 -1
package/dist/index.js CHANGED
@@ -2,9 +2,9 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var tslib = require('tslib');
6
5
  var coreClient = require('@azure/core-client');
7
6
  var coreRestPipeline = require('@azure/core-rest-pipeline');
7
+ var tslib = require('tslib');
8
8
  var coreLro = require('@azure/core-lro');
9
9
 
10
10
  function _interopNamespaceDefault(e) {
@@ -66,6 +66,78 @@ function setContinuationToken(page, continuationToken) {
66
66
  * Code generated by Microsoft (R) AutoRest Code Generator.
67
67
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
68
68
  */
69
+ /** Known values of {@link ProvisioningState} that the service accepts. */
70
+ exports.KnownProvisioningState = void 0;
71
+ (function (KnownProvisioningState) {
72
+ /** Provisioning */
73
+ KnownProvisioningState["Provisioning"] = "Provisioning";
74
+ /** Succeeded */
75
+ KnownProvisioningState["Succeeded"] = "Succeeded";
76
+ /** Failed */
77
+ KnownProvisioningState["Failed"] = "Failed";
78
+ /** Deleting */
79
+ KnownProvisioningState["Deleting"] = "Deleting";
80
+ /** Canceled */
81
+ KnownProvisioningState["Canceled"] = "Canceled";
82
+ })(exports.KnownProvisioningState || (exports.KnownProvisioningState = {}));
83
+ /** Known values of {@link PrivateEndpointServiceConnectionStatus} that the service accepts. */
84
+ exports.KnownPrivateEndpointServiceConnectionStatus = void 0;
85
+ (function (KnownPrivateEndpointServiceConnectionStatus) {
86
+ /** Pending */
87
+ KnownPrivateEndpointServiceConnectionStatus["Pending"] = "Pending";
88
+ /** Approved */
89
+ KnownPrivateEndpointServiceConnectionStatus["Approved"] = "Approved";
90
+ /** Rejected */
91
+ KnownPrivateEndpointServiceConnectionStatus["Rejected"] = "Rejected";
92
+ })(exports.KnownPrivateEndpointServiceConnectionStatus || (exports.KnownPrivateEndpointServiceConnectionStatus = {}));
93
+ /** Known values of {@link PrivateEndpointConnectionProvisioningState} that the service accepts. */
94
+ exports.KnownPrivateEndpointConnectionProvisioningState = void 0;
95
+ (function (KnownPrivateEndpointConnectionProvisioningState) {
96
+ /** Succeeded */
97
+ KnownPrivateEndpointConnectionProvisioningState["Succeeded"] = "Succeeded";
98
+ /** Creating */
99
+ KnownPrivateEndpointConnectionProvisioningState["Creating"] = "Creating";
100
+ /** Deleting */
101
+ KnownPrivateEndpointConnectionProvisioningState["Deleting"] = "Deleting";
102
+ /** Failed */
103
+ KnownPrivateEndpointConnectionProvisioningState["Failed"] = "Failed";
104
+ /** Updating */
105
+ KnownPrivateEndpointConnectionProvisioningState["Updating"] = "Updating";
106
+ /** InternalError */
107
+ KnownPrivateEndpointConnectionProvisioningState["InternalError"] = "InternalError";
108
+ /** Canceled */
109
+ KnownPrivateEndpointConnectionProvisioningState["Canceled"] = "Canceled";
110
+ })(exports.KnownPrivateEndpointConnectionProvisioningState || (exports.KnownPrivateEndpointConnectionProvisioningState = {}));
111
+ /** Known values of {@link CreatedByType} that the service accepts. */
112
+ exports.KnownCreatedByType = void 0;
113
+ (function (KnownCreatedByType) {
114
+ /** User */
115
+ KnownCreatedByType["User"] = "User";
116
+ /** Application */
117
+ KnownCreatedByType["Application"] = "Application";
118
+ /** ManagedIdentity */
119
+ KnownCreatedByType["ManagedIdentity"] = "ManagedIdentity";
120
+ /** Key */
121
+ KnownCreatedByType["Key"] = "Key";
122
+ })(exports.KnownCreatedByType || (exports.KnownCreatedByType = {}));
123
+ /** Known values of {@link CloudHsmClusterSkuFamily} that the service accepts. */
124
+ exports.KnownCloudHsmClusterSkuFamily = void 0;
125
+ (function (KnownCloudHsmClusterSkuFamily) {
126
+ /** B */
127
+ KnownCloudHsmClusterSkuFamily["B"] = "B";
128
+ })(exports.KnownCloudHsmClusterSkuFamily || (exports.KnownCloudHsmClusterSkuFamily = {}));
129
+ /** Known values of {@link ManagedServiceIdentityType} that the service accepts. */
130
+ exports.KnownManagedServiceIdentityType = void 0;
131
+ (function (KnownManagedServiceIdentityType) {
132
+ /** None */
133
+ KnownManagedServiceIdentityType["None"] = "None";
134
+ /** SystemAssigned */
135
+ KnownManagedServiceIdentityType["SystemAssigned"] = "SystemAssigned";
136
+ /** UserAssigned */
137
+ KnownManagedServiceIdentityType["UserAssigned"] = "UserAssigned";
138
+ /** SystemAssignedUserAssigned */
139
+ KnownManagedServiceIdentityType["SystemAssignedUserAssigned"] = "SystemAssigned,UserAssigned";
140
+ })(exports.KnownManagedServiceIdentityType || (exports.KnownManagedServiceIdentityType = {}));
69
141
  /** Known values of {@link IdentityType} that the service accepts. */
70
142
  exports.KnownIdentityType = void 0;
71
143
  (function (KnownIdentityType) {
@@ -122,79 +194,86 @@ exports.KnownSkuName = void 0;
122
194
  * Code generated by Microsoft (R) AutoRest Code Generator.
123
195
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
124
196
  */
125
- const DedicatedHsmOperationListResult = {
197
+ const CloudHsmClusterSecurityDomainProperties = {
126
198
  type: {
127
199
  name: "Composite",
128
- className: "DedicatedHsmOperationListResult",
200
+ className: "CloudHsmClusterSecurityDomainProperties",
129
201
  modelProperties: {
130
- value: {
131
- serializedName: "value",
202
+ fipsState: {
203
+ serializedName: "fipsState",
132
204
  type: {
133
- name: "Sequence",
134
- element: {
135
- type: {
136
- name: "Composite",
137
- className: "DedicatedHsmOperation"
138
- }
139
- }
205
+ name: "Number"
206
+ }
207
+ },
208
+ activationStatus: {
209
+ serializedName: "activationStatus",
210
+ type: {
211
+ name: "String"
140
212
  }
141
213
  }
142
214
  }
143
215
  }
144
216
  };
145
- const DedicatedHsmOperation = {
217
+ const CloudHsmProperties = {
146
218
  type: {
147
219
  name: "Composite",
148
- className: "DedicatedHsmOperation",
220
+ className: "CloudHsmProperties",
149
221
  modelProperties: {
150
- name: {
151
- serializedName: "name",
222
+ fqdn: {
223
+ serializedName: "fqdn",
152
224
  type: {
153
225
  name: "String"
154
226
  }
155
227
  },
156
- isDataAction: {
157
- serializedName: "isDataAction",
158
- readOnly: true,
228
+ state: {
229
+ serializedName: "state",
159
230
  type: {
160
- name: "Boolean"
231
+ name: "String"
161
232
  }
162
233
  },
163
- display: {
164
- serializedName: "display",
234
+ stateMessage: {
235
+ serializedName: "stateMessage",
165
236
  type: {
166
- name: "Composite",
167
- className: "DedicatedHsmOperationDisplay"
237
+ name: "String"
168
238
  }
169
239
  }
170
240
  }
171
241
  }
172
242
  };
173
- const DedicatedHsmOperationDisplay = {
243
+ const PrivateEndpoint = {
174
244
  type: {
175
245
  name: "Composite",
176
- className: "DedicatedHsmOperationDisplay",
246
+ className: "PrivateEndpoint",
177
247
  modelProperties: {
178
- provider: {
179
- serializedName: "provider",
248
+ id: {
249
+ serializedName: "id",
250
+ readOnly: true,
180
251
  type: {
181
252
  name: "String"
182
253
  }
183
- },
184
- resource: {
185
- serializedName: "resource",
254
+ }
255
+ }
256
+ }
257
+ };
258
+ const PrivateLinkServiceConnectionState = {
259
+ type: {
260
+ name: "Composite",
261
+ className: "PrivateLinkServiceConnectionState",
262
+ modelProperties: {
263
+ status: {
264
+ serializedName: "status",
186
265
  type: {
187
266
  name: "String"
188
267
  }
189
268
  },
190
- operation: {
191
- serializedName: "operation",
269
+ description: {
270
+ serializedName: "description",
192
271
  type: {
193
272
  name: "String"
194
273
  }
195
274
  },
196
- description: {
197
- serializedName: "description",
275
+ actionsRequired: {
276
+ serializedName: "actionsRequired",
198
277
  type: {
199
278
  name: "String"
200
279
  }
@@ -202,45 +281,37 @@ const DedicatedHsmOperationDisplay = {
202
281
  }
203
282
  }
204
283
  };
205
- const DedicatedHsmError = {
284
+ const Resource = {
206
285
  type: {
207
286
  name: "Composite",
208
- className: "DedicatedHsmError",
287
+ className: "Resource",
209
288
  modelProperties: {
210
- error: {
211
- serializedName: "error",
289
+ id: {
290
+ serializedName: "id",
291
+ readOnly: true,
212
292
  type: {
213
- name: "Composite",
214
- className: "ErrorModel"
293
+ name: "String"
215
294
  }
216
- }
217
- }
218
- }
219
- };
220
- const ErrorModel = {
221
- type: {
222
- name: "Composite",
223
- className: "ErrorModel",
224
- modelProperties: {
225
- code: {
226
- serializedName: "code",
295
+ },
296
+ name: {
297
+ serializedName: "name",
227
298
  readOnly: true,
228
299
  type: {
229
300
  name: "String"
230
301
  }
231
302
  },
232
- message: {
233
- serializedName: "message",
303
+ type: {
304
+ serializedName: "type",
234
305
  readOnly: true,
235
306
  type: {
236
307
  name: "String"
237
308
  }
238
309
  },
239
- innerError: {
240
- serializedName: "innererror",
310
+ systemData: {
311
+ serializedName: "systemData",
241
312
  type: {
242
313
  name: "Composite",
243
- className: "ErrorModel"
314
+ className: "SystemData"
244
315
  }
245
316
  }
246
317
  }
@@ -290,40 +361,47 @@ const SystemData = {
290
361
  }
291
362
  }
292
363
  };
293
- const NetworkProfile = {
364
+ const RestoreProperties = {
294
365
  type: {
295
366
  name: "Composite",
296
- className: "NetworkProfile",
367
+ className: "RestoreProperties",
297
368
  modelProperties: {
298
- subnet: {
299
- serializedName: "subnet",
369
+ foldername: {
370
+ serializedName: "foldername",
300
371
  type: {
301
- name: "Composite",
302
- className: "ApiEntityReference"
372
+ name: "String"
303
373
  }
304
374
  },
305
- networkInterfaces: {
306
- serializedName: "networkInterfaces",
375
+ azureStorageResourceUri: {
376
+ serializedName: "azureStorageResourceUri",
307
377
  type: {
308
- name: "Sequence",
309
- element: {
310
- type: {
311
- name: "Composite",
312
- className: "NetworkInterface"
313
- }
314
- }
378
+ name: "String"
315
379
  }
316
380
  }
317
381
  }
318
382
  }
319
383
  };
320
- const ApiEntityReference = {
384
+ const BackupProperties = {
321
385
  type: {
322
386
  name: "Composite",
323
- className: "ApiEntityReference",
387
+ className: "BackupProperties",
324
388
  modelProperties: {
325
- id: {
326
- serializedName: "id",
389
+ azureStorageResourceUri: {
390
+ serializedName: "azureStorageResourceUri",
391
+ type: {
392
+ name: "String"
393
+ }
394
+ },
395
+ lastBackupDateTime: {
396
+ serializedName: "lastBackupDateTime",
397
+ readOnly: true,
398
+ type: {
399
+ name: "DateTime"
400
+ }
401
+ },
402
+ lastBackupStatus: {
403
+ serializedName: "lastBackupStatus",
404
+ readOnly: true,
327
405
  type: {
328
406
  name: "String"
329
407
  }
@@ -331,95 +409,125 @@ const ApiEntityReference = {
331
409
  }
332
410
  }
333
411
  };
334
- const NetworkInterface = {
412
+ const CloudHsmClusterSku = {
335
413
  type: {
336
414
  name: "Composite",
337
- className: "NetworkInterface",
415
+ className: "CloudHsmClusterSku",
338
416
  modelProperties: {
339
- id: {
340
- serializedName: "id",
341
- readOnly: true,
417
+ family: {
418
+ serializedName: "family",
419
+ required: true,
342
420
  type: {
343
421
  name: "String"
344
422
  }
345
423
  },
346
- privateIpAddress: {
347
- serializedName: "privateIpAddress",
424
+ name: {
425
+ serializedName: "name",
426
+ required: true,
348
427
  type: {
349
- name: "String"
428
+ name: "Enum",
429
+ allowedValues: ["Standard_B1", "Standard B10"]
430
+ }
431
+ },
432
+ capacity: {
433
+ serializedName: "capacity",
434
+ type: {
435
+ name: "Number"
350
436
  }
351
437
  }
352
438
  }
353
439
  }
354
440
  };
355
- const Resource = {
441
+ const ManagedServiceIdentity = {
356
442
  type: {
357
443
  name: "Composite",
358
- className: "Resource",
444
+ className: "ManagedServiceIdentity",
359
445
  modelProperties: {
360
- id: {
361
- serializedName: "id",
446
+ principalId: {
447
+ serializedName: "principalId",
362
448
  readOnly: true,
363
449
  type: {
364
- name: "String"
450
+ name: "Uuid"
365
451
  }
366
452
  },
367
- name: {
368
- serializedName: "name",
453
+ tenantId: {
454
+ serializedName: "tenantId",
369
455
  readOnly: true,
370
456
  type: {
371
- name: "String"
457
+ name: "Uuid"
372
458
  }
373
459
  },
374
460
  type: {
375
461
  serializedName: "type",
376
- readOnly: true,
462
+ required: true,
377
463
  type: {
378
464
  name: "String"
379
465
  }
380
466
  },
381
- location: {
382
- serializedName: "location",
383
- required: true,
467
+ userAssignedIdentities: {
468
+ serializedName: "userAssignedIdentities",
384
469
  type: {
385
- name: "String"
470
+ name: "Dictionary",
471
+ value: {
472
+ type: { name: "Composite", className: "UserAssignedIdentity" }
473
+ }
386
474
  }
387
- },
388
- sku: {
389
- serializedName: "sku",
475
+ }
476
+ }
477
+ }
478
+ };
479
+ const UserAssignedIdentity = {
480
+ type: {
481
+ name: "Composite",
482
+ className: "UserAssignedIdentity",
483
+ modelProperties: {
484
+ principalId: {
485
+ serializedName: "principalId",
486
+ readOnly: true,
390
487
  type: {
391
- name: "Composite",
392
- className: "Sku"
488
+ name: "Uuid"
393
489
  }
394
490
  },
395
- zones: {
396
- serializedName: "zones",
491
+ clientId: {
492
+ serializedName: "clientId",
493
+ readOnly: true,
397
494
  type: {
398
- name: "Sequence",
399
- element: {
400
- type: {
401
- name: "String"
402
- }
403
- }
495
+ name: "Uuid"
404
496
  }
405
- },
406
- tags: {
407
- serializedName: "tags",
497
+ }
498
+ }
499
+ }
500
+ };
501
+ const CloudHsmClusterError = {
502
+ type: {
503
+ name: "Composite",
504
+ className: "CloudHsmClusterError",
505
+ modelProperties: {
506
+ error: {
507
+ serializedName: "error",
408
508
  type: {
409
- name: "Dictionary",
410
- value: { type: { name: "String" } }
509
+ name: "Composite",
510
+ className: "CHsmError"
411
511
  }
412
512
  }
413
513
  }
414
514
  }
415
515
  };
416
- const Sku = {
516
+ const CHsmError = {
417
517
  type: {
418
518
  name: "Composite",
419
- className: "Sku",
519
+ className: "CHsmError",
420
520
  modelProperties: {
421
- name: {
422
- serializedName: "name",
521
+ code: {
522
+ serializedName: "code",
523
+ readOnly: true,
524
+ type: {
525
+ name: "String"
526
+ }
527
+ },
528
+ message: {
529
+ serializedName: "message",
530
+ readOnly: true,
423
531
  type: {
424
532
  name: "String"
425
533
  }
@@ -427,10 +535,10 @@ const Sku = {
427
535
  }
428
536
  }
429
537
  };
430
- const DedicatedHsmPatchParameters = {
538
+ const CloudHsmClusterPatchParameters = {
431
539
  type: {
432
540
  name: "Composite",
433
- className: "DedicatedHsmPatchParameters",
541
+ className: "CloudHsmClusterPatchParameters",
434
542
  modelProperties: {
435
543
  tags: {
436
544
  serializedName: "tags",
@@ -438,14 +546,35 @@ const DedicatedHsmPatchParameters = {
438
546
  name: "Dictionary",
439
547
  value: { type: { name: "String" } }
440
548
  }
549
+ },
550
+ sku: {
551
+ serializedName: "sku",
552
+ type: {
553
+ name: "Composite",
554
+ className: "CloudHsmClusterSku"
555
+ }
556
+ },
557
+ identity: {
558
+ serializedName: "identity",
559
+ type: {
560
+ name: "Composite",
561
+ className: "ManagedServiceIdentity"
562
+ }
563
+ },
564
+ backupProperties: {
565
+ serializedName: "properties.backupProperties",
566
+ type: {
567
+ name: "Composite",
568
+ className: "BackupProperties"
569
+ }
441
570
  }
442
571
  }
443
572
  }
444
573
  };
445
- const DedicatedHsmListResult = {
574
+ const CloudHsmClusterListResult = {
446
575
  type: {
447
576
  name: "Composite",
448
- className: "DedicatedHsmListResult",
577
+ className: "CloudHsmClusterListResult",
449
578
  modelProperties: {
450
579
  value: {
451
580
  serializedName: "value",
@@ -454,7 +583,7 @@ const DedicatedHsmListResult = {
454
583
  element: {
455
584
  type: {
456
585
  name: "Composite",
457
- className: "DedicatedHsm"
586
+ className: "CloudHsmCluster"
458
587
  }
459
588
  }
460
589
  }
@@ -468,79 +597,65 @@ const DedicatedHsmListResult = {
468
597
  }
469
598
  }
470
599
  };
471
- const OutboundEnvironmentEndpointCollection = {
600
+ const PrivateLinkResourceListResult = {
472
601
  type: {
473
602
  name: "Composite",
474
- className: "OutboundEnvironmentEndpointCollection",
603
+ className: "PrivateLinkResourceListResult",
475
604
  modelProperties: {
476
605
  value: {
477
606
  serializedName: "value",
478
- required: true,
479
607
  type: {
480
608
  name: "Sequence",
481
609
  element: {
482
610
  type: {
483
611
  name: "Composite",
484
- className: "OutboundEnvironmentEndpoint"
612
+ className: "PrivateLinkResource"
485
613
  }
486
614
  }
487
615
  }
488
- },
489
- nextLink: {
490
- serializedName: "nextLink",
491
- readOnly: true,
492
- type: {
493
- name: "String"
494
- }
495
616
  }
496
617
  }
497
618
  }
498
619
  };
499
- const OutboundEnvironmentEndpoint = {
620
+ const PrivateEndpointConnectionListResult = {
500
621
  type: {
501
622
  name: "Composite",
502
- className: "OutboundEnvironmentEndpoint",
623
+ className: "PrivateEndpointConnectionListResult",
503
624
  modelProperties: {
504
- category: {
505
- serializedName: "category",
506
- type: {
507
- name: "String"
508
- }
509
- },
510
- endpoints: {
511
- serializedName: "endpoints",
625
+ value: {
626
+ serializedName: "value",
512
627
  type: {
513
628
  name: "Sequence",
514
629
  element: {
515
630
  type: {
516
631
  name: "Composite",
517
- className: "EndpointDependency"
632
+ className: "PrivateEndpointConnection"
518
633
  }
519
634
  }
520
635
  }
521
- }
522
- }
523
- }
524
- };
525
- const EndpointDependency = {
526
- type: {
527
- name: "Composite",
528
- className: "EndpointDependency",
529
- modelProperties: {
530
- domainName: {
531
- serializedName: "domainName",
636
+ },
637
+ nextLink: {
638
+ serializedName: "nextLink",
532
639
  type: {
533
640
  name: "String"
534
641
  }
535
- },
536
- endpointDetails: {
537
- serializedName: "endpointDetails",
642
+ }
643
+ }
644
+ }
645
+ };
646
+ const DedicatedHsmOperationListResult = {
647
+ type: {
648
+ name: "Composite",
649
+ className: "DedicatedHsmOperationListResult",
650
+ modelProperties: {
651
+ value: {
652
+ serializedName: "value",
538
653
  type: {
539
654
  name: "Sequence",
540
655
  element: {
541
656
  type: {
542
657
  name: "Composite",
543
- className: "EndpointDetail"
658
+ className: "DedicatedHsmOperation"
544
659
  }
545
660
  }
546
661
  }
@@ -548,25 +663,59 @@ const EndpointDependency = {
548
663
  }
549
664
  }
550
665
  };
551
- const EndpointDetail = {
666
+ const DedicatedHsmOperation = {
552
667
  type: {
553
668
  name: "Composite",
554
- className: "EndpointDetail",
669
+ className: "DedicatedHsmOperation",
555
670
  modelProperties: {
556
- ipAddress: {
557
- serializedName: "ipAddress",
671
+ name: {
672
+ serializedName: "name",
558
673
  type: {
559
674
  name: "String"
560
675
  }
561
676
  },
562
- port: {
563
- serializedName: "port",
677
+ isDataAction: {
678
+ serializedName: "isDataAction",
679
+ readOnly: true,
564
680
  type: {
565
- name: "Number"
681
+ name: "Boolean"
566
682
  }
567
683
  },
568
- protocol: {
569
- serializedName: "protocol",
684
+ origin: {
685
+ serializedName: "origin",
686
+ type: {
687
+ name: "String"
688
+ }
689
+ },
690
+ display: {
691
+ serializedName: "display",
692
+ type: {
693
+ name: "Composite",
694
+ className: "DedicatedHsmOperationDisplay"
695
+ }
696
+ }
697
+ }
698
+ }
699
+ };
700
+ const DedicatedHsmOperationDisplay = {
701
+ type: {
702
+ name: "Composite",
703
+ className: "DedicatedHsmOperationDisplay",
704
+ modelProperties: {
705
+ provider: {
706
+ serializedName: "provider",
707
+ type: {
708
+ name: "String"
709
+ }
710
+ },
711
+ resource: {
712
+ serializedName: "resource",
713
+ type: {
714
+ name: "String"
715
+ }
716
+ },
717
+ operation: {
718
+ serializedName: "operation",
570
719
  type: {
571
720
  name: "String"
572
721
  }
@@ -580,25 +729,128 @@ const EndpointDetail = {
580
729
  }
581
730
  }
582
731
  };
583
- const ResourceListResult = {
732
+ const DedicatedHsmError = {
584
733
  type: {
585
734
  name: "Composite",
586
- className: "ResourceListResult",
735
+ className: "DedicatedHsmError",
587
736
  modelProperties: {
588
- value: {
589
- serializedName: "value",
737
+ error: {
738
+ serializedName: "error",
739
+ type: {
740
+ name: "Composite",
741
+ className: "ErrorModel"
742
+ }
743
+ }
744
+ }
745
+ }
746
+ };
747
+ const ErrorModel = {
748
+ type: {
749
+ name: "Composite",
750
+ className: "ErrorModel",
751
+ modelProperties: {
752
+ code: {
753
+ serializedName: "code",
754
+ readOnly: true,
755
+ type: {
756
+ name: "String"
757
+ }
758
+ },
759
+ message: {
760
+ serializedName: "message",
761
+ readOnly: true,
762
+ type: {
763
+ name: "String"
764
+ }
765
+ },
766
+ innerError: {
767
+ serializedName: "innererror",
768
+ type: {
769
+ name: "Composite",
770
+ className: "ErrorModel"
771
+ }
772
+ }
773
+ }
774
+ }
775
+ };
776
+ const SystemDataAutoGenerated = {
777
+ type: {
778
+ name: "Composite",
779
+ className: "SystemDataAutoGenerated",
780
+ modelProperties: {
781
+ createdBy: {
782
+ serializedName: "createdBy",
783
+ type: {
784
+ name: "String"
785
+ }
786
+ },
787
+ createdByType: {
788
+ serializedName: "createdByType",
789
+ type: {
790
+ name: "String"
791
+ }
792
+ },
793
+ createdAt: {
794
+ serializedName: "createdAt",
795
+ type: {
796
+ name: "DateTime"
797
+ }
798
+ },
799
+ lastModifiedBy: {
800
+ serializedName: "lastModifiedBy",
801
+ type: {
802
+ name: "String"
803
+ }
804
+ },
805
+ lastModifiedByType: {
806
+ serializedName: "lastModifiedByType",
807
+ type: {
808
+ name: "String"
809
+ }
810
+ },
811
+ lastModifiedAt: {
812
+ serializedName: "lastModifiedAt",
813
+ type: {
814
+ name: "DateTime"
815
+ }
816
+ }
817
+ }
818
+ }
819
+ };
820
+ const NetworkProfile = {
821
+ type: {
822
+ name: "Composite",
823
+ className: "NetworkProfile",
824
+ modelProperties: {
825
+ subnet: {
826
+ serializedName: "subnet",
827
+ type: {
828
+ name: "Composite",
829
+ className: "ApiEntityReference"
830
+ }
831
+ },
832
+ networkInterfaces: {
833
+ serializedName: "networkInterfaces",
590
834
  type: {
591
835
  name: "Sequence",
592
836
  element: {
593
837
  type: {
594
838
  name: "Composite",
595
- className: "Resource"
839
+ className: "NetworkInterface"
596
840
  }
597
841
  }
598
842
  }
599
- },
600
- nextLink: {
601
- serializedName: "nextLink",
843
+ }
844
+ }
845
+ }
846
+ };
847
+ const ApiEntityReference = {
848
+ type: {
849
+ name: "Composite",
850
+ className: "ApiEntityReference",
851
+ modelProperties: {
852
+ id: {
853
+ serializedName: "id",
602
854
  type: {
603
855
  name: "String"
604
856
  }
@@ -606,72 +858,1621 @@ const ResourceListResult = {
606
858
  }
607
859
  }
608
860
  };
609
- const DedicatedHsm = {
861
+ const NetworkInterface = {
610
862
  type: {
611
863
  name: "Composite",
612
- className: "DedicatedHsm",
613
- modelProperties: Object.assign(Object.assign({}, Resource.type.modelProperties), { systemData: {
614
- serializedName: "systemData",
864
+ className: "NetworkInterface",
865
+ modelProperties: {
866
+ id: {
867
+ serializedName: "id",
868
+ readOnly: true,
615
869
  type: {
616
- name: "Composite",
617
- className: "SystemData"
870
+ name: "String"
618
871
  }
619
- }, networkProfile: {
620
- serializedName: "properties.networkProfile",
872
+ },
873
+ privateIpAddress: {
874
+ serializedName: "privateIpAddress",
621
875
  type: {
622
- name: "Composite",
623
- className: "NetworkProfile"
876
+ name: "String"
624
877
  }
625
- }, managementNetworkProfile: {
626
- serializedName: "properties.managementNetworkProfile",
878
+ }
879
+ }
880
+ }
881
+ };
882
+ const DedicatedHsmResource = {
883
+ type: {
884
+ name: "Composite",
885
+ className: "DedicatedHsmResource",
886
+ modelProperties: {
887
+ id: {
888
+ serializedName: "id",
889
+ readOnly: true,
627
890
  type: {
628
- name: "Composite",
629
- className: "NetworkProfile"
891
+ name: "String"
630
892
  }
631
- }, stampId: {
632
- serializedName: "properties.stampId",
893
+ },
894
+ name: {
895
+ serializedName: "name",
896
+ readOnly: true,
633
897
  type: {
634
898
  name: "String"
635
899
  }
636
- }, statusMessage: {
637
- serializedName: "properties.statusMessage",
900
+ },
901
+ type: {
902
+ serializedName: "type",
638
903
  readOnly: true,
639
904
  type: {
640
905
  name: "String"
641
906
  }
642
- }, provisioningState: {
643
- serializedName: "properties.provisioningState",
644
- readOnly: true,
907
+ },
908
+ location: {
909
+ serializedName: "location",
910
+ required: true,
645
911
  type: {
646
912
  name: "String"
647
913
  }
648
- } })
649
- }
914
+ },
915
+ sku: {
916
+ serializedName: "sku",
917
+ type: {
918
+ name: "Composite",
919
+ className: "Sku"
920
+ }
921
+ },
922
+ zones: {
923
+ serializedName: "zones",
924
+ type: {
925
+ name: "Sequence",
926
+ element: {
927
+ type: {
928
+ name: "String"
929
+ }
930
+ }
931
+ }
932
+ },
933
+ tags: {
934
+ serializedName: "tags",
935
+ type: {
936
+ name: "Dictionary",
937
+ value: { type: { name: "String" } }
938
+ }
939
+ }
940
+ }
941
+ }
942
+ };
943
+ const Sku = {
944
+ type: {
945
+ name: "Composite",
946
+ className: "Sku",
947
+ modelProperties: {
948
+ name: {
949
+ serializedName: "name",
950
+ type: {
951
+ name: "String"
952
+ }
953
+ }
954
+ }
955
+ }
956
+ };
957
+ const DedicatedHsmPatchParameters = {
958
+ type: {
959
+ name: "Composite",
960
+ className: "DedicatedHsmPatchParameters",
961
+ modelProperties: {
962
+ tags: {
963
+ serializedName: "tags",
964
+ type: {
965
+ name: "Dictionary",
966
+ value: { type: { name: "String" } }
967
+ }
968
+ }
969
+ }
970
+ }
971
+ };
972
+ const DedicatedHsmListResult = {
973
+ type: {
974
+ name: "Composite",
975
+ className: "DedicatedHsmListResult",
976
+ modelProperties: {
977
+ value: {
978
+ serializedName: "value",
979
+ type: {
980
+ name: "Sequence",
981
+ element: {
982
+ type: {
983
+ name: "Composite",
984
+ className: "DedicatedHsm"
985
+ }
986
+ }
987
+ }
988
+ },
989
+ nextLink: {
990
+ serializedName: "nextLink",
991
+ type: {
992
+ name: "String"
993
+ }
994
+ }
995
+ }
996
+ }
997
+ };
998
+ const OutboundEnvironmentEndpointCollection = {
999
+ type: {
1000
+ name: "Composite",
1001
+ className: "OutboundEnvironmentEndpointCollection",
1002
+ modelProperties: {
1003
+ value: {
1004
+ serializedName: "value",
1005
+ required: true,
1006
+ type: {
1007
+ name: "Sequence",
1008
+ element: {
1009
+ type: {
1010
+ name: "Composite",
1011
+ className: "OutboundEnvironmentEndpoint"
1012
+ }
1013
+ }
1014
+ }
1015
+ },
1016
+ nextLink: {
1017
+ serializedName: "nextLink",
1018
+ readOnly: true,
1019
+ type: {
1020
+ name: "String"
1021
+ }
1022
+ }
1023
+ }
1024
+ }
1025
+ };
1026
+ const OutboundEnvironmentEndpoint = {
1027
+ type: {
1028
+ name: "Composite",
1029
+ className: "OutboundEnvironmentEndpoint",
1030
+ modelProperties: {
1031
+ category: {
1032
+ serializedName: "category",
1033
+ type: {
1034
+ name: "String"
1035
+ }
1036
+ },
1037
+ endpoints: {
1038
+ serializedName: "endpoints",
1039
+ type: {
1040
+ name: "Sequence",
1041
+ element: {
1042
+ type: {
1043
+ name: "Composite",
1044
+ className: "EndpointDependency"
1045
+ }
1046
+ }
1047
+ }
1048
+ }
1049
+ }
1050
+ }
1051
+ };
1052
+ const EndpointDependency = {
1053
+ type: {
1054
+ name: "Composite",
1055
+ className: "EndpointDependency",
1056
+ modelProperties: {
1057
+ domainName: {
1058
+ serializedName: "domainName",
1059
+ type: {
1060
+ name: "String"
1061
+ }
1062
+ },
1063
+ endpointDetails: {
1064
+ serializedName: "endpointDetails",
1065
+ type: {
1066
+ name: "Sequence",
1067
+ element: {
1068
+ type: {
1069
+ name: "Composite",
1070
+ className: "EndpointDetail"
1071
+ }
1072
+ }
1073
+ }
1074
+ }
1075
+ }
1076
+ }
1077
+ };
1078
+ const EndpointDetail = {
1079
+ type: {
1080
+ name: "Composite",
1081
+ className: "EndpointDetail",
1082
+ modelProperties: {
1083
+ ipAddress: {
1084
+ serializedName: "ipAddress",
1085
+ type: {
1086
+ name: "String"
1087
+ }
1088
+ },
1089
+ port: {
1090
+ serializedName: "port",
1091
+ type: {
1092
+ name: "Number"
1093
+ }
1094
+ },
1095
+ protocol: {
1096
+ serializedName: "protocol",
1097
+ type: {
1098
+ name: "String"
1099
+ }
1100
+ },
1101
+ description: {
1102
+ serializedName: "description",
1103
+ type: {
1104
+ name: "String"
1105
+ }
1106
+ }
1107
+ }
1108
+ }
1109
+ };
1110
+ const ResourceListResult = {
1111
+ type: {
1112
+ name: "Composite",
1113
+ className: "ResourceListResult",
1114
+ modelProperties: {
1115
+ value: {
1116
+ serializedName: "value",
1117
+ type: {
1118
+ name: "Sequence",
1119
+ element: {
1120
+ type: {
1121
+ name: "Composite",
1122
+ className: "DedicatedHsmResource"
1123
+ }
1124
+ }
1125
+ }
1126
+ },
1127
+ nextLink: {
1128
+ serializedName: "nextLink",
1129
+ type: {
1130
+ name: "String"
1131
+ }
1132
+ }
1133
+ }
1134
+ }
1135
+ };
1136
+ const ProxyResource = {
1137
+ type: {
1138
+ name: "Composite",
1139
+ className: "ProxyResource",
1140
+ modelProperties: Object.assign({}, Resource.type.modelProperties)
1141
+ }
1142
+ };
1143
+ const TrackedResource = {
1144
+ type: {
1145
+ name: "Composite",
1146
+ className: "TrackedResource",
1147
+ modelProperties: Object.assign(Object.assign({}, Resource.type.modelProperties), { tags: {
1148
+ serializedName: "tags",
1149
+ type: {
1150
+ name: "Dictionary",
1151
+ value: { type: { name: "String" } }
1152
+ }
1153
+ }, location: {
1154
+ serializedName: "location",
1155
+ required: true,
1156
+ type: {
1157
+ name: "String"
1158
+ }
1159
+ } })
1160
+ }
1161
+ };
1162
+ const PrivateLinkResource = {
1163
+ type: {
1164
+ name: "Composite",
1165
+ className: "PrivateLinkResource",
1166
+ modelProperties: Object.assign(Object.assign({}, Resource.type.modelProperties), { groupId: {
1167
+ serializedName: "properties.groupId",
1168
+ readOnly: true,
1169
+ type: {
1170
+ name: "String"
1171
+ }
1172
+ }, requiredMembers: {
1173
+ serializedName: "properties.requiredMembers",
1174
+ readOnly: true,
1175
+ type: {
1176
+ name: "Sequence",
1177
+ element: {
1178
+ type: {
1179
+ name: "String"
1180
+ }
1181
+ }
1182
+ }
1183
+ }, requiredZoneNames: {
1184
+ serializedName: "properties.requiredZoneNames",
1185
+ type: {
1186
+ name: "Sequence",
1187
+ element: {
1188
+ type: {
1189
+ name: "String"
1190
+ }
1191
+ }
1192
+ }
1193
+ } })
1194
+ }
1195
+ };
1196
+ const DedicatedHsm = {
1197
+ type: {
1198
+ name: "Composite",
1199
+ className: "DedicatedHsm",
1200
+ modelProperties: Object.assign(Object.assign({}, DedicatedHsmResource.type.modelProperties), { systemData: {
1201
+ serializedName: "systemData",
1202
+ type: {
1203
+ name: "Composite",
1204
+ className: "SystemDataAutoGenerated"
1205
+ }
1206
+ }, networkProfile: {
1207
+ serializedName: "properties.networkProfile",
1208
+ type: {
1209
+ name: "Composite",
1210
+ className: "NetworkProfile"
1211
+ }
1212
+ }, managementNetworkProfile: {
1213
+ serializedName: "properties.managementNetworkProfile",
1214
+ type: {
1215
+ name: "Composite",
1216
+ className: "NetworkProfile"
1217
+ }
1218
+ }, stampId: {
1219
+ serializedName: "properties.stampId",
1220
+ type: {
1221
+ name: "String"
1222
+ }
1223
+ }, statusMessage: {
1224
+ serializedName: "properties.statusMessage",
1225
+ readOnly: true,
1226
+ type: {
1227
+ name: "String"
1228
+ }
1229
+ }, provisioningState: {
1230
+ serializedName: "properties.provisioningState",
1231
+ readOnly: true,
1232
+ type: {
1233
+ name: "String"
1234
+ }
1235
+ } })
1236
+ }
1237
+ };
1238
+ const PrivateEndpointConnection = {
1239
+ type: {
1240
+ name: "Composite",
1241
+ className: "PrivateEndpointConnection",
1242
+ modelProperties: Object.assign(Object.assign({}, ProxyResource.type.modelProperties), { etag: {
1243
+ serializedName: "etag",
1244
+ type: {
1245
+ name: "String"
1246
+ }
1247
+ }, privateEndpoint: {
1248
+ serializedName: "properties.privateEndpoint",
1249
+ type: {
1250
+ name: "Composite",
1251
+ className: "PrivateEndpoint"
1252
+ }
1253
+ }, privateLinkServiceConnectionState: {
1254
+ serializedName: "properties.privateLinkServiceConnectionState",
1255
+ type: {
1256
+ name: "Composite",
1257
+ className: "PrivateLinkServiceConnectionState"
1258
+ }
1259
+ }, provisioningState: {
1260
+ serializedName: "properties.provisioningState",
1261
+ readOnly: true,
1262
+ type: {
1263
+ name: "String"
1264
+ }
1265
+ }, groupIds: {
1266
+ serializedName: "properties.groupIds",
1267
+ readOnly: true,
1268
+ type: {
1269
+ name: "Sequence",
1270
+ element: {
1271
+ type: {
1272
+ name: "String"
1273
+ }
1274
+ }
1275
+ }
1276
+ } })
1277
+ }
1278
+ };
1279
+ const CloudHsmClusterResource = {
1280
+ type: {
1281
+ name: "Composite",
1282
+ className: "CloudHsmClusterResource",
1283
+ modelProperties: Object.assign(Object.assign({}, TrackedResource.type.modelProperties), { sku: {
1284
+ serializedName: "sku",
1285
+ type: {
1286
+ name: "Composite",
1287
+ className: "CloudHsmClusterSku"
1288
+ }
1289
+ }, identity: {
1290
+ serializedName: "identity",
1291
+ type: {
1292
+ name: "Composite",
1293
+ className: "ManagedServiceIdentity"
1294
+ }
1295
+ } })
1296
+ }
1297
+ };
1298
+ const CloudHsmCluster = {
1299
+ type: {
1300
+ name: "Composite",
1301
+ className: "CloudHsmCluster",
1302
+ modelProperties: Object.assign(Object.assign({}, CloudHsmClusterResource.type.modelProperties), { provisioningState: {
1303
+ serializedName: "properties.provisioningState",
1304
+ type: {
1305
+ name: "String"
1306
+ }
1307
+ }, autoGeneratedDomainNameLabelScope: {
1308
+ serializedName: "properties.autoGeneratedDomainNameLabelScope",
1309
+ type: {
1310
+ name: "String"
1311
+ }
1312
+ }, securityDomain: {
1313
+ serializedName: "properties.securityDomain",
1314
+ type: {
1315
+ name: "Composite",
1316
+ className: "CloudHsmClusterSecurityDomainProperties"
1317
+ }
1318
+ }, hsms: {
1319
+ serializedName: "properties.hsms",
1320
+ type: {
1321
+ name: "Sequence",
1322
+ element: {
1323
+ type: {
1324
+ name: "Composite",
1325
+ className: "CloudHsmProperties"
1326
+ }
1327
+ }
1328
+ }
1329
+ }, publicNetworkAccess: {
1330
+ serializedName: "properties.publicNetworkAccess",
1331
+ type: {
1332
+ name: "String"
1333
+ }
1334
+ }, privateEndpointConnections: {
1335
+ serializedName: "properties.privateEndpointConnections",
1336
+ type: {
1337
+ name: "Sequence",
1338
+ element: {
1339
+ type: {
1340
+ name: "Composite",
1341
+ className: "PrivateEndpointConnection"
1342
+ }
1343
+ }
1344
+ }
1345
+ }, statusMessage: {
1346
+ serializedName: "properties.statusMessage",
1347
+ readOnly: true,
1348
+ type: {
1349
+ name: "String"
1350
+ }
1351
+ }, restoreProperties: {
1352
+ serializedName: "properties.restoreProperties",
1353
+ type: {
1354
+ name: "Composite",
1355
+ className: "RestoreProperties"
1356
+ }
1357
+ }, backupProperties: {
1358
+ serializedName: "properties.backupProperties",
1359
+ type: {
1360
+ name: "Composite",
1361
+ className: "BackupProperties"
1362
+ }
1363
+ } })
1364
+ }
1365
+ };
1366
+ const CloudHsmClustersUpdateHeaders = {
1367
+ type: {
1368
+ name: "Composite",
1369
+ className: "CloudHsmClustersUpdateHeaders",
1370
+ modelProperties: {
1371
+ location: {
1372
+ serializedName: "location",
1373
+ type: {
1374
+ name: "String"
1375
+ }
1376
+ }
1377
+ }
1378
+ }
1379
+ };
1380
+ const CloudHsmClustersDeleteHeaders = {
1381
+ type: {
1382
+ name: "Composite",
1383
+ className: "CloudHsmClustersDeleteHeaders",
1384
+ modelProperties: {
1385
+ location: {
1386
+ serializedName: "location",
1387
+ type: {
1388
+ name: "String"
1389
+ }
1390
+ }
1391
+ }
1392
+ }
1393
+ };
1394
+ const CloudHsmClusterPrivateEndpointConnectionsDeleteHeaders = {
1395
+ type: {
1396
+ name: "Composite",
1397
+ className: "CloudHsmClusterPrivateEndpointConnectionsDeleteHeaders",
1398
+ modelProperties: {
1399
+ location: {
1400
+ serializedName: "location",
1401
+ type: {
1402
+ name: "String"
1403
+ }
1404
+ }
1405
+ }
1406
+ }
1407
+ };
1408
+
1409
+ var Mappers = /*#__PURE__*/Object.freeze({
1410
+ __proto__: null,
1411
+ ApiEntityReference: ApiEntityReference,
1412
+ BackupProperties: BackupProperties,
1413
+ CHsmError: CHsmError,
1414
+ CloudHsmCluster: CloudHsmCluster,
1415
+ CloudHsmClusterError: CloudHsmClusterError,
1416
+ CloudHsmClusterListResult: CloudHsmClusterListResult,
1417
+ CloudHsmClusterPatchParameters: CloudHsmClusterPatchParameters,
1418
+ CloudHsmClusterPrivateEndpointConnectionsDeleteHeaders: CloudHsmClusterPrivateEndpointConnectionsDeleteHeaders,
1419
+ CloudHsmClusterResource: CloudHsmClusterResource,
1420
+ CloudHsmClusterSecurityDomainProperties: CloudHsmClusterSecurityDomainProperties,
1421
+ CloudHsmClusterSku: CloudHsmClusterSku,
1422
+ CloudHsmClustersDeleteHeaders: CloudHsmClustersDeleteHeaders,
1423
+ CloudHsmClustersUpdateHeaders: CloudHsmClustersUpdateHeaders,
1424
+ CloudHsmProperties: CloudHsmProperties,
1425
+ DedicatedHsm: DedicatedHsm,
1426
+ DedicatedHsmError: DedicatedHsmError,
1427
+ DedicatedHsmListResult: DedicatedHsmListResult,
1428
+ DedicatedHsmOperation: DedicatedHsmOperation,
1429
+ DedicatedHsmOperationDisplay: DedicatedHsmOperationDisplay,
1430
+ DedicatedHsmOperationListResult: DedicatedHsmOperationListResult,
1431
+ DedicatedHsmPatchParameters: DedicatedHsmPatchParameters,
1432
+ DedicatedHsmResource: DedicatedHsmResource,
1433
+ EndpointDependency: EndpointDependency,
1434
+ EndpointDetail: EndpointDetail,
1435
+ ErrorModel: ErrorModel,
1436
+ ManagedServiceIdentity: ManagedServiceIdentity,
1437
+ NetworkInterface: NetworkInterface,
1438
+ NetworkProfile: NetworkProfile,
1439
+ OutboundEnvironmentEndpoint: OutboundEnvironmentEndpoint,
1440
+ OutboundEnvironmentEndpointCollection: OutboundEnvironmentEndpointCollection,
1441
+ PrivateEndpoint: PrivateEndpoint,
1442
+ PrivateEndpointConnection: PrivateEndpointConnection,
1443
+ PrivateEndpointConnectionListResult: PrivateEndpointConnectionListResult,
1444
+ PrivateLinkResource: PrivateLinkResource,
1445
+ PrivateLinkResourceListResult: PrivateLinkResourceListResult,
1446
+ PrivateLinkServiceConnectionState: PrivateLinkServiceConnectionState,
1447
+ ProxyResource: ProxyResource,
1448
+ Resource: Resource,
1449
+ ResourceListResult: ResourceListResult,
1450
+ RestoreProperties: RestoreProperties,
1451
+ Sku: Sku,
1452
+ SystemData: SystemData,
1453
+ SystemDataAutoGenerated: SystemDataAutoGenerated,
1454
+ TrackedResource: TrackedResource,
1455
+ UserAssignedIdentity: UserAssignedIdentity
1456
+ });
1457
+
1458
+ /*
1459
+ * Copyright (c) Microsoft Corporation.
1460
+ * Licensed under the MIT License.
1461
+ *
1462
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1463
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1464
+ */
1465
+ const contentType = {
1466
+ parameterPath: ["options", "contentType"],
1467
+ mapper: {
1468
+ defaultValue: "application/json",
1469
+ isConstant: true,
1470
+ serializedName: "Content-Type",
1471
+ type: {
1472
+ name: "String"
1473
+ }
1474
+ }
1475
+ };
1476
+ const accept = {
1477
+ parameterPath: "accept",
1478
+ mapper: {
1479
+ defaultValue: "application/json",
1480
+ isConstant: true,
1481
+ serializedName: "Accept",
1482
+ type: {
1483
+ name: "String"
1484
+ }
1485
+ }
1486
+ };
1487
+ const $host = {
1488
+ parameterPath: "$host",
1489
+ mapper: {
1490
+ serializedName: "$host",
1491
+ required: true,
1492
+ type: {
1493
+ name: "String"
1494
+ }
1495
+ },
1496
+ skipEncoding: true
1497
+ };
1498
+ const subscriptionId = {
1499
+ parameterPath: "subscriptionId",
1500
+ mapper: {
1501
+ serializedName: "subscriptionId",
1502
+ required: true,
1503
+ type: {
1504
+ name: "Uuid"
1505
+ }
1506
+ }
1507
+ };
1508
+ const resourceGroupName = {
1509
+ parameterPath: "resourceGroupName",
1510
+ mapper: {
1511
+ constraints: {
1512
+ MaxLength: 90,
1513
+ MinLength: 1
1514
+ },
1515
+ serializedName: "resourceGroupName",
1516
+ required: true,
1517
+ type: {
1518
+ name: "String"
1519
+ }
1520
+ }
1521
+ };
1522
+ const cloudHsmClusterName = {
1523
+ parameterPath: "cloudHsmClusterName",
1524
+ mapper: {
1525
+ constraints: {
1526
+ Pattern: new RegExp("^[a-zA-Z0-9-]{3,24}$"),
1527
+ MaxLength: 24,
1528
+ MinLength: 3
1529
+ },
1530
+ serializedName: "cloudHsmClusterName",
1531
+ required: true,
1532
+ type: {
1533
+ name: "String"
1534
+ }
1535
+ }
1536
+ };
1537
+ const apiVersion = {
1538
+ parameterPath: "apiVersion",
1539
+ mapper: {
1540
+ defaultValue: "2023-12-10-preview",
1541
+ isConstant: true,
1542
+ serializedName: "api-version",
1543
+ type: {
1544
+ name: "String"
1545
+ }
1546
+ }
1547
+ };
1548
+ const skiptoken = {
1549
+ parameterPath: ["options", "skiptoken"],
1550
+ mapper: {
1551
+ serializedName: "$skiptoken",
1552
+ type: {
1553
+ name: "String"
1554
+ }
1555
+ }
1556
+ };
1557
+ const nextLink = {
1558
+ parameterPath: "nextLink",
1559
+ mapper: {
1560
+ serializedName: "nextLink",
1561
+ required: true,
1562
+ type: {
1563
+ name: "String"
1564
+ }
1565
+ },
1566
+ skipEncoding: true
1567
+ };
1568
+ const properties = {
1569
+ parameterPath: "properties",
1570
+ mapper: PrivateEndpointConnection
1571
+ };
1572
+ const peConnectionName = {
1573
+ parameterPath: "peConnectionName",
1574
+ mapper: {
1575
+ constraints: {
1576
+ Pattern: new RegExp("^[a-zA-Z0-9-]{3,24}$"),
1577
+ MaxLength: 24,
1578
+ MinLength: 3
1579
+ },
1580
+ serializedName: "peConnectionName",
1581
+ required: true,
1582
+ type: {
1583
+ name: "String"
1584
+ }
1585
+ }
1586
+ };
1587
+ const apiVersion1 = {
1588
+ parameterPath: "apiVersion",
1589
+ mapper: {
1590
+ defaultValue: "2021-11-30",
1591
+ isConstant: true,
1592
+ serializedName: "api-version",
1593
+ type: {
1594
+ name: "String"
1595
+ }
1596
+ }
1597
+ };
1598
+ const parameters = {
1599
+ parameterPath: "parameters",
1600
+ mapper: DedicatedHsm
1601
+ };
1602
+ const resourceGroupName1 = {
1603
+ parameterPath: "resourceGroupName",
1604
+ mapper: {
1605
+ serializedName: "resourceGroupName",
1606
+ required: true,
1607
+ type: {
1608
+ name: "String"
1609
+ }
1610
+ }
1611
+ };
1612
+ const name = {
1613
+ parameterPath: "name",
1614
+ mapper: {
1615
+ constraints: {
1616
+ Pattern: new RegExp("^[a-zA-Z0-9-]{3,24}$")
1617
+ },
1618
+ serializedName: "name",
1619
+ required: true,
1620
+ type: {
1621
+ name: "String"
1622
+ }
1623
+ }
1624
+ };
1625
+ const name1 = {
1626
+ parameterPath: "name",
1627
+ mapper: {
1628
+ serializedName: "name",
1629
+ required: true,
1630
+ type: {
1631
+ name: "String"
1632
+ }
1633
+ }
1634
+ };
1635
+ const top = {
1636
+ parameterPath: ["options", "top"],
1637
+ mapper: {
1638
+ serializedName: "$top",
1639
+ type: {
1640
+ name: "Number"
1641
+ }
1642
+ }
1643
+ };
1644
+
1645
+ /*
1646
+ * Copyright (c) Microsoft Corporation.
1647
+ * Licensed under the MIT License.
1648
+ *
1649
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1650
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1651
+ */
1652
+ function createLroSpec(inputs) {
1653
+ const { args, spec, sendOperationFn } = inputs;
1654
+ return {
1655
+ requestMethod: spec.httpMethod,
1656
+ requestPath: spec.path,
1657
+ sendInitialRequest: () => sendOperationFn(args, spec),
1658
+ sendPollRequest: (path, options) => {
1659
+ const restSpec = tslib.__rest(spec, ["requestBody"]);
1660
+ return sendOperationFn(args, Object.assign(Object.assign({}, restSpec), { httpMethod: "GET", path, abortSignal: options === null || options === void 0 ? void 0 : options.abortSignal }));
1661
+ }
1662
+ };
1663
+ }
1664
+
1665
+ /*
1666
+ * Copyright (c) Microsoft Corporation.
1667
+ * Licensed under the MIT License.
1668
+ *
1669
+ * Code generated by Microsoft (R) AutoRest Code Generator.
1670
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1671
+ */
1672
+ /// <reference lib="esnext.asynciterable" />
1673
+ /** Class containing CloudHsmClusters operations. */
1674
+ class CloudHsmClustersImpl {
1675
+ /**
1676
+ * Initialize a new instance of the class CloudHsmClusters class.
1677
+ * @param client Reference to the service client
1678
+ */
1679
+ constructor(client) {
1680
+ this.client = client;
1681
+ }
1682
+ /**
1683
+ * The List operation gets information about the Cloud HSM Clusters associated with the subscription
1684
+ * and within the specified resource group.
1685
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1686
+ * @param options The options parameters.
1687
+ */
1688
+ listByResourceGroup(resourceGroupName, options) {
1689
+ const iter = this.listByResourceGroupPagingAll(resourceGroupName, options);
1690
+ return {
1691
+ next() {
1692
+ return iter.next();
1693
+ },
1694
+ [Symbol.asyncIterator]() {
1695
+ return this;
1696
+ },
1697
+ byPage: (settings) => {
1698
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
1699
+ throw new Error("maxPageSize is not supported by this operation.");
1700
+ }
1701
+ return this.listByResourceGroupPagingPage(resourceGroupName, options, settings);
1702
+ }
1703
+ };
1704
+ }
1705
+ listByResourceGroupPagingPage(resourceGroupName, options, settings) {
1706
+ return tslib.__asyncGenerator(this, arguments, function* listByResourceGroupPagingPage_1() {
1707
+ let result;
1708
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
1709
+ if (!continuationToken) {
1710
+ result = yield tslib.__await(this._listByResourceGroup(resourceGroupName, options));
1711
+ let page = result.value || [];
1712
+ continuationToken = result.nextLink;
1713
+ setContinuationToken(page, continuationToken);
1714
+ yield yield tslib.__await(page);
1715
+ }
1716
+ while (continuationToken) {
1717
+ result = yield tslib.__await(this._listByResourceGroupNext(resourceGroupName, continuationToken, options));
1718
+ continuationToken = result.nextLink;
1719
+ let page = result.value || [];
1720
+ setContinuationToken(page, continuationToken);
1721
+ yield yield tslib.__await(page);
1722
+ }
1723
+ });
1724
+ }
1725
+ listByResourceGroupPagingAll(resourceGroupName, options) {
1726
+ return tslib.__asyncGenerator(this, arguments, function* listByResourceGroupPagingAll_1() {
1727
+ var _a, e_1, _b, _c;
1728
+ try {
1729
+ for (var _d = true, _e = tslib.__asyncValues(this.listByResourceGroupPagingPage(resourceGroupName, options)), _f; _f = yield tslib.__await(_e.next()), _a = _f.done, !_a; _d = true) {
1730
+ _c = _f.value;
1731
+ _d = false;
1732
+ const page = _c;
1733
+ yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(page)));
1734
+ }
1735
+ }
1736
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
1737
+ finally {
1738
+ try {
1739
+ if (!_d && !_a && (_b = _e.return)) yield tslib.__await(_b.call(_e));
1740
+ }
1741
+ finally { if (e_1) throw e_1.error; }
1742
+ }
1743
+ });
1744
+ }
1745
+ /**
1746
+ * The List operation gets information about the Cloud HSM Clusters associated with the subscription.
1747
+ * @param options The options parameters.
1748
+ */
1749
+ listBySubscription(options) {
1750
+ const iter = this.listBySubscriptionPagingAll(options);
1751
+ return {
1752
+ next() {
1753
+ return iter.next();
1754
+ },
1755
+ [Symbol.asyncIterator]() {
1756
+ return this;
1757
+ },
1758
+ byPage: (settings) => {
1759
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
1760
+ throw new Error("maxPageSize is not supported by this operation.");
1761
+ }
1762
+ return this.listBySubscriptionPagingPage(options, settings);
1763
+ }
1764
+ };
1765
+ }
1766
+ listBySubscriptionPagingPage(options, settings) {
1767
+ return tslib.__asyncGenerator(this, arguments, function* listBySubscriptionPagingPage_1() {
1768
+ let result;
1769
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
1770
+ if (!continuationToken) {
1771
+ result = yield tslib.__await(this._listBySubscription(options));
1772
+ let page = result.value || [];
1773
+ continuationToken = result.nextLink;
1774
+ setContinuationToken(page, continuationToken);
1775
+ yield yield tslib.__await(page);
1776
+ }
1777
+ while (continuationToken) {
1778
+ result = yield tslib.__await(this._listBySubscriptionNext(continuationToken, options));
1779
+ continuationToken = result.nextLink;
1780
+ let page = result.value || [];
1781
+ setContinuationToken(page, continuationToken);
1782
+ yield yield tslib.__await(page);
1783
+ }
1784
+ });
1785
+ }
1786
+ listBySubscriptionPagingAll(options) {
1787
+ return tslib.__asyncGenerator(this, arguments, function* listBySubscriptionPagingAll_1() {
1788
+ var _a, e_2, _b, _c;
1789
+ try {
1790
+ for (var _d = true, _e = tslib.__asyncValues(this.listBySubscriptionPagingPage(options)), _f; _f = yield tslib.__await(_e.next()), _a = _f.done, !_a; _d = true) {
1791
+ _c = _f.value;
1792
+ _d = false;
1793
+ const page = _c;
1794
+ yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(page)));
1795
+ }
1796
+ }
1797
+ catch (e_2_1) { e_2 = { error: e_2_1 }; }
1798
+ finally {
1799
+ try {
1800
+ if (!_d && !_a && (_b = _e.return)) yield tslib.__await(_b.call(_e));
1801
+ }
1802
+ finally { if (e_2) throw e_2.error; }
1803
+ }
1804
+ });
1805
+ }
1806
+ /**
1807
+ * Create or Update a Cloud HSM Cluster in the specified subscription.
1808
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1809
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1810
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1811
+ * @param location The geo-location where the resource lives
1812
+ * @param options The options parameters.
1813
+ */
1814
+ beginCreateOrUpdate(resourceGroupName, cloudHsmClusterName, location, options) {
1815
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1816
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1817
+ return this.client.sendOperationRequest(args, spec);
1818
+ });
1819
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1820
+ var _a;
1821
+ let currentRawResponse = undefined;
1822
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
1823
+ const callback = (rawResponse, flatResponse) => {
1824
+ currentRawResponse = rawResponse;
1825
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
1826
+ };
1827
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
1828
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
1829
+ return {
1830
+ flatResponse,
1831
+ rawResponse: {
1832
+ statusCode: currentRawResponse.status,
1833
+ body: currentRawResponse.parsedBody,
1834
+ headers: currentRawResponse.headers.toJSON()
1835
+ }
1836
+ };
1837
+ });
1838
+ const lro = createLroSpec({
1839
+ sendOperationFn,
1840
+ args: { resourceGroupName, cloudHsmClusterName, location, options },
1841
+ spec: createOrUpdateOperationSpec$1
1842
+ });
1843
+ const poller = yield coreLro.createHttpPoller(lro, {
1844
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1845
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
1846
+ resourceLocationConfig: "original-uri"
1847
+ });
1848
+ yield poller.poll();
1849
+ return poller;
1850
+ });
1851
+ }
1852
+ /**
1853
+ * Create or Update a Cloud HSM Cluster in the specified subscription.
1854
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1855
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1856
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1857
+ * @param location The geo-location where the resource lives
1858
+ * @param options The options parameters.
1859
+ */
1860
+ beginCreateOrUpdateAndWait(resourceGroupName, cloudHsmClusterName, location, options) {
1861
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1862
+ const poller = yield this.beginCreateOrUpdate(resourceGroupName, cloudHsmClusterName, location, options);
1863
+ return poller.pollUntilDone();
1864
+ });
1865
+ }
1866
+ /**
1867
+ * Update a Cloud HSM Cluster in the specified subscription.
1868
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1869
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1870
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1871
+ * @param options The options parameters.
1872
+ */
1873
+ beginUpdate(resourceGroupName, cloudHsmClusterName, options) {
1874
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1875
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1876
+ return this.client.sendOperationRequest(args, spec);
1877
+ });
1878
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1879
+ var _a;
1880
+ let currentRawResponse = undefined;
1881
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
1882
+ const callback = (rawResponse, flatResponse) => {
1883
+ currentRawResponse = rawResponse;
1884
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
1885
+ };
1886
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
1887
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
1888
+ return {
1889
+ flatResponse,
1890
+ rawResponse: {
1891
+ statusCode: currentRawResponse.status,
1892
+ body: currentRawResponse.parsedBody,
1893
+ headers: currentRawResponse.headers.toJSON()
1894
+ }
1895
+ };
1896
+ });
1897
+ const lro = createLroSpec({
1898
+ sendOperationFn,
1899
+ args: { resourceGroupName, cloudHsmClusterName, options },
1900
+ spec: updateOperationSpec$1
1901
+ });
1902
+ const poller = yield coreLro.createHttpPoller(lro, {
1903
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1904
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
1905
+ resourceLocationConfig: "location"
1906
+ });
1907
+ yield poller.poll();
1908
+ return poller;
1909
+ });
1910
+ }
1911
+ /**
1912
+ * Update a Cloud HSM Cluster in the specified subscription.
1913
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1914
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1915
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1916
+ * @param options The options parameters.
1917
+ */
1918
+ beginUpdateAndWait(resourceGroupName, cloudHsmClusterName, options) {
1919
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1920
+ const poller = yield this.beginUpdate(resourceGroupName, cloudHsmClusterName, options);
1921
+ return poller.pollUntilDone();
1922
+ });
1923
+ }
1924
+ /**
1925
+ * Gets the specified Cloud HSM Cluster
1926
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1927
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1928
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1929
+ * @param options The options parameters.
1930
+ */
1931
+ get(resourceGroupName, cloudHsmClusterName, options) {
1932
+ return this.client.sendOperationRequest({ resourceGroupName, cloudHsmClusterName, options }, getOperationSpec$2);
1933
+ }
1934
+ /**
1935
+ * Deletes the specified Cloud HSM Cluster
1936
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1937
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1938
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1939
+ * @param options The options parameters.
1940
+ */
1941
+ beginDelete(resourceGroupName, cloudHsmClusterName, options) {
1942
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1943
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1944
+ return this.client.sendOperationRequest(args, spec);
1945
+ });
1946
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1947
+ var _a;
1948
+ let currentRawResponse = undefined;
1949
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
1950
+ const callback = (rawResponse, flatResponse) => {
1951
+ currentRawResponse = rawResponse;
1952
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
1953
+ };
1954
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
1955
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
1956
+ return {
1957
+ flatResponse,
1958
+ rawResponse: {
1959
+ statusCode: currentRawResponse.status,
1960
+ body: currentRawResponse.parsedBody,
1961
+ headers: currentRawResponse.headers.toJSON()
1962
+ }
1963
+ };
1964
+ });
1965
+ const lro = createLroSpec({
1966
+ sendOperationFn,
1967
+ args: { resourceGroupName, cloudHsmClusterName, options },
1968
+ spec: deleteOperationSpec$2
1969
+ });
1970
+ const poller = yield coreLro.createHttpPoller(lro, {
1971
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1972
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
1973
+ resourceLocationConfig: "location"
1974
+ });
1975
+ yield poller.poll();
1976
+ return poller;
1977
+ });
1978
+ }
1979
+ /**
1980
+ * Deletes the specified Cloud HSM Cluster
1981
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1982
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
1983
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
1984
+ * @param options The options parameters.
1985
+ */
1986
+ beginDeleteAndWait(resourceGroupName, cloudHsmClusterName, options) {
1987
+ return tslib.__awaiter(this, void 0, void 0, function* () {
1988
+ const poller = yield this.beginDelete(resourceGroupName, cloudHsmClusterName, options);
1989
+ return poller.pollUntilDone();
1990
+ });
1991
+ }
1992
+ /**
1993
+ * The List operation gets information about the Cloud HSM Clusters associated with the subscription
1994
+ * and within the specified resource group.
1995
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
1996
+ * @param options The options parameters.
1997
+ */
1998
+ _listByResourceGroup(resourceGroupName, options) {
1999
+ return this.client.sendOperationRequest({ resourceGroupName, options }, listByResourceGroupOperationSpec$1);
2000
+ }
2001
+ /**
2002
+ * The List operation gets information about the Cloud HSM Clusters associated with the subscription.
2003
+ * @param options The options parameters.
2004
+ */
2005
+ _listBySubscription(options) {
2006
+ return this.client.sendOperationRequest({ options }, listBySubscriptionOperationSpec$1);
2007
+ }
2008
+ /**
2009
+ * ListByResourceGroupNext
2010
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2011
+ * @param nextLink The nextLink from the previous successful call to the ListByResourceGroup method.
2012
+ * @param options The options parameters.
2013
+ */
2014
+ _listByResourceGroupNext(resourceGroupName, nextLink, options) {
2015
+ return this.client.sendOperationRequest({ resourceGroupName, nextLink, options }, listByResourceGroupNextOperationSpec$1);
2016
+ }
2017
+ /**
2018
+ * ListBySubscriptionNext
2019
+ * @param nextLink The nextLink from the previous successful call to the ListBySubscription method.
2020
+ * @param options The options parameters.
2021
+ */
2022
+ _listBySubscriptionNext(nextLink, options) {
2023
+ return this.client.sendOperationRequest({ nextLink, options }, listBySubscriptionNextOperationSpec$1);
2024
+ }
2025
+ }
2026
+ // Operation Specifications
2027
+ const serializer$5 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2028
+ const createOrUpdateOperationSpec$1 = {
2029
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
2030
+ httpMethod: "PUT",
2031
+ responses: {
2032
+ 200: {
2033
+ bodyMapper: CloudHsmCluster
2034
+ },
2035
+ 201: {
2036
+ bodyMapper: CloudHsmCluster
2037
+ },
2038
+ 202: {
2039
+ bodyMapper: CloudHsmCluster
2040
+ },
2041
+ 204: {
2042
+ bodyMapper: CloudHsmCluster
2043
+ },
2044
+ default: {
2045
+ bodyMapper: CloudHsmClusterError
2046
+ }
2047
+ },
2048
+ requestBody: {
2049
+ parameterPath: {
2050
+ tags: ["options", "tags"],
2051
+ location: ["location"],
2052
+ sku: ["options", "sku"],
2053
+ identity: ["options", "identity"],
2054
+ provisioningState: ["options", "provisioningState"],
2055
+ autoGeneratedDomainNameLabelScope: [
2056
+ "options",
2057
+ "autoGeneratedDomainNameLabelScope"
2058
+ ],
2059
+ securityDomain: ["options", "securityDomain"],
2060
+ hsms: ["options", "hsms"],
2061
+ publicNetworkAccess: ["options", "publicNetworkAccess"],
2062
+ privateEndpointConnections: ["options", "privateEndpointConnections"],
2063
+ restoreProperties: ["options", "restoreProperties"],
2064
+ backupProperties: ["options", "backupProperties"]
2065
+ },
2066
+ mapper: Object.assign(Object.assign({}, CloudHsmCluster), { required: true })
2067
+ },
2068
+ queryParameters: [apiVersion],
2069
+ urlParameters: [
2070
+ $host,
2071
+ subscriptionId,
2072
+ resourceGroupName,
2073
+ cloudHsmClusterName
2074
+ ],
2075
+ headerParameters: [contentType, accept],
2076
+ mediaType: "json",
2077
+ serializer: serializer$5
2078
+ };
2079
+ const updateOperationSpec$1 = {
2080
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
2081
+ httpMethod: "PATCH",
2082
+ responses: {
2083
+ 200: {
2084
+ bodyMapper: CloudHsmCluster
2085
+ },
2086
+ 201: {
2087
+ bodyMapper: CloudHsmCluster
2088
+ },
2089
+ 202: {
2090
+ bodyMapper: CloudHsmCluster
2091
+ },
2092
+ 204: {
2093
+ bodyMapper: CloudHsmCluster
2094
+ },
2095
+ default: {
2096
+ bodyMapper: CloudHsmClusterError
2097
+ }
2098
+ },
2099
+ requestBody: {
2100
+ parameterPath: {
2101
+ tags: ["options", "tags"],
2102
+ sku: ["options", "sku"],
2103
+ identity: ["options", "identity"],
2104
+ backupProperties: ["options", "backupProperties"]
2105
+ },
2106
+ mapper: Object.assign(Object.assign({}, CloudHsmClusterPatchParameters), { required: true })
2107
+ },
2108
+ queryParameters: [apiVersion],
2109
+ urlParameters: [
2110
+ $host,
2111
+ subscriptionId,
2112
+ resourceGroupName,
2113
+ cloudHsmClusterName
2114
+ ],
2115
+ headerParameters: [contentType, accept],
2116
+ mediaType: "json",
2117
+ serializer: serializer$5
2118
+ };
2119
+ const getOperationSpec$2 = {
2120
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
2121
+ httpMethod: "GET",
2122
+ responses: {
2123
+ 200: {
2124
+ bodyMapper: CloudHsmCluster
2125
+ },
2126
+ default: {
2127
+ bodyMapper: CloudHsmClusterError
2128
+ }
2129
+ },
2130
+ queryParameters: [apiVersion],
2131
+ urlParameters: [
2132
+ $host,
2133
+ subscriptionId,
2134
+ resourceGroupName,
2135
+ cloudHsmClusterName
2136
+ ],
2137
+ headerParameters: [accept],
2138
+ serializer: serializer$5
2139
+ };
2140
+ const deleteOperationSpec$2 = {
2141
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
2142
+ httpMethod: "DELETE",
2143
+ responses: {
2144
+ 200: {},
2145
+ 201: {},
2146
+ 202: {},
2147
+ 204: {},
2148
+ default: {
2149
+ bodyMapper: CloudHsmClusterError
2150
+ }
2151
+ },
2152
+ queryParameters: [apiVersion],
2153
+ urlParameters: [
2154
+ $host,
2155
+ subscriptionId,
2156
+ resourceGroupName,
2157
+ cloudHsmClusterName
2158
+ ],
2159
+ headerParameters: [accept],
2160
+ serializer: serializer$5
2161
+ };
2162
+ const listByResourceGroupOperationSpec$1 = {
2163
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters",
2164
+ httpMethod: "GET",
2165
+ responses: {
2166
+ 200: {
2167
+ bodyMapper: CloudHsmClusterListResult
2168
+ },
2169
+ default: {
2170
+ bodyMapper: CloudHsmClusterError
2171
+ }
2172
+ },
2173
+ queryParameters: [apiVersion, skiptoken],
2174
+ urlParameters: [
2175
+ $host,
2176
+ subscriptionId,
2177
+ resourceGroupName
2178
+ ],
2179
+ headerParameters: [accept],
2180
+ serializer: serializer$5
2181
+ };
2182
+ const listBySubscriptionOperationSpec$1 = {
2183
+ path: "/subscriptions/{subscriptionId}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters",
2184
+ httpMethod: "GET",
2185
+ responses: {
2186
+ 200: {
2187
+ bodyMapper: CloudHsmClusterListResult
2188
+ },
2189
+ default: {
2190
+ bodyMapper: CloudHsmClusterError
2191
+ }
2192
+ },
2193
+ queryParameters: [apiVersion, skiptoken],
2194
+ urlParameters: [$host, subscriptionId],
2195
+ headerParameters: [accept],
2196
+ serializer: serializer$5
2197
+ };
2198
+ const listByResourceGroupNextOperationSpec$1 = {
2199
+ path: "{nextLink}",
2200
+ httpMethod: "GET",
2201
+ responses: {
2202
+ 200: {
2203
+ bodyMapper: CloudHsmClusterListResult
2204
+ },
2205
+ default: {
2206
+ bodyMapper: CloudHsmClusterError
2207
+ }
2208
+ },
2209
+ urlParameters: [
2210
+ $host,
2211
+ subscriptionId,
2212
+ resourceGroupName,
2213
+ nextLink
2214
+ ],
2215
+ headerParameters: [accept],
2216
+ serializer: serializer$5
2217
+ };
2218
+ const listBySubscriptionNextOperationSpec$1 = {
2219
+ path: "{nextLink}",
2220
+ httpMethod: "GET",
2221
+ responses: {
2222
+ 200: {
2223
+ bodyMapper: CloudHsmClusterListResult
2224
+ },
2225
+ default: {
2226
+ bodyMapper: CloudHsmClusterError
2227
+ }
2228
+ },
2229
+ urlParameters: [
2230
+ $host,
2231
+ subscriptionId,
2232
+ nextLink
2233
+ ],
2234
+ headerParameters: [accept],
2235
+ serializer: serializer$5
2236
+ };
2237
+
2238
+ /*
2239
+ * Copyright (c) Microsoft Corporation.
2240
+ * Licensed under the MIT License.
2241
+ *
2242
+ * Code generated by Microsoft (R) AutoRest Code Generator.
2243
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
2244
+ */
2245
+ /** Class containing CloudHsmClusterPrivateLinkResources operations. */
2246
+ class CloudHsmClusterPrivateLinkResourcesImpl {
2247
+ /**
2248
+ * Initialize a new instance of the class CloudHsmClusterPrivateLinkResources class.
2249
+ * @param client Reference to the service client
2250
+ */
2251
+ constructor(client) {
2252
+ this.client = client;
2253
+ }
2254
+ /**
2255
+ * Gets the private link resources supported for the Cloud Hsm Cluster.
2256
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2257
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2258
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2259
+ * @param options The options parameters.
2260
+ */
2261
+ listByCloudHsmCluster(resourceGroupName, cloudHsmClusterName, options) {
2262
+ return this.client.sendOperationRequest({ resourceGroupName, cloudHsmClusterName, options }, listByCloudHsmClusterOperationSpec$1);
2263
+ }
2264
+ }
2265
+ // Operation Specifications
2266
+ const serializer$4 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2267
+ const listByCloudHsmClusterOperationSpec$1 = {
2268
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/privateLinkResources",
2269
+ httpMethod: "GET",
2270
+ responses: {
2271
+ 200: {
2272
+ bodyMapper: PrivateLinkResourceListResult
2273
+ },
2274
+ default: {
2275
+ bodyMapper: CloudHsmClusterError
2276
+ }
2277
+ },
2278
+ queryParameters: [apiVersion],
2279
+ urlParameters: [
2280
+ $host,
2281
+ subscriptionId,
2282
+ resourceGroupName,
2283
+ cloudHsmClusterName
2284
+ ],
2285
+ headerParameters: [accept],
2286
+ serializer: serializer$4
2287
+ };
2288
+
2289
+ /*
2290
+ * Copyright (c) Microsoft Corporation.
2291
+ * Licensed under the MIT License.
2292
+ *
2293
+ * Code generated by Microsoft (R) AutoRest Code Generator.
2294
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
2295
+ */
2296
+ /** Class containing CloudHsmClusterPrivateEndpointConnections operations. */
2297
+ class CloudHsmClusterPrivateEndpointConnectionsImpl {
2298
+ /**
2299
+ * Initialize a new instance of the class CloudHsmClusterPrivateEndpointConnections class.
2300
+ * @param client Reference to the service client
2301
+ */
2302
+ constructor(client) {
2303
+ this.client = client;
2304
+ }
2305
+ /**
2306
+ * Creates or updates the private endpoint connection for the Cloud Hsm Cluster.
2307
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2308
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2309
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2310
+ * @param peConnectionName Name of the private endpoint connection associated with the Cloud HSM
2311
+ * Cluster.
2312
+ * @param properties Parameters of the PrivateEndpointConnection
2313
+ * @param options The options parameters.
2314
+ */
2315
+ create(resourceGroupName, cloudHsmClusterName, peConnectionName, properties, options) {
2316
+ return this.client.sendOperationRequest({
2317
+ resourceGroupName,
2318
+ cloudHsmClusterName,
2319
+ peConnectionName,
2320
+ properties,
2321
+ options
2322
+ }, createOperationSpec);
2323
+ }
2324
+ /**
2325
+ * Deletes the private endpoint connection for the Cloud Hsm Cluster.
2326
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2327
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2328
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2329
+ * @param peConnectionName Name of the private endpoint connection associated with the Cloud HSM
2330
+ * Cluster.
2331
+ * @param options The options parameters.
2332
+ */
2333
+ beginDelete(resourceGroupName, cloudHsmClusterName, peConnectionName, options) {
2334
+ return tslib.__awaiter(this, void 0, void 0, function* () {
2335
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2336
+ return this.client.sendOperationRequest(args, spec);
2337
+ });
2338
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2339
+ var _a;
2340
+ let currentRawResponse = undefined;
2341
+ const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
2342
+ const callback = (rawResponse, flatResponse) => {
2343
+ currentRawResponse = rawResponse;
2344
+ providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
2345
+ };
2346
+ const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
2347
+ const flatResponse = yield directSendOperation(updatedArgs, spec);
2348
+ return {
2349
+ flatResponse,
2350
+ rawResponse: {
2351
+ statusCode: currentRawResponse.status,
2352
+ body: currentRawResponse.parsedBody,
2353
+ headers: currentRawResponse.headers.toJSON()
2354
+ }
2355
+ };
2356
+ });
2357
+ const lro = createLroSpec({
2358
+ sendOperationFn,
2359
+ args: {
2360
+ resourceGroupName,
2361
+ cloudHsmClusterName,
2362
+ peConnectionName,
2363
+ options
2364
+ },
2365
+ spec: deleteOperationSpec$1
2366
+ });
2367
+ const poller = yield coreLro.createHttpPoller(lro, {
2368
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2369
+ intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
2370
+ resourceLocationConfig: "location"
2371
+ });
2372
+ yield poller.poll();
2373
+ return poller;
2374
+ });
2375
+ }
2376
+ /**
2377
+ * Deletes the private endpoint connection for the Cloud Hsm Cluster.
2378
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2379
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2380
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2381
+ * @param peConnectionName Name of the private endpoint connection associated with the Cloud HSM
2382
+ * Cluster.
2383
+ * @param options The options parameters.
2384
+ */
2385
+ beginDeleteAndWait(resourceGroupName, cloudHsmClusterName, peConnectionName, options) {
2386
+ return tslib.__awaiter(this, void 0, void 0, function* () {
2387
+ const poller = yield this.beginDelete(resourceGroupName, cloudHsmClusterName, peConnectionName, options);
2388
+ return poller.pollUntilDone();
2389
+ });
2390
+ }
2391
+ /**
2392
+ * Gets the private endpoint connection for the Cloud Hsm Cluster.
2393
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2394
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2395
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2396
+ * @param peConnectionName Name of the private endpoint connection associated with the Cloud HSM
2397
+ * Cluster.
2398
+ * @param options The options parameters.
2399
+ */
2400
+ get(resourceGroupName, cloudHsmClusterName, peConnectionName, options) {
2401
+ return this.client.sendOperationRequest({ resourceGroupName, cloudHsmClusterName, peConnectionName, options }, getOperationSpec$1);
2402
+ }
2403
+ }
2404
+ // Operation Specifications
2405
+ const serializer$3 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2406
+ const createOperationSpec = {
2407
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/privateEndpointConnections/{peConnectionName}",
2408
+ httpMethod: "PUT",
2409
+ responses: {
2410
+ 200: {
2411
+ bodyMapper: PrivateEndpointConnection
2412
+ },
2413
+ default: {
2414
+ bodyMapper: CloudHsmClusterError
2415
+ }
2416
+ },
2417
+ requestBody: properties,
2418
+ queryParameters: [apiVersion],
2419
+ urlParameters: [
2420
+ $host,
2421
+ subscriptionId,
2422
+ resourceGroupName,
2423
+ cloudHsmClusterName,
2424
+ peConnectionName
2425
+ ],
2426
+ headerParameters: [contentType, accept],
2427
+ mediaType: "json",
2428
+ serializer: serializer$3
2429
+ };
2430
+ const deleteOperationSpec$1 = {
2431
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/privateEndpointConnections/{peConnectionName}",
2432
+ httpMethod: "DELETE",
2433
+ responses: {
2434
+ 200: {},
2435
+ 201: {},
2436
+ 202: {},
2437
+ 204: {},
2438
+ default: {
2439
+ bodyMapper: CloudHsmClusterError
2440
+ }
2441
+ },
2442
+ queryParameters: [apiVersion],
2443
+ urlParameters: [
2444
+ $host,
2445
+ subscriptionId,
2446
+ resourceGroupName,
2447
+ cloudHsmClusterName,
2448
+ peConnectionName
2449
+ ],
2450
+ headerParameters: [accept],
2451
+ serializer: serializer$3
2452
+ };
2453
+ const getOperationSpec$1 = {
2454
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/privateEndpointConnections/{peConnectionName}",
2455
+ httpMethod: "GET",
2456
+ responses: {
2457
+ 200: {
2458
+ bodyMapper: PrivateEndpointConnection
2459
+ },
2460
+ default: {
2461
+ bodyMapper: CloudHsmClusterError
2462
+ }
2463
+ },
2464
+ queryParameters: [apiVersion],
2465
+ urlParameters: [
2466
+ $host,
2467
+ subscriptionId,
2468
+ resourceGroupName,
2469
+ cloudHsmClusterName,
2470
+ peConnectionName
2471
+ ],
2472
+ headerParameters: [accept],
2473
+ serializer: serializer$3
650
2474
  };
651
2475
 
652
- var Mappers = /*#__PURE__*/Object.freeze({
653
- __proto__: null,
654
- ApiEntityReference: ApiEntityReference,
655
- DedicatedHsm: DedicatedHsm,
656
- DedicatedHsmError: DedicatedHsmError,
657
- DedicatedHsmListResult: DedicatedHsmListResult,
658
- DedicatedHsmOperation: DedicatedHsmOperation,
659
- DedicatedHsmOperationDisplay: DedicatedHsmOperationDisplay,
660
- DedicatedHsmOperationListResult: DedicatedHsmOperationListResult,
661
- DedicatedHsmPatchParameters: DedicatedHsmPatchParameters,
662
- EndpointDependency: EndpointDependency,
663
- EndpointDetail: EndpointDetail,
664
- ErrorModel: ErrorModel,
665
- NetworkInterface: NetworkInterface,
666
- NetworkProfile: NetworkProfile,
667
- OutboundEnvironmentEndpoint: OutboundEnvironmentEndpoint,
668
- OutboundEnvironmentEndpointCollection: OutboundEnvironmentEndpointCollection,
669
- Resource: Resource,
670
- ResourceListResult: ResourceListResult,
671
- Sku: Sku,
672
- SystemData: SystemData
673
- });
674
-
675
2476
  /*
676
2477
  * Copyright (c) Microsoft Corporation.
677
2478
  * Licensed under the MIT License.
@@ -679,116 +2480,147 @@ var Mappers = /*#__PURE__*/Object.freeze({
679
2480
  * Code generated by Microsoft (R) AutoRest Code Generator.
680
2481
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
681
2482
  */
682
- const accept = {
683
- parameterPath: "accept",
684
- mapper: {
685
- defaultValue: "application/json",
686
- isConstant: true,
687
- serializedName: "Accept",
688
- type: {
689
- name: "String"
690
- }
691
- }
692
- };
693
- const $host = {
694
- parameterPath: "$host",
695
- mapper: {
696
- serializedName: "$host",
697
- required: true,
698
- type: {
699
- name: "String"
700
- }
701
- },
702
- skipEncoding: true
703
- };
704
- const apiVersion = {
705
- parameterPath: "apiVersion",
706
- mapper: {
707
- defaultValue: "2021-11-30",
708
- isConstant: true,
709
- serializedName: "api-version",
710
- type: {
711
- name: "String"
712
- }
2483
+ /// <reference lib="esnext.asynciterable" />
2484
+ /** Class containing PrivateEndpointConnections operations. */
2485
+ class PrivateEndpointConnectionsImpl {
2486
+ /**
2487
+ * Initialize a new instance of the class PrivateEndpointConnections class.
2488
+ * @param client Reference to the service client
2489
+ */
2490
+ constructor(client) {
2491
+ this.client = client;
713
2492
  }
714
- };
715
- const contentType = {
716
- parameterPath: ["options", "contentType"],
717
- mapper: {
718
- defaultValue: "application/json",
719
- isConstant: true,
720
- serializedName: "Content-Type",
721
- type: {
722
- name: "String"
723
- }
2493
+ /**
2494
+ * The List operation gets information about the private endpoint connections associated with the Cloud
2495
+ * HSM Cluster
2496
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2497
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2498
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2499
+ * @param options The options parameters.
2500
+ */
2501
+ listByCloudHsmCluster(resourceGroupName, cloudHsmClusterName, options) {
2502
+ const iter = this.listByCloudHsmClusterPagingAll(resourceGroupName, cloudHsmClusterName, options);
2503
+ return {
2504
+ next() {
2505
+ return iter.next();
2506
+ },
2507
+ [Symbol.asyncIterator]() {
2508
+ return this;
2509
+ },
2510
+ byPage: (settings) => {
2511
+ if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
2512
+ throw new Error("maxPageSize is not supported by this operation.");
2513
+ }
2514
+ return this.listByCloudHsmClusterPagingPage(resourceGroupName, cloudHsmClusterName, options, settings);
2515
+ }
2516
+ };
724
2517
  }
725
- };
726
- const parameters = {
727
- parameterPath: "parameters",
728
- mapper: DedicatedHsm
729
- };
730
- const resourceGroupName = {
731
- parameterPath: "resourceGroupName",
732
- mapper: {
733
- serializedName: "resourceGroupName",
734
- required: true,
735
- type: {
736
- name: "String"
737
- }
2518
+ listByCloudHsmClusterPagingPage(resourceGroupName, cloudHsmClusterName, options, settings) {
2519
+ return tslib.__asyncGenerator(this, arguments, function* listByCloudHsmClusterPagingPage_1() {
2520
+ let result;
2521
+ let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
2522
+ if (!continuationToken) {
2523
+ result = yield tslib.__await(this._listByCloudHsmCluster(resourceGroupName, cloudHsmClusterName, options));
2524
+ let page = result.value || [];
2525
+ continuationToken = result.nextLink;
2526
+ setContinuationToken(page, continuationToken);
2527
+ yield yield tslib.__await(page);
2528
+ }
2529
+ while (continuationToken) {
2530
+ result = yield tslib.__await(this._listByCloudHsmClusterNext(resourceGroupName, cloudHsmClusterName, continuationToken, options));
2531
+ continuationToken = result.nextLink;
2532
+ let page = result.value || [];
2533
+ setContinuationToken(page, continuationToken);
2534
+ yield yield tslib.__await(page);
2535
+ }
2536
+ });
738
2537
  }
739
- };
740
- const name = {
741
- parameterPath: "name",
742
- mapper: {
743
- constraints: {
744
- Pattern: new RegExp("^[a-zA-Z0-9-]{3,24}$")
745
- },
746
- serializedName: "name",
747
- required: true,
748
- type: {
749
- name: "String"
750
- }
2538
+ listByCloudHsmClusterPagingAll(resourceGroupName, cloudHsmClusterName, options) {
2539
+ return tslib.__asyncGenerator(this, arguments, function* listByCloudHsmClusterPagingAll_1() {
2540
+ var _a, e_1, _b, _c;
2541
+ try {
2542
+ for (var _d = true, _e = tslib.__asyncValues(this.listByCloudHsmClusterPagingPage(resourceGroupName, cloudHsmClusterName, options)), _f; _f = yield tslib.__await(_e.next()), _a = _f.done, !_a; _d = true) {
2543
+ _c = _f.value;
2544
+ _d = false;
2545
+ const page = _c;
2546
+ yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(page)));
2547
+ }
2548
+ }
2549
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
2550
+ finally {
2551
+ try {
2552
+ if (!_d && !_a && (_b = _e.return)) yield tslib.__await(_b.call(_e));
2553
+ }
2554
+ finally { if (e_1) throw e_1.error; }
2555
+ }
2556
+ });
751
2557
  }
752
- };
753
- const subscriptionId = {
754
- parameterPath: "subscriptionId",
755
- mapper: {
756
- serializedName: "subscriptionId",
757
- required: true,
758
- type: {
759
- name: "String"
760
- }
2558
+ /**
2559
+ * The List operation gets information about the private endpoint connections associated with the Cloud
2560
+ * HSM Cluster
2561
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2562
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2563
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2564
+ * @param options The options parameters.
2565
+ */
2566
+ _listByCloudHsmCluster(resourceGroupName, cloudHsmClusterName, options) {
2567
+ return this.client.sendOperationRequest({ resourceGroupName, cloudHsmClusterName, options }, listByCloudHsmClusterOperationSpec);
761
2568
  }
762
- };
763
- const name1 = {
764
- parameterPath: "name",
765
- mapper: {
766
- serializedName: "name",
767
- required: true,
768
- type: {
769
- name: "String"
770
- }
2569
+ /**
2570
+ * ListByCloudHsmClusterNext
2571
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
2572
+ * @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
2573
+ * Cloud HSM Cluster names must be between 3 and 24 characters in length.
2574
+ * @param nextLink The nextLink from the previous successful call to the ListByCloudHsmCluster method.
2575
+ * @param options The options parameters.
2576
+ */
2577
+ _listByCloudHsmClusterNext(resourceGroupName, cloudHsmClusterName, nextLink, options) {
2578
+ return this.client.sendOperationRequest({ resourceGroupName, cloudHsmClusterName, nextLink, options }, listByCloudHsmClusterNextOperationSpec);
771
2579
  }
772
- };
773
- const top = {
774
- parameterPath: ["options", "top"],
775
- mapper: {
776
- serializedName: "$top",
777
- type: {
778
- name: "Number"
2580
+ }
2581
+ // Operation Specifications
2582
+ const serializer$2 = coreClient__namespace.createSerializer(Mappers, /* isXml */ false);
2583
+ const listByCloudHsmClusterOperationSpec = {
2584
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/privateEndpointConnections",
2585
+ httpMethod: "GET",
2586
+ responses: {
2587
+ 200: {
2588
+ bodyMapper: PrivateEndpointConnectionListResult
2589
+ },
2590
+ default: {
2591
+ bodyMapper: CloudHsmClusterError
779
2592
  }
780
- }
2593
+ },
2594
+ queryParameters: [apiVersion],
2595
+ urlParameters: [
2596
+ $host,
2597
+ subscriptionId,
2598
+ resourceGroupName,
2599
+ cloudHsmClusterName
2600
+ ],
2601
+ headerParameters: [accept],
2602
+ serializer: serializer$2
781
2603
  };
782
- const nextLink = {
783
- parameterPath: "nextLink",
784
- mapper: {
785
- serializedName: "nextLink",
786
- required: true,
787
- type: {
788
- name: "String"
2604
+ const listByCloudHsmClusterNextOperationSpec = {
2605
+ path: "{nextLink}",
2606
+ httpMethod: "GET",
2607
+ responses: {
2608
+ 200: {
2609
+ bodyMapper: PrivateEndpointConnectionListResult
2610
+ },
2611
+ default: {
2612
+ bodyMapper: CloudHsmClusterError
789
2613
  }
790
2614
  },
791
- skipEncoding: true
2615
+ urlParameters: [
2616
+ $host,
2617
+ subscriptionId,
2618
+ resourceGroupName,
2619
+ cloudHsmClusterName,
2620
+ nextLink
2621
+ ],
2622
+ headerParameters: [accept],
2623
+ serializer: serializer$2
792
2624
  };
793
2625
 
794
2626
  /*
@@ -877,40 +2709,12 @@ const listOperationSpec = {
877
2709
  bodyMapper: DedicatedHsmError
878
2710
  }
879
2711
  },
880
- queryParameters: [apiVersion],
2712
+ queryParameters: [apiVersion1],
881
2713
  urlParameters: [$host],
882
2714
  headerParameters: [accept],
883
2715
  serializer: serializer$1
884
2716
  };
885
2717
 
886
- /*
887
- * Copyright (c) Microsoft Corporation.
888
- * Licensed under the MIT License.
889
- *
890
- * Code generated by Microsoft (R) AutoRest Code Generator.
891
- * Changes may cause incorrect behavior and will be lost if the code is regenerated.
892
- */
893
- class LroImpl {
894
- constructor(sendOperationFn, args, spec, requestPath = spec.path, requestMethod = spec.httpMethod) {
895
- this.sendOperationFn = sendOperationFn;
896
- this.args = args;
897
- this.spec = spec;
898
- this.requestPath = requestPath;
899
- this.requestMethod = requestMethod;
900
- }
901
- sendInitialRequest() {
902
- return tslib.__awaiter(this, void 0, void 0, function* () {
903
- return this.sendOperationFn(this.args, this.spec);
904
- });
905
- }
906
- sendPollRequest(path) {
907
- return tslib.__awaiter(this, void 0, void 0, function* () {
908
- const _a = this.spec, restSpec = tslib.__rest(_a, ["requestBody"]);
909
- return this.sendOperationFn(this.args, Object.assign(Object.assign({}, restSpec), { path, httpMethod: "GET" }));
910
- });
911
- }
912
- }
913
-
914
2718
  /*
915
2719
  * Copyright (c) Microsoft Corporation.
916
2720
  * Licensed under the MIT License.
@@ -1128,7 +2932,7 @@ class DedicatedHsmOperationsImpl {
1128
2932
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1129
2933
  return this.client.sendOperationRequest(args, spec);
1130
2934
  });
1131
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2935
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1132
2936
  var _a;
1133
2937
  let currentRawResponse = undefined;
1134
2938
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -1147,9 +2951,13 @@ class DedicatedHsmOperationsImpl {
1147
2951
  }
1148
2952
  };
1149
2953
  });
1150
- const lro = new LroImpl(sendOperation, { resourceGroupName, name, parameters, options }, createOrUpdateOperationSpec);
1151
- const poller = new coreLro.LroEngine(lro, {
1152
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2954
+ const lro = createLroSpec({
2955
+ sendOperationFn,
2956
+ args: { resourceGroupName, name, parameters, options },
2957
+ spec: createOrUpdateOperationSpec
2958
+ });
2959
+ const poller = yield coreLro.createHttpPoller(lro, {
2960
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1153
2961
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
1154
2962
  });
1155
2963
  yield poller.poll();
@@ -1180,7 +2988,7 @@ class DedicatedHsmOperationsImpl {
1180
2988
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1181
2989
  return this.client.sendOperationRequest(args, spec);
1182
2990
  });
1183
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2991
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1184
2992
  var _a;
1185
2993
  let currentRawResponse = undefined;
1186
2994
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -1199,9 +3007,13 @@ class DedicatedHsmOperationsImpl {
1199
3007
  }
1200
3008
  };
1201
3009
  });
1202
- const lro = new LroImpl(sendOperation, { resourceGroupName, name, options }, updateOperationSpec);
1203
- const poller = new coreLro.LroEngine(lro, {
1204
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
3010
+ const lro = createLroSpec({
3011
+ sendOperationFn,
3012
+ args: { resourceGroupName, name, options },
3013
+ spec: updateOperationSpec
3014
+ });
3015
+ const poller = yield coreLro.createHttpPoller(lro, {
3016
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1205
3017
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
1206
3018
  });
1207
3019
  yield poller.poll();
@@ -1231,7 +3043,7 @@ class DedicatedHsmOperationsImpl {
1231
3043
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1232
3044
  return this.client.sendOperationRequest(args, spec);
1233
3045
  });
1234
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
3046
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
1235
3047
  var _a;
1236
3048
  let currentRawResponse = undefined;
1237
3049
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -1250,9 +3062,13 @@ class DedicatedHsmOperationsImpl {
1250
3062
  }
1251
3063
  };
1252
3064
  });
1253
- const lro = new LroImpl(sendOperation, { resourceGroupName, name, options }, deleteOperationSpec);
1254
- const poller = new coreLro.LroEngine(lro, {
1255
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
3065
+ const lro = createLroSpec({
3066
+ sendOperationFn,
3067
+ args: { resourceGroupName, name, options },
3068
+ spec: deleteOperationSpec
3069
+ });
3070
+ const poller = yield coreLro.createHttpPoller(lro, {
3071
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
1256
3072
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
1257
3073
  });
1258
3074
  yield poller.poll();
@@ -1358,14 +3174,14 @@ const createOrUpdateOperationSpec = {
1358
3174
  }
1359
3175
  },
1360
3176
  requestBody: parameters,
1361
- queryParameters: [apiVersion],
3177
+ queryParameters: [apiVersion1],
1362
3178
  urlParameters: [
1363
3179
  $host,
1364
- resourceGroupName,
1365
- name,
1366
- subscriptionId
3180
+ subscriptionId,
3181
+ resourceGroupName1,
3182
+ name
1367
3183
  ],
1368
- headerParameters: [accept, contentType],
3184
+ headerParameters: [contentType, accept],
1369
3185
  mediaType: "json",
1370
3186
  serializer
1371
3187
  };
@@ -1393,14 +3209,14 @@ const updateOperationSpec = {
1393
3209
  parameterPath: { tags: ["options", "tags"] },
1394
3210
  mapper: Object.assign(Object.assign({}, DedicatedHsmPatchParameters), { required: true })
1395
3211
  },
1396
- queryParameters: [apiVersion],
3212
+ queryParameters: [apiVersion1],
1397
3213
  urlParameters: [
1398
3214
  $host,
1399
- resourceGroupName,
1400
- name,
1401
- subscriptionId
3215
+ subscriptionId,
3216
+ resourceGroupName1,
3217
+ name
1402
3218
  ],
1403
- headerParameters: [accept, contentType],
3219
+ headerParameters: [contentType, accept],
1404
3220
  mediaType: "json",
1405
3221
  serializer
1406
3222
  };
@@ -1416,11 +3232,11 @@ const deleteOperationSpec = {
1416
3232
  bodyMapper: DedicatedHsmError
1417
3233
  }
1418
3234
  },
1419
- queryParameters: [apiVersion],
3235
+ queryParameters: [apiVersion1],
1420
3236
  urlParameters: [
1421
3237
  $host,
1422
- resourceGroupName,
1423
3238
  subscriptionId,
3239
+ resourceGroupName1,
1424
3240
  name1
1425
3241
  ],
1426
3242
  headerParameters: [accept],
@@ -1437,11 +3253,11 @@ const getOperationSpec = {
1437
3253
  bodyMapper: DedicatedHsmError
1438
3254
  }
1439
3255
  },
1440
- queryParameters: [apiVersion],
3256
+ queryParameters: [apiVersion1],
1441
3257
  urlParameters: [
1442
3258
  $host,
1443
- resourceGroupName,
1444
3259
  subscriptionId,
3260
+ resourceGroupName1,
1445
3261
  name1
1446
3262
  ],
1447
3263
  headerParameters: [accept],
@@ -1458,11 +3274,11 @@ const listByResourceGroupOperationSpec = {
1458
3274
  bodyMapper: DedicatedHsmError
1459
3275
  }
1460
3276
  },
1461
- queryParameters: [apiVersion, top],
3277
+ queryParameters: [apiVersion1, top],
1462
3278
  urlParameters: [
1463
3279
  $host,
1464
- resourceGroupName,
1465
- subscriptionId
3280
+ subscriptionId,
3281
+ resourceGroupName1
1466
3282
  ],
1467
3283
  headerParameters: [accept],
1468
3284
  serializer
@@ -1478,7 +3294,7 @@ const listBySubscriptionOperationSpec = {
1478
3294
  bodyMapper: DedicatedHsmError
1479
3295
  }
1480
3296
  },
1481
- queryParameters: [apiVersion, top],
3297
+ queryParameters: [apiVersion1, top],
1482
3298
  urlParameters: [$host, subscriptionId],
1483
3299
  headerParameters: [accept],
1484
3300
  serializer
@@ -1494,11 +3310,11 @@ const listOutboundNetworkDependenciesEndpointsOperationSpec = {
1494
3310
  bodyMapper: DedicatedHsmError
1495
3311
  }
1496
3312
  },
1497
- queryParameters: [apiVersion],
3313
+ queryParameters: [apiVersion1],
1498
3314
  urlParameters: [
1499
3315
  $host,
1500
- resourceGroupName,
1501
3316
  subscriptionId,
3317
+ resourceGroupName1,
1502
3318
  name1
1503
3319
  ],
1504
3320
  headerParameters: [accept],
@@ -1517,9 +3333,9 @@ const listByResourceGroupNextOperationSpec = {
1517
3333
  },
1518
3334
  urlParameters: [
1519
3335
  $host,
1520
- resourceGroupName,
1521
3336
  subscriptionId,
1522
- nextLink
3337
+ nextLink,
3338
+ resourceGroupName1
1523
3339
  ],
1524
3340
  headerParameters: [accept],
1525
3341
  serializer
@@ -1556,10 +3372,10 @@ const listOutboundNetworkDependenciesEndpointsNextOperationSpec = {
1556
3372
  },
1557
3373
  urlParameters: [
1558
3374
  $host,
1559
- resourceGroupName,
1560
3375
  subscriptionId,
1561
- name1,
1562
- nextLink
3376
+ nextLink,
3377
+ resourceGroupName1,
3378
+ name1
1563
3379
  ],
1564
3380
  headerParameters: [accept],
1565
3381
  serializer
@@ -1572,12 +3388,11 @@ const listOutboundNetworkDependenciesEndpointsNextOperationSpec = {
1572
3388
  * Code generated by Microsoft (R) AutoRest Code Generator.
1573
3389
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
1574
3390
  */
1575
- class AzureDedicatedHSMResourceProvider extends coreClient__namespace.ServiceClient {
3391
+ class AzureHSMResourceProvider extends coreClient__namespace.ServiceClient {
1576
3392
  /**
1577
- * Initializes a new instance of the AzureDedicatedHSMResourceProvider class.
3393
+ * Initializes a new instance of the AzureHSMResourceProvider class.
1578
3394
  * @param credentials Subscription credentials which uniquely identify client subscription.
1579
- * @param subscriptionId Subscription credentials which uniquely identify Microsoft Azure subscription.
1580
- * The subscription ID forms part of the URI for every service call.
3395
+ * @param subscriptionId The ID of the target subscription. The value must be an UUID.
1581
3396
  * @param options The parameter options
1582
3397
  */
1583
3398
  constructor(credentials, subscriptionId, options) {
@@ -1596,7 +3411,7 @@ class AzureDedicatedHSMResourceProvider extends coreClient__namespace.ServiceCli
1596
3411
  requestContentType: "application/json; charset=utf-8",
1597
3412
  credential: credentials
1598
3413
  };
1599
- const packageDetails = `azsdk-js-arm-hardwaresecuritymodules/2.0.0`;
3414
+ const packageDetails = `azsdk-js-arm-hardwaresecuritymodules/2.0.0-beta.1`;
1600
3415
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
1601
3416
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
1602
3417
  : `${packageDetails}`;
@@ -1629,40 +3444,15 @@ class AzureDedicatedHSMResourceProvider extends coreClient__namespace.ServiceCli
1629
3444
  this.subscriptionId = subscriptionId;
1630
3445
  // Assigning values to Constant parameters
1631
3446
  this.$host = options.$host || "https://management.azure.com";
1632
- this.apiVersion = options.apiVersion || "2021-11-30";
3447
+ this.cloudHsmClusters = new CloudHsmClustersImpl(this);
3448
+ this.cloudHsmClusterPrivateLinkResources = new CloudHsmClusterPrivateLinkResourcesImpl(this);
3449
+ this.cloudHsmClusterPrivateEndpointConnections = new CloudHsmClusterPrivateEndpointConnectionsImpl(this);
3450
+ this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(this);
1633
3451
  this.operations = new OperationsImpl(this);
1634
3452
  this.dedicatedHsmOperations = new DedicatedHsmOperationsImpl(this);
1635
- this.addCustomApiVersionPolicy(options.apiVersion);
1636
- }
1637
- /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */
1638
- addCustomApiVersionPolicy(apiVersion) {
1639
- if (!apiVersion) {
1640
- return;
1641
- }
1642
- const apiVersionPolicy = {
1643
- name: "CustomApiVersionPolicy",
1644
- sendRequest(request, next) {
1645
- return tslib.__awaiter(this, void 0, void 0, function* () {
1646
- const param = request.url.split("?");
1647
- if (param.length > 1) {
1648
- const newParams = param[1].split("&").map((item) => {
1649
- if (item.indexOf("api-version") > -1) {
1650
- return "api-version=" + apiVersion;
1651
- }
1652
- else {
1653
- return item;
1654
- }
1655
- });
1656
- request.url = param[0] + "?" + newParams.join("&");
1657
- }
1658
- return next(request);
1659
- });
1660
- }
1661
- };
1662
- this.pipeline.addPolicy(apiVersionPolicy);
1663
3453
  }
1664
3454
  }
1665
3455
 
1666
- exports.AzureDedicatedHSMResourceProvider = AzureDedicatedHSMResourceProvider;
3456
+ exports.AzureHSMResourceProvider = AzureHSMResourceProvider;
1667
3457
  exports.getContinuationToken = getContinuationToken;
1668
3458
  //# sourceMappingURL=index.js.map