@azure/arm-hardwaresecuritymodules 1.0.0-alpha.20220401.3

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 (109) hide show
  1. package/CHANGELOG.md +5 -0
  2. package/LICENSE +21 -0
  3. package/README.md +109 -0
  4. package/dist/index.js +1542 -0
  5. package/dist/index.js.map +1 -0
  6. package/dist/index.min.js +1 -0
  7. package/dist/index.min.js.map +1 -0
  8. package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.d.ts +2 -0
  9. package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.d.ts.map +1 -0
  10. package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.js +109 -0
  11. package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.js.map +1 -0
  12. package/dist-esm/samples-dev/dedicatedHsmDeleteSample.d.ts +2 -0
  13. package/dist-esm/samples-dev/dedicatedHsmDeleteSample.d.ts.map +1 -0
  14. package/dist-esm/samples-dev/dedicatedHsmDeleteSample.js +31 -0
  15. package/dist-esm/samples-dev/dedicatedHsmDeleteSample.js.map +1 -0
  16. package/dist-esm/samples-dev/dedicatedHsmGetSample.d.ts +2 -0
  17. package/dist-esm/samples-dev/dedicatedHsmGetSample.d.ts.map +1 -0
  18. package/dist-esm/samples-dev/dedicatedHsmGetSample.js +67 -0
  19. package/dist-esm/samples-dev/dedicatedHsmGetSample.js.map +1 -0
  20. package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.d.ts +2 -0
  21. package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.d.ts.map +1 -0
  22. package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.js +75 -0
  23. package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.js.map +1 -0
  24. package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.d.ts +2 -0
  25. package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.d.ts.map +1 -0
  26. package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.js +73 -0
  27. package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.js.map +1 -0
  28. package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.d.ts +2 -0
  29. package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.d.ts.map +1 -0
  30. package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.js +45 -0
  31. package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.js.map +1 -0
  32. package/dist-esm/samples-dev/dedicatedHsmUpdateSample.d.ts +2 -0
  33. package/dist-esm/samples-dev/dedicatedHsmUpdateSample.d.ts.map +1 -0
  34. package/dist-esm/samples-dev/dedicatedHsmUpdateSample.js +53 -0
  35. package/dist-esm/samples-dev/dedicatedHsmUpdateSample.js.map +1 -0
  36. package/dist-esm/samples-dev/operationsListSample.d.ts +2 -0
  37. package/dist-esm/samples-dev/operationsListSample.d.ts.map +1 -0
  38. package/dist-esm/samples-dev/operationsListSample.js +73 -0
  39. package/dist-esm/samples-dev/operationsListSample.js.map +1 -0
  40. package/dist-esm/src/azureDedicatedHSMResourceProvider.d.ts +20 -0
  41. package/dist-esm/src/azureDedicatedHSMResourceProvider.d.ts.map +1 -0
  42. package/dist-esm/src/azureDedicatedHSMResourceProvider.js +54 -0
  43. package/dist-esm/src/azureDedicatedHSMResourceProvider.js.map +1 -0
  44. package/dist-esm/src/index.d.ts +5 -0
  45. package/dist-esm/src/index.d.ts.map +1 -0
  46. package/dist-esm/src/index.js +12 -0
  47. package/dist-esm/src/index.js.map +1 -0
  48. package/dist-esm/src/lroImpl.d.ts +16 -0
  49. package/dist-esm/src/lroImpl.d.ts.map +1 -0
  50. package/dist-esm/src/lroImpl.js +29 -0
  51. package/dist-esm/src/lroImpl.js.map +1 -0
  52. package/dist-esm/src/models/index.d.ts +372 -0
  53. package/dist-esm/src/models/index.d.ts.map +1 -0
  54. package/dist-esm/src/models/index.js +52 -0
  55. package/dist-esm/src/models/index.js.map +1 -0
  56. package/dist-esm/src/models/mappers.d.ts +21 -0
  57. package/dist-esm/src/models/mappers.d.ts.map +1 -0
  58. package/dist-esm/src/models/mappers.js +534 -0
  59. package/dist-esm/src/models/mappers.js.map +1 -0
  60. package/dist-esm/src/models/parameters.d.ts +14 -0
  61. package/dist-esm/src/models/parameters.d.ts.map +1 -0
  62. package/dist-esm/src/models/parameters.js +124 -0
  63. package/dist-esm/src/models/parameters.js.map +1 -0
  64. package/dist-esm/src/operations/dedicatedHsmOperations.d.ts +134 -0
  65. package/dist-esm/src/operations/dedicatedHsmOperations.d.ts.map +1 -0
  66. package/dist-esm/src/operations/dedicatedHsmOperations.js +624 -0
  67. package/dist-esm/src/operations/dedicatedHsmOperations.js.map +1 -0
  68. package/dist-esm/src/operations/index.d.ts +3 -0
  69. package/dist-esm/src/operations/index.d.ts.map +1 -0
  70. package/dist-esm/src/operations/index.js +10 -0
  71. package/dist-esm/src/operations/index.js.map +1 -0
  72. package/dist-esm/src/operations/operations.d.ts +26 -0
  73. package/dist-esm/src/operations/operations.d.ts.map +1 -0
  74. package/dist-esm/src/operations/operations.js +90 -0
  75. package/dist-esm/src/operations/operations.js.map +1 -0
  76. package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.d.ts +78 -0
  77. package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.d.ts.map +1 -0
  78. package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.js +9 -0
  79. package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.js.map +1 -0
  80. package/dist-esm/src/operationsInterfaces/index.d.ts +3 -0
  81. package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
  82. package/dist-esm/src/operationsInterfaces/index.js +10 -0
  83. package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
  84. package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -0
  85. package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
  86. package/dist-esm/src/operationsInterfaces/operations.js +9 -0
  87. package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
  88. package/dist-esm/test/sampleTest.d.ts +2 -0
  89. package/dist-esm/test/sampleTest.d.ts.map +1 -0
  90. package/dist-esm/test/sampleTest.js +41 -0
  91. package/dist-esm/test/sampleTest.js.map +1 -0
  92. package/package.json +118 -0
  93. package/review/arm-hardwaresecuritymodules.api.md +318 -0
  94. package/rollup.config.js +122 -0
  95. package/src/azureDedicatedHSMResourceProvider.ts +79 -0
  96. package/src/index.ts +12 -0
  97. package/src/lroImpl.ts +34 -0
  98. package/src/models/index.ts +428 -0
  99. package/src/models/mappers.ts +562 -0
  100. package/src/models/parameters.ts +144 -0
  101. package/src/operations/dedicatedHsmOperations.ts +830 -0
  102. package/src/operations/index.ts +10 -0
  103. package/src/operations/operations.ts +98 -0
  104. package/src/operationsInterfaces/dedicatedHsmOperations.ts +149 -0
  105. package/src/operationsInterfaces/index.ts +10 -0
  106. package/src/operationsInterfaces/operations.ts +22 -0
  107. package/tsconfig.json +33 -0
  108. package/types/arm-hardwaresecuritymodules.d.ts +524 -0
  109. package/types/tsdoc-metadata.json +11 -0
@@ -0,0 +1,10 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ export * from "./operations";
10
+ export * from "./dedicatedHsmOperations";
@@ -0,0 +1,98 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { Operations } from "../operationsInterfaces";
11
+ import * as coreClient from "@azure/core-client";
12
+ import * as Mappers from "../models/mappers";
13
+ import * as Parameters from "../models/parameters";
14
+ import { AzureDedicatedHSMResourceProvider } from "../azureDedicatedHSMResourceProvider";
15
+ import {
16
+ DedicatedHsmOperation,
17
+ OperationsListOptionalParams,
18
+ OperationsListResponse
19
+ } from "../models";
20
+
21
+ /// <reference lib="esnext.asynciterable" />
22
+ /** Class containing Operations operations. */
23
+ export class OperationsImpl implements Operations {
24
+ private readonly client: AzureDedicatedHSMResourceProvider;
25
+
26
+ /**
27
+ * Initialize a new instance of the class Operations class.
28
+ * @param client Reference to the service client
29
+ */
30
+ constructor(client: AzureDedicatedHSMResourceProvider) {
31
+ this.client = client;
32
+ }
33
+
34
+ /**
35
+ * Get a list of Dedicated HSM operations.
36
+ * @param options The options parameters.
37
+ */
38
+ public list(
39
+ options?: OperationsListOptionalParams
40
+ ): PagedAsyncIterableIterator<DedicatedHsmOperation> {
41
+ const iter = this.listPagingAll(options);
42
+ return {
43
+ next() {
44
+ return iter.next();
45
+ },
46
+ [Symbol.asyncIterator]() {
47
+ return this;
48
+ },
49
+ byPage: () => {
50
+ return this.listPagingPage(options);
51
+ }
52
+ };
53
+ }
54
+
55
+ private async *listPagingPage(
56
+ options?: OperationsListOptionalParams
57
+ ): AsyncIterableIterator<DedicatedHsmOperation[]> {
58
+ let result = await this._list(options);
59
+ yield result.value || [];
60
+ }
61
+
62
+ private async *listPagingAll(
63
+ options?: OperationsListOptionalParams
64
+ ): AsyncIterableIterator<DedicatedHsmOperation> {
65
+ for await (const page of this.listPagingPage(options)) {
66
+ yield* page;
67
+ }
68
+ }
69
+
70
+ /**
71
+ * Get a list of Dedicated HSM operations.
72
+ * @param options The options parameters.
73
+ */
74
+ private _list(
75
+ options?: OperationsListOptionalParams
76
+ ): Promise<OperationsListResponse> {
77
+ return this.client.sendOperationRequest({ options }, listOperationSpec);
78
+ }
79
+ }
80
+ // Operation Specifications
81
+ const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
82
+
83
+ const listOperationSpec: coreClient.OperationSpec = {
84
+ path: "/providers/Microsoft.HardwareSecurityModules/operations",
85
+ httpMethod: "GET",
86
+ responses: {
87
+ 200: {
88
+ bodyMapper: Mappers.DedicatedHsmOperationListResult
89
+ },
90
+ default: {
91
+ bodyMapper: Mappers.DedicatedHsmError
92
+ }
93
+ },
94
+ queryParameters: [Parameters.apiVersion],
95
+ urlParameters: [Parameters.$host],
96
+ headerParameters: [Parameters.accept],
97
+ serializer
98
+ };
@@ -0,0 +1,149 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { PollerLike, PollOperationState } from "@azure/core-lro";
11
+ import {
12
+ DedicatedHsm,
13
+ DedicatedHsmListByResourceGroupOptionalParams,
14
+ DedicatedHsmListBySubscriptionOptionalParams,
15
+ OutboundEnvironmentEndpoint,
16
+ DedicatedHsmListOutboundNetworkDependenciesEndpointsOptionalParams,
17
+ DedicatedHsmCreateOrUpdateOptionalParams,
18
+ DedicatedHsmCreateOrUpdateResponse,
19
+ DedicatedHsmUpdateOptionalParams,
20
+ DedicatedHsmUpdateResponse,
21
+ DedicatedHsmDeleteOptionalParams,
22
+ DedicatedHsmGetOptionalParams,
23
+ DedicatedHsmGetResponse
24
+ } from "../models";
25
+
26
+ /// <reference lib="esnext.asynciterable" />
27
+ /** Interface representing a DedicatedHsmOperations. */
28
+ export interface DedicatedHsmOperations {
29
+ /**
30
+ * The List operation gets information about the dedicated hsms associated with the subscription and
31
+ * within the specified resource group.
32
+ * @param resourceGroupName The name of the Resource Group to which the dedicated HSM belongs.
33
+ * @param options The options parameters.
34
+ */
35
+ listByResourceGroup(
36
+ resourceGroupName: string,
37
+ options?: DedicatedHsmListByResourceGroupOptionalParams
38
+ ): PagedAsyncIterableIterator<DedicatedHsm>;
39
+ /**
40
+ * The List operation gets information about the dedicated HSMs associated with the subscription.
41
+ * @param options The options parameters.
42
+ */
43
+ listBySubscription(
44
+ options?: DedicatedHsmListBySubscriptionOptionalParams
45
+ ): PagedAsyncIterableIterator<DedicatedHsm>;
46
+ /**
47
+ * Gets a list of egress endpoints (network endpoints of all outbound dependencies) in the specified
48
+ * dedicated hsm resource. The operation returns properties of each egress endpoint.
49
+ * @param resourceGroupName The name of the Resource Group to which the dedicated hsm belongs.
50
+ * @param name The name of the dedicated HSM.
51
+ * @param options The options parameters.
52
+ */
53
+ listOutboundNetworkDependenciesEndpoints(
54
+ resourceGroupName: string,
55
+ name: string,
56
+ options?: DedicatedHsmListOutboundNetworkDependenciesEndpointsOptionalParams
57
+ ): PagedAsyncIterableIterator<OutboundEnvironmentEndpoint>;
58
+ /**
59
+ * Create or Update a dedicated HSM in the specified subscription.
60
+ * @param resourceGroupName The name of the Resource Group to which the resource belongs.
61
+ * @param name Name of the dedicated Hsm
62
+ * @param parameters Parameters to create or update the dedicated hsm
63
+ * @param options The options parameters.
64
+ */
65
+ beginCreateOrUpdate(
66
+ resourceGroupName: string,
67
+ name: string,
68
+ parameters: DedicatedHsm,
69
+ options?: DedicatedHsmCreateOrUpdateOptionalParams
70
+ ): Promise<
71
+ PollerLike<
72
+ PollOperationState<DedicatedHsmCreateOrUpdateResponse>,
73
+ DedicatedHsmCreateOrUpdateResponse
74
+ >
75
+ >;
76
+ /**
77
+ * Create or Update a dedicated HSM in the specified subscription.
78
+ * @param resourceGroupName The name of the Resource Group to which the resource belongs.
79
+ * @param name Name of the dedicated Hsm
80
+ * @param parameters Parameters to create or update the dedicated hsm
81
+ * @param options The options parameters.
82
+ */
83
+ beginCreateOrUpdateAndWait(
84
+ resourceGroupName: string,
85
+ name: string,
86
+ parameters: DedicatedHsm,
87
+ options?: DedicatedHsmCreateOrUpdateOptionalParams
88
+ ): Promise<DedicatedHsmCreateOrUpdateResponse>;
89
+ /**
90
+ * Update a dedicated HSM in the specified subscription.
91
+ * @param resourceGroupName The name of the Resource Group to which the server belongs.
92
+ * @param name Name of the dedicated HSM
93
+ * @param options The options parameters.
94
+ */
95
+ beginUpdate(
96
+ resourceGroupName: string,
97
+ name: string,
98
+ options?: DedicatedHsmUpdateOptionalParams
99
+ ): Promise<
100
+ PollerLike<
101
+ PollOperationState<DedicatedHsmUpdateResponse>,
102
+ DedicatedHsmUpdateResponse
103
+ >
104
+ >;
105
+ /**
106
+ * Update a dedicated HSM in the specified subscription.
107
+ * @param resourceGroupName The name of the Resource Group to which the server belongs.
108
+ * @param name Name of the dedicated HSM
109
+ * @param options The options parameters.
110
+ */
111
+ beginUpdateAndWait(
112
+ resourceGroupName: string,
113
+ name: string,
114
+ options?: DedicatedHsmUpdateOptionalParams
115
+ ): Promise<DedicatedHsmUpdateResponse>;
116
+ /**
117
+ * Deletes the specified Azure Dedicated HSM.
118
+ * @param resourceGroupName The name of the Resource Group to which the dedicated HSM belongs.
119
+ * @param name The name of the dedicated HSM to delete
120
+ * @param options The options parameters.
121
+ */
122
+ beginDelete(
123
+ resourceGroupName: string,
124
+ name: string,
125
+ options?: DedicatedHsmDeleteOptionalParams
126
+ ): Promise<PollerLike<PollOperationState<void>, void>>;
127
+ /**
128
+ * Deletes the specified Azure Dedicated HSM.
129
+ * @param resourceGroupName The name of the Resource Group to which the dedicated HSM belongs.
130
+ * @param name The name of the dedicated HSM to delete
131
+ * @param options The options parameters.
132
+ */
133
+ beginDeleteAndWait(
134
+ resourceGroupName: string,
135
+ name: string,
136
+ options?: DedicatedHsmDeleteOptionalParams
137
+ ): Promise<void>;
138
+ /**
139
+ * Gets the specified Azure dedicated HSM.
140
+ * @param resourceGroupName The name of the Resource Group to which the dedicated hsm belongs.
141
+ * @param name The name of the dedicated HSM.
142
+ * @param options The options parameters.
143
+ */
144
+ get(
145
+ resourceGroupName: string,
146
+ name: string,
147
+ options?: DedicatedHsmGetOptionalParams
148
+ ): Promise<DedicatedHsmGetResponse>;
149
+ }
@@ -0,0 +1,10 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ export * from "./operations";
10
+ export * from "./dedicatedHsmOperations";
@@ -0,0 +1,22 @@
1
+ /*
2
+ * Copyright (c) Microsoft Corporation.
3
+ * Licensed under the MIT License.
4
+ *
5
+ * Code generated by Microsoft (R) AutoRest Code Generator.
6
+ * Changes may cause incorrect behavior and will be lost if the code is regenerated.
7
+ */
8
+
9
+ import { PagedAsyncIterableIterator } from "@azure/core-paging";
10
+ import { DedicatedHsmOperation, OperationsListOptionalParams } from "../models";
11
+
12
+ /// <reference lib="esnext.asynciterable" />
13
+ /** Interface representing a Operations. */
14
+ export interface Operations {
15
+ /**
16
+ * Get a list of Dedicated HSM operations.
17
+ * @param options The options parameters.
18
+ */
19
+ list(
20
+ options?: OperationsListOptionalParams
21
+ ): PagedAsyncIterableIterator<DedicatedHsmOperation>;
22
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,33 @@
1
+ {
2
+ "compilerOptions": {
3
+ "module": "es6",
4
+ "moduleResolution": "node",
5
+ "strict": true,
6
+ "target": "es6",
7
+ "sourceMap": true,
8
+ "declarationMap": true,
9
+ "esModuleInterop": true,
10
+ "allowSyntheticDefaultImports": true,
11
+ "forceConsistentCasingInFileNames": true,
12
+ "lib": [
13
+ "es6",
14
+ "dom"
15
+ ],
16
+ "declaration": true,
17
+ "outDir": "./dist-esm",
18
+ "importHelpers": true,
19
+ "paths": {
20
+ "@azure/arm-hardwaresecuritymodules": [
21
+ "./src/index"
22
+ ]
23
+ }
24
+ },
25
+ "include": [
26
+ "./src/**/*.ts",
27
+ "./test/**/*.ts",
28
+ "samples-dev/**/*.ts"
29
+ ],
30
+ "exclude": [
31
+ "node_modules"
32
+ ]
33
+ }