@azure/arm-networkfunction 2.0.2-alpha.20260302.1 → 2.0.2-alpha.20260303.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 (77) hide show
  1. package/dist/commonjs/azureTrafficCollectorClient.js +131 -115
  2. package/dist/commonjs/azureTrafficCollectorClient.js.map +7 -1
  3. package/dist/commonjs/index.js +28 -19
  4. package/dist/commonjs/index.js.map +7 -1
  5. package/dist/commonjs/lroImpl.js +40 -35
  6. package/dist/commonjs/lroImpl.js.map +7 -1
  7. package/dist/commonjs/models/index.js +64 -69
  8. package/dist/commonjs/models/index.js.map +7 -1
  9. package/dist/commonjs/models/mappers.js +502 -473
  10. package/dist/commonjs/models/mappers.js.map +7 -1
  11. package/dist/commonjs/models/parameters.js +154 -127
  12. package/dist/commonjs/models/parameters.js.map +7 -1
  13. package/dist/commonjs/operations/azureTrafficCollectors.js +293 -249
  14. package/dist/commonjs/operations/azureTrafficCollectors.js.map +7 -1
  15. package/dist/commonjs/operations/azureTrafficCollectorsByResourceGroup.js +152 -122
  16. package/dist/commonjs/operations/azureTrafficCollectorsByResourceGroup.js.map +7 -1
  17. package/dist/commonjs/operations/azureTrafficCollectorsBySubscription.js +137 -114
  18. package/dist/commonjs/operations/azureTrafficCollectorsBySubscription.js.map +7 -1
  19. package/dist/commonjs/operations/collectorPolicies.js +454 -381
  20. package/dist/commonjs/operations/collectorPolicies.js.map +7 -1
  21. package/dist/commonjs/operations/index.js +21 -16
  22. package/dist/commonjs/operations/index.js.map +7 -1
  23. package/dist/commonjs/operations/networkFunction.js +100 -77
  24. package/dist/commonjs/operations/networkFunction.js.map +7 -1
  25. package/dist/commonjs/operationsInterfaces/azureTrafficCollectors.js +15 -10
  26. package/dist/commonjs/operationsInterfaces/azureTrafficCollectors.js.map +7 -1
  27. package/dist/commonjs/operationsInterfaces/azureTrafficCollectorsByResourceGroup.js +15 -10
  28. package/dist/commonjs/operationsInterfaces/azureTrafficCollectorsByResourceGroup.js.map +7 -1
  29. package/dist/commonjs/operationsInterfaces/azureTrafficCollectorsBySubscription.js +15 -10
  30. package/dist/commonjs/operationsInterfaces/azureTrafficCollectorsBySubscription.js.map +7 -1
  31. package/dist/commonjs/operationsInterfaces/collectorPolicies.js +15 -10
  32. package/dist/commonjs/operationsInterfaces/collectorPolicies.js.map +7 -1
  33. package/dist/commonjs/operationsInterfaces/index.js +21 -16
  34. package/dist/commonjs/operationsInterfaces/index.js.map +7 -1
  35. package/dist/commonjs/operationsInterfaces/networkFunction.js +15 -10
  36. package/dist/commonjs/operationsInterfaces/networkFunction.js.map +7 -1
  37. package/dist/commonjs/pagingHelper.js +34 -30
  38. package/dist/commonjs/pagingHelper.js.map +7 -1
  39. package/dist/esm/azureTrafficCollectorClient.js +107 -109
  40. package/dist/esm/azureTrafficCollectorClient.js.map +7 -1
  41. package/dist/esm/index.js +6 -11
  42. package/dist/esm/index.js.map +7 -1
  43. package/dist/esm/lroImpl.js +22 -32
  44. package/dist/esm/lroImpl.js.map +7 -1
  45. package/dist/esm/models/index.js +45 -66
  46. package/dist/esm/models/index.js.map +7 -1
  47. package/dist/esm/models/mappers.js +483 -470
  48. package/dist/esm/models/mappers.js.map +7 -1
  49. package/dist/esm/models/parameters.js +143 -128
  50. package/dist/esm/models/parameters.js.map +7 -1
  51. package/dist/esm/operations/azureTrafficCollectors.js +260 -240
  52. package/dist/esm/operations/azureTrafficCollectors.js.map +7 -1
  53. package/dist/esm/operations/azureTrafficCollectorsByResourceGroup.js +120 -114
  54. package/dist/esm/operations/azureTrafficCollectorsByResourceGroup.js.map +7 -1
  55. package/dist/esm/operations/azureTrafficCollectorsBySubscription.js +105 -106
  56. package/dist/esm/operations/azureTrafficCollectorsBySubscription.js.map +7 -1
  57. package/dist/esm/operations/collectorPolicies.js +420 -371
  58. package/dist/esm/operations/collectorPolicies.js.map +7 -1
  59. package/dist/esm/operations/index.js +0 -8
  60. package/dist/esm/operations/index.js.map +7 -1
  61. package/dist/esm/operations/networkFunction.js +69 -70
  62. package/dist/esm/operations/networkFunction.js.map +7 -1
  63. package/dist/esm/operationsInterfaces/azureTrafficCollectors.js +0 -9
  64. package/dist/esm/operationsInterfaces/azureTrafficCollectors.js.map +7 -1
  65. package/dist/esm/operationsInterfaces/azureTrafficCollectorsByResourceGroup.js +0 -9
  66. package/dist/esm/operationsInterfaces/azureTrafficCollectorsByResourceGroup.js.map +7 -1
  67. package/dist/esm/operationsInterfaces/azureTrafficCollectorsBySubscription.js +0 -9
  68. package/dist/esm/operationsInterfaces/azureTrafficCollectorsBySubscription.js.map +7 -1
  69. package/dist/esm/operationsInterfaces/collectorPolicies.js +0 -9
  70. package/dist/esm/operationsInterfaces/collectorPolicies.js.map +7 -1
  71. package/dist/esm/operationsInterfaces/index.js +0 -8
  72. package/dist/esm/operationsInterfaces/index.js.map +7 -1
  73. package/dist/esm/operationsInterfaces/networkFunction.js +0 -9
  74. package/dist/esm/operationsInterfaces/networkFunction.js.map +7 -1
  75. package/dist/esm/pagingHelper.js +17 -28
  76. package/dist/esm/pagingHelper.js.map +7 -1
  77. package/package.json +4 -21
@@ -1,401 +1,450 @@
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
1
  import { setContinuationToken } from "../pagingHelper.js";
9
2
  import * as coreClient from "@azure/core-client";
10
3
  import * as Mappers from "../models/mappers.js";
11
4
  import * as Parameters from "../models/parameters.js";
12
5
  import { LroEngine } from "@azure/core-lro";
13
6
  import { LroImpl } from "../lroImpl.js";
14
- /// <reference lib="esnext.asynciterable" />
15
- /** Class containing CollectorPolicies operations. */
16
- export class CollectorPoliciesImpl {
17
- client;
18
- /**
19
- * Initialize a new instance of the class CollectorPolicies class.
20
- * @param client Reference to the service client
21
- */
22
- constructor(client) {
23
- this.client = client;
7
+ class CollectorPoliciesImpl {
8
+ client;
9
+ /**
10
+ * Initialize a new instance of the class CollectorPolicies class.
11
+ * @param client Reference to the service client
12
+ */
13
+ constructor(client) {
14
+ this.client = client;
15
+ }
16
+ /**
17
+ * Return list of Collector policies in a Azure Traffic Collector
18
+ * @param resourceGroupName The name of the resource group.
19
+ * @param azureTrafficCollectorName Azure Traffic Collector name
20
+ * @param options The options parameters.
21
+ */
22
+ list(resourceGroupName, azureTrafficCollectorName, options) {
23
+ const iter = this.listPagingAll(
24
+ resourceGroupName,
25
+ azureTrafficCollectorName,
26
+ options
27
+ );
28
+ return {
29
+ next() {
30
+ return iter.next();
31
+ },
32
+ [Symbol.asyncIterator]() {
33
+ return this;
34
+ },
35
+ byPage: (settings) => {
36
+ if (settings?.maxPageSize) {
37
+ throw new Error("maxPageSize is not supported by this operation.");
38
+ }
39
+ return this.listPagingPage(
40
+ resourceGroupName,
41
+ azureTrafficCollectorName,
42
+ options,
43
+ settings
44
+ );
45
+ }
46
+ };
47
+ }
48
+ async *listPagingPage(resourceGroupName, azureTrafficCollectorName, options, settings) {
49
+ let result;
50
+ let continuationToken = settings?.continuationToken;
51
+ if (!continuationToken) {
52
+ result = await this._list(
53
+ resourceGroupName,
54
+ azureTrafficCollectorName,
55
+ options
56
+ );
57
+ let page = result.value || [];
58
+ continuationToken = result.nextLink;
59
+ setContinuationToken(page, continuationToken);
60
+ yield page;
61
+ }
62
+ while (continuationToken) {
63
+ result = await this._listNext(
64
+ resourceGroupName,
65
+ azureTrafficCollectorName,
66
+ continuationToken,
67
+ options
68
+ );
69
+ continuationToken = result.nextLink;
70
+ let page = result.value || [];
71
+ setContinuationToken(page, continuationToken);
72
+ yield page;
24
73
  }
25
- /**
26
- * Return list of Collector policies in a Azure Traffic Collector
27
- * @param resourceGroupName The name of the resource group.
28
- * @param azureTrafficCollectorName Azure Traffic Collector name
29
- * @param options The options parameters.
30
- */
31
- list(resourceGroupName, azureTrafficCollectorName, options) {
32
- const iter = this.listPagingAll(resourceGroupName, azureTrafficCollectorName, options);
33
- return {
34
- next() {
35
- return iter.next();
36
- },
37
- [Symbol.asyncIterator]() {
38
- return this;
39
- },
40
- byPage: (settings) => {
41
- if (settings?.maxPageSize) {
42
- throw new Error("maxPageSize is not supported by this operation.");
43
- }
44
- return this.listPagingPage(resourceGroupName, azureTrafficCollectorName, options, settings);
45
- }
46
- };
74
+ }
75
+ async *listPagingAll(resourceGroupName, azureTrafficCollectorName, options) {
76
+ for await (const page of this.listPagingPage(
77
+ resourceGroupName,
78
+ azureTrafficCollectorName,
79
+ options
80
+ )) {
81
+ yield* page;
47
82
  }
48
- async *listPagingPage(resourceGroupName, azureTrafficCollectorName, options, settings) {
49
- let result;
50
- let continuationToken = settings?.continuationToken;
51
- if (!continuationToken) {
52
- result = await this._list(resourceGroupName, azureTrafficCollectorName, options);
53
- let page = result.value || [];
54
- continuationToken = result.nextLink;
55
- setContinuationToken(page, continuationToken);
56
- yield page;
83
+ }
84
+ /**
85
+ * Return list of Collector policies in a Azure Traffic Collector
86
+ * @param resourceGroupName The name of the resource group.
87
+ * @param azureTrafficCollectorName Azure Traffic Collector name
88
+ * @param options The options parameters.
89
+ */
90
+ _list(resourceGroupName, azureTrafficCollectorName, options) {
91
+ return this.client.sendOperationRequest(
92
+ { resourceGroupName, azureTrafficCollectorName, options },
93
+ listOperationSpec
94
+ );
95
+ }
96
+ /**
97
+ * Gets the collector policy in a specified Traffic Collector
98
+ * @param resourceGroupName The name of the resource group.
99
+ * @param azureTrafficCollectorName Azure Traffic Collector name
100
+ * @param collectorPolicyName Collector Policy Name
101
+ * @param options The options parameters.
102
+ */
103
+ get(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options) {
104
+ return this.client.sendOperationRequest(
105
+ {
106
+ resourceGroupName,
107
+ azureTrafficCollectorName,
108
+ collectorPolicyName,
109
+ options
110
+ },
111
+ getOperationSpec
112
+ );
113
+ }
114
+ /**
115
+ * Creates or updates a Collector Policy resource
116
+ * @param resourceGroupName The name of the resource group.
117
+ * @param azureTrafficCollectorName Azure Traffic Collector name
118
+ * @param collectorPolicyName Collector Policy Name
119
+ * @param location Resource location.
120
+ * @param options The options parameters.
121
+ */
122
+ async beginCreateOrUpdate(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, location, options) {
123
+ const directSendOperation = async (args, spec) => {
124
+ return this.client.sendOperationRequest(args, spec);
125
+ };
126
+ const sendOperation = async (args, spec) => {
127
+ let currentRawResponse = void 0;
128
+ const providedCallback = args.options?.onResponse;
129
+ const callback = (rawResponse, flatResponse2) => {
130
+ currentRawResponse = rawResponse;
131
+ providedCallback?.(rawResponse, flatResponse2);
132
+ };
133
+ const updatedArgs = {
134
+ ...args,
135
+ options: {
136
+ ...args.options,
137
+ onResponse: callback
57
138
  }
58
- while (continuationToken) {
59
- result = await this._listNext(resourceGroupName, azureTrafficCollectorName, continuationToken, options);
60
- continuationToken = result.nextLink;
61
- let page = result.value || [];
62
- setContinuationToken(page, continuationToken);
63
- yield page;
139
+ };
140
+ const flatResponse = await directSendOperation(updatedArgs, spec);
141
+ return {
142
+ flatResponse,
143
+ rawResponse: {
144
+ statusCode: currentRawResponse.status,
145
+ body: currentRawResponse.parsedBody,
146
+ headers: currentRawResponse.headers.toJSON()
64
147
  }
65
- }
66
- async *listPagingAll(resourceGroupName, azureTrafficCollectorName, options) {
67
- for await (const page of this.listPagingPage(resourceGroupName, azureTrafficCollectorName, options)) {
68
- yield* page;
148
+ };
149
+ };
150
+ const lro = new LroImpl(
151
+ sendOperation,
152
+ {
153
+ resourceGroupName,
154
+ azureTrafficCollectorName,
155
+ collectorPolicyName,
156
+ location,
157
+ options
158
+ },
159
+ createOrUpdateOperationSpec
160
+ );
161
+ const poller = new LroEngine(lro, {
162
+ resumeFrom: options?.resumeFrom,
163
+ intervalInMs: options?.updateIntervalInMs,
164
+ lroResourceLocationConfig: "azure-async-operation"
165
+ });
166
+ await poller.poll();
167
+ return poller;
168
+ }
169
+ /**
170
+ * Creates or updates a Collector Policy resource
171
+ * @param resourceGroupName The name of the resource group.
172
+ * @param azureTrafficCollectorName Azure Traffic Collector name
173
+ * @param collectorPolicyName Collector Policy Name
174
+ * @param location Resource location.
175
+ * @param options The options parameters.
176
+ */
177
+ async beginCreateOrUpdateAndWait(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, location, options) {
178
+ const poller = await this.beginCreateOrUpdate(
179
+ resourceGroupName,
180
+ azureTrafficCollectorName,
181
+ collectorPolicyName,
182
+ location,
183
+ options
184
+ );
185
+ return poller.pollUntilDone();
186
+ }
187
+ /**
188
+ * Deletes a specified Collector Policy resource.
189
+ * @param resourceGroupName The name of the resource group.
190
+ * @param azureTrafficCollectorName Azure Traffic Collector name
191
+ * @param collectorPolicyName Collector Policy Name
192
+ * @param options The options parameters.
193
+ */
194
+ async beginDelete(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options) {
195
+ const directSendOperation = async (args, spec) => {
196
+ return this.client.sendOperationRequest(args, spec);
197
+ };
198
+ const sendOperation = async (args, spec) => {
199
+ let currentRawResponse = void 0;
200
+ const providedCallback = args.options?.onResponse;
201
+ const callback = (rawResponse, flatResponse2) => {
202
+ currentRawResponse = rawResponse;
203
+ providedCallback?.(rawResponse, flatResponse2);
204
+ };
205
+ const updatedArgs = {
206
+ ...args,
207
+ options: {
208
+ ...args.options,
209
+ onResponse: callback
69
210
  }
70
- }
71
- /**
72
- * Return list of Collector policies in a Azure Traffic Collector
73
- * @param resourceGroupName The name of the resource group.
74
- * @param azureTrafficCollectorName Azure Traffic Collector name
75
- * @param options The options parameters.
76
- */
77
- _list(resourceGroupName, azureTrafficCollectorName, options) {
78
- return this.client.sendOperationRequest({ resourceGroupName, azureTrafficCollectorName, options }, listOperationSpec);
79
- }
80
- /**
81
- * Gets the collector policy in a specified Traffic Collector
82
- * @param resourceGroupName The name of the resource group.
83
- * @param azureTrafficCollectorName Azure Traffic Collector name
84
- * @param collectorPolicyName Collector Policy Name
85
- * @param options The options parameters.
86
- */
87
- get(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options) {
88
- return this.client.sendOperationRequest({
89
- resourceGroupName,
90
- azureTrafficCollectorName,
91
- collectorPolicyName,
92
- options
93
- }, getOperationSpec);
94
- }
95
- /**
96
- * Creates or updates a Collector Policy resource
97
- * @param resourceGroupName The name of the resource group.
98
- * @param azureTrafficCollectorName Azure Traffic Collector name
99
- * @param collectorPolicyName Collector Policy Name
100
- * @param location Resource location.
101
- * @param options The options parameters.
102
- */
103
- async beginCreateOrUpdate(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, location, options) {
104
- const directSendOperation = async (args, spec) => {
105
- return this.client.sendOperationRequest(args, spec);
106
- };
107
- const sendOperation = async (args, spec) => {
108
- let currentRawResponse = undefined;
109
- const providedCallback = args.options?.onResponse;
110
- const callback = (rawResponse, flatResponse) => {
111
- currentRawResponse = rawResponse;
112
- providedCallback?.(rawResponse, flatResponse);
113
- };
114
- const updatedArgs = {
115
- ...args,
116
- options: {
117
- ...args.options,
118
- onResponse: callback
119
- }
120
- };
121
- const flatResponse = await directSendOperation(updatedArgs, spec);
122
- return {
123
- flatResponse,
124
- rawResponse: {
125
- statusCode: currentRawResponse.status,
126
- body: currentRawResponse.parsedBody,
127
- headers: currentRawResponse.headers.toJSON()
128
- }
129
- };
130
- };
131
- const lro = new LroImpl(sendOperation, {
132
- resourceGroupName,
133
- azureTrafficCollectorName,
134
- collectorPolicyName,
135
- location,
136
- options
137
- }, createOrUpdateOperationSpec);
138
- const poller = new LroEngine(lro, {
139
- resumeFrom: options?.resumeFrom,
140
- intervalInMs: options?.updateIntervalInMs,
141
- lroResourceLocationConfig: "azure-async-operation"
142
- });
143
- await poller.poll();
144
- return poller;
145
- }
146
- /**
147
- * Creates or updates a Collector Policy resource
148
- * @param resourceGroupName The name of the resource group.
149
- * @param azureTrafficCollectorName Azure Traffic Collector name
150
- * @param collectorPolicyName Collector Policy Name
151
- * @param location Resource location.
152
- * @param options The options parameters.
153
- */
154
- async beginCreateOrUpdateAndWait(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, location, options) {
155
- const poller = await this.beginCreateOrUpdate(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, location, options);
156
- return poller.pollUntilDone();
157
- }
158
- /**
159
- * Deletes a specified Collector Policy resource.
160
- * @param resourceGroupName The name of the resource group.
161
- * @param azureTrafficCollectorName Azure Traffic Collector name
162
- * @param collectorPolicyName Collector Policy Name
163
- * @param options The options parameters.
164
- */
165
- async beginDelete(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options) {
166
- const directSendOperation = async (args, spec) => {
167
- return this.client.sendOperationRequest(args, spec);
168
- };
169
- const sendOperation = async (args, spec) => {
170
- let currentRawResponse = undefined;
171
- const providedCallback = args.options?.onResponse;
172
- const callback = (rawResponse, flatResponse) => {
173
- currentRawResponse = rawResponse;
174
- providedCallback?.(rawResponse, flatResponse);
175
- };
176
- const updatedArgs = {
177
- ...args,
178
- options: {
179
- ...args.options,
180
- onResponse: callback
181
- }
182
- };
183
- const flatResponse = await directSendOperation(updatedArgs, spec);
184
- return {
185
- flatResponse,
186
- rawResponse: {
187
- statusCode: currentRawResponse.status,
188
- body: currentRawResponse.parsedBody,
189
- headers: currentRawResponse.headers.toJSON()
190
- }
191
- };
192
- };
193
- const lro = new LroImpl(sendOperation, {
194
- resourceGroupName,
195
- azureTrafficCollectorName,
196
- collectorPolicyName,
197
- options
198
- }, deleteOperationSpec);
199
- const poller = new LroEngine(lro, {
200
- resumeFrom: options?.resumeFrom,
201
- intervalInMs: options?.updateIntervalInMs,
202
- lroResourceLocationConfig: "location"
203
- });
204
- await poller.poll();
205
- return poller;
206
- }
207
- /**
208
- * Deletes a specified Collector Policy resource.
209
- * @param resourceGroupName The name of the resource group.
210
- * @param azureTrafficCollectorName Azure Traffic Collector name
211
- * @param collectorPolicyName Collector Policy Name
212
- * @param options The options parameters.
213
- */
214
- async beginDeleteAndWait(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options) {
215
- const poller = await this.beginDelete(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options);
216
- return poller.pollUntilDone();
217
- }
218
- /**
219
- * Updates the specified Collector Policy tags.
220
- * @param resourceGroupName The name of the resource group.
221
- * @param azureTrafficCollectorName Azure Traffic Collector name
222
- * @param collectorPolicyName Collector Policy Name
223
- * @param parameters Parameters supplied to update Collector Policy tags.
224
- * @param options The options parameters.
225
- */
226
- updateTags(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, parameters, options) {
227
- return this.client.sendOperationRequest({
228
- resourceGroupName,
229
- azureTrafficCollectorName,
230
- collectorPolicyName,
231
- parameters,
232
- options
233
- }, updateTagsOperationSpec);
234
- }
235
- /**
236
- * ListNext
237
- * @param resourceGroupName The name of the resource group.
238
- * @param azureTrafficCollectorName Azure Traffic Collector name
239
- * @param nextLink The nextLink from the previous successful call to the List method.
240
- * @param options The options parameters.
241
- */
242
- _listNext(resourceGroupName, azureTrafficCollectorName, nextLink, options) {
243
- return this.client.sendOperationRequest({ resourceGroupName, azureTrafficCollectorName, nextLink, options }, listNextOperationSpec);
244
- }
211
+ };
212
+ const flatResponse = await directSendOperation(updatedArgs, spec);
213
+ return {
214
+ flatResponse,
215
+ rawResponse: {
216
+ statusCode: currentRawResponse.status,
217
+ body: currentRawResponse.parsedBody,
218
+ headers: currentRawResponse.headers.toJSON()
219
+ }
220
+ };
221
+ };
222
+ const lro = new LroImpl(
223
+ sendOperation,
224
+ {
225
+ resourceGroupName,
226
+ azureTrafficCollectorName,
227
+ collectorPolicyName,
228
+ options
229
+ },
230
+ deleteOperationSpec
231
+ );
232
+ const poller = new LroEngine(lro, {
233
+ resumeFrom: options?.resumeFrom,
234
+ intervalInMs: options?.updateIntervalInMs,
235
+ lroResourceLocationConfig: "location"
236
+ });
237
+ await poller.poll();
238
+ return poller;
239
+ }
240
+ /**
241
+ * Deletes a specified Collector Policy resource.
242
+ * @param resourceGroupName The name of the resource group.
243
+ * @param azureTrafficCollectorName Azure Traffic Collector name
244
+ * @param collectorPolicyName Collector Policy Name
245
+ * @param options The options parameters.
246
+ */
247
+ async beginDeleteAndWait(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, options) {
248
+ const poller = await this.beginDelete(
249
+ resourceGroupName,
250
+ azureTrafficCollectorName,
251
+ collectorPolicyName,
252
+ options
253
+ );
254
+ return poller.pollUntilDone();
255
+ }
256
+ /**
257
+ * Updates the specified Collector Policy tags.
258
+ * @param resourceGroupName The name of the resource group.
259
+ * @param azureTrafficCollectorName Azure Traffic Collector name
260
+ * @param collectorPolicyName Collector Policy Name
261
+ * @param parameters Parameters supplied to update Collector Policy tags.
262
+ * @param options The options parameters.
263
+ */
264
+ updateTags(resourceGroupName, azureTrafficCollectorName, collectorPolicyName, parameters, options) {
265
+ return this.client.sendOperationRequest(
266
+ {
267
+ resourceGroupName,
268
+ azureTrafficCollectorName,
269
+ collectorPolicyName,
270
+ parameters,
271
+ options
272
+ },
273
+ updateTagsOperationSpec
274
+ );
275
+ }
276
+ /**
277
+ * ListNext
278
+ * @param resourceGroupName The name of the resource group.
279
+ * @param azureTrafficCollectorName Azure Traffic Collector name
280
+ * @param nextLink The nextLink from the previous successful call to the List method.
281
+ * @param options The options parameters.
282
+ */
283
+ _listNext(resourceGroupName, azureTrafficCollectorName, nextLink, options) {
284
+ return this.client.sendOperationRequest(
285
+ { resourceGroupName, azureTrafficCollectorName, nextLink, options },
286
+ listNextOperationSpec
287
+ );
288
+ }
245
289
  }
246
- // Operation Specifications
247
- const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
290
+ const serializer = coreClient.createSerializer(
291
+ Mappers,
292
+ /* isXml */
293
+ false
294
+ );
248
295
  const listOperationSpec = {
249
- path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies",
250
- httpMethod: "GET",
251
- responses: {
252
- 200: {
253
- bodyMapper: Mappers.CollectorPolicyListResult
254
- },
255
- default: {
256
- bodyMapper: Mappers.CloudError
257
- }
296
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies",
297
+ httpMethod: "GET",
298
+ responses: {
299
+ 200: {
300
+ bodyMapper: Mappers.CollectorPolicyListResult
258
301
  },
259
- queryParameters: [Parameters.apiVersion],
260
- urlParameters: [
261
- Parameters.$host,
262
- Parameters.subscriptionId,
263
- Parameters.resourceGroupName,
264
- Parameters.azureTrafficCollectorName
265
- ],
266
- headerParameters: [Parameters.accept],
267
- serializer
302
+ default: {
303
+ bodyMapper: Mappers.CloudError
304
+ }
305
+ },
306
+ queryParameters: [Parameters.apiVersion],
307
+ urlParameters: [
308
+ Parameters.$host,
309
+ Parameters.subscriptionId,
310
+ Parameters.resourceGroupName,
311
+ Parameters.azureTrafficCollectorName
312
+ ],
313
+ headerParameters: [Parameters.accept],
314
+ serializer
268
315
  };
269
316
  const getOperationSpec = {
270
- path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
271
- httpMethod: "GET",
272
- responses: {
273
- 200: {
274
- bodyMapper: Mappers.CollectorPolicy
275
- },
276
- default: {
277
- bodyMapper: Mappers.CloudError
278
- }
317
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
318
+ httpMethod: "GET",
319
+ responses: {
320
+ 200: {
321
+ bodyMapper: Mappers.CollectorPolicy
279
322
  },
280
- queryParameters: [Parameters.apiVersion],
281
- urlParameters: [
282
- Parameters.$host,
283
- Parameters.subscriptionId,
284
- Parameters.resourceGroupName,
285
- Parameters.azureTrafficCollectorName,
286
- Parameters.collectorPolicyName
287
- ],
288
- headerParameters: [Parameters.accept],
289
- serializer
323
+ default: {
324
+ bodyMapper: Mappers.CloudError
325
+ }
326
+ },
327
+ queryParameters: [Parameters.apiVersion],
328
+ urlParameters: [
329
+ Parameters.$host,
330
+ Parameters.subscriptionId,
331
+ Parameters.resourceGroupName,
332
+ Parameters.azureTrafficCollectorName,
333
+ Parameters.collectorPolicyName
334
+ ],
335
+ headerParameters: [Parameters.accept],
336
+ serializer
290
337
  };
291
338
  const createOrUpdateOperationSpec = {
292
- path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
293
- httpMethod: "PUT",
294
- responses: {
295
- 200: {
296
- bodyMapper: Mappers.CollectorPolicy
297
- },
298
- 201: {
299
- bodyMapper: Mappers.CollectorPolicy
300
- },
301
- 202: {
302
- bodyMapper: Mappers.CollectorPolicy
303
- },
304
- 204: {
305
- bodyMapper: Mappers.CollectorPolicy
306
- },
307
- default: {
308
- bodyMapper: Mappers.CloudError
309
- }
339
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
340
+ httpMethod: "PUT",
341
+ responses: {
342
+ 200: {
343
+ bodyMapper: Mappers.CollectorPolicy
344
+ },
345
+ 201: {
346
+ bodyMapper: Mappers.CollectorPolicy
310
347
  },
311
- requestBody: {
312
- parameterPath: {
313
- location: ["location"],
314
- tags: ["options", "tags"],
315
- ingestionPolicy: ["options", "ingestionPolicy"],
316
- emissionPolicies: ["options", "emissionPolicies"]
317
- },
318
- mapper: { ...Mappers.CollectorPolicy, required: true }
348
+ 202: {
349
+ bodyMapper: Mappers.CollectorPolicy
319
350
  },
320
- queryParameters: [Parameters.apiVersion],
321
- urlParameters: [
322
- Parameters.$host,
323
- Parameters.subscriptionId,
324
- Parameters.resourceGroupName,
325
- Parameters.azureTrafficCollectorName,
326
- Parameters.collectorPolicyName
327
- ],
328
- headerParameters: [Parameters.accept, Parameters.contentType],
329
- mediaType: "json",
330
- serializer
351
+ 204: {
352
+ bodyMapper: Mappers.CollectorPolicy
353
+ },
354
+ default: {
355
+ bodyMapper: Mappers.CloudError
356
+ }
357
+ },
358
+ requestBody: {
359
+ parameterPath: {
360
+ location: ["location"],
361
+ tags: ["options", "tags"],
362
+ ingestionPolicy: ["options", "ingestionPolicy"],
363
+ emissionPolicies: ["options", "emissionPolicies"]
364
+ },
365
+ mapper: { ...Mappers.CollectorPolicy, required: true }
366
+ },
367
+ queryParameters: [Parameters.apiVersion],
368
+ urlParameters: [
369
+ Parameters.$host,
370
+ Parameters.subscriptionId,
371
+ Parameters.resourceGroupName,
372
+ Parameters.azureTrafficCollectorName,
373
+ Parameters.collectorPolicyName
374
+ ],
375
+ headerParameters: [Parameters.accept, Parameters.contentType],
376
+ mediaType: "json",
377
+ serializer
331
378
  };
332
379
  const deleteOperationSpec = {
333
- path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
334
- httpMethod: "DELETE",
335
- responses: {
336
- 200: {},
337
- 201: {},
338
- 202: {},
339
- 204: {},
340
- default: {
341
- bodyMapper: Mappers.CloudError
342
- }
343
- },
344
- queryParameters: [Parameters.apiVersion],
345
- urlParameters: [
346
- Parameters.$host,
347
- Parameters.subscriptionId,
348
- Parameters.resourceGroupName,
349
- Parameters.azureTrafficCollectorName,
350
- Parameters.collectorPolicyName
351
- ],
352
- headerParameters: [Parameters.accept],
353
- serializer
380
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
381
+ httpMethod: "DELETE",
382
+ responses: {
383
+ 200: {},
384
+ 201: {},
385
+ 202: {},
386
+ 204: {},
387
+ default: {
388
+ bodyMapper: Mappers.CloudError
389
+ }
390
+ },
391
+ queryParameters: [Parameters.apiVersion],
392
+ urlParameters: [
393
+ Parameters.$host,
394
+ Parameters.subscriptionId,
395
+ Parameters.resourceGroupName,
396
+ Parameters.azureTrafficCollectorName,
397
+ Parameters.collectorPolicyName
398
+ ],
399
+ headerParameters: [Parameters.accept],
400
+ serializer
354
401
  };
355
402
  const updateTagsOperationSpec = {
356
- path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
357
- httpMethod: "PATCH",
358
- responses: {
359
- 200: {
360
- bodyMapper: Mappers.CollectorPolicy
361
- },
362
- default: {
363
- bodyMapper: Mappers.CloudError
364
- }
403
+ path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetworkFunction/azureTrafficCollectors/{azureTrafficCollectorName}/collectorPolicies/{collectorPolicyName}",
404
+ httpMethod: "PATCH",
405
+ responses: {
406
+ 200: {
407
+ bodyMapper: Mappers.CollectorPolicy
365
408
  },
366
- requestBody: Parameters.parameters1,
367
- queryParameters: [Parameters.apiVersion],
368
- urlParameters: [
369
- Parameters.$host,
370
- Parameters.subscriptionId,
371
- Parameters.resourceGroupName,
372
- Parameters.azureTrafficCollectorName,
373
- Parameters.collectorPolicyName
374
- ],
375
- headerParameters: [Parameters.accept, Parameters.contentType],
376
- mediaType: "json",
377
- serializer
409
+ default: {
410
+ bodyMapper: Mappers.CloudError
411
+ }
412
+ },
413
+ requestBody: Parameters.parameters1,
414
+ queryParameters: [Parameters.apiVersion],
415
+ urlParameters: [
416
+ Parameters.$host,
417
+ Parameters.subscriptionId,
418
+ Parameters.resourceGroupName,
419
+ Parameters.azureTrafficCollectorName,
420
+ Parameters.collectorPolicyName
421
+ ],
422
+ headerParameters: [Parameters.accept, Parameters.contentType],
423
+ mediaType: "json",
424
+ serializer
378
425
  };
379
426
  const listNextOperationSpec = {
380
- path: "{nextLink}",
381
- httpMethod: "GET",
382
- responses: {
383
- 200: {
384
- bodyMapper: Mappers.CollectorPolicyListResult
385
- },
386
- default: {
387
- bodyMapper: Mappers.CloudError
388
- }
427
+ path: "{nextLink}",
428
+ httpMethod: "GET",
429
+ responses: {
430
+ 200: {
431
+ bodyMapper: Mappers.CollectorPolicyListResult
389
432
  },
390
- queryParameters: [Parameters.apiVersion],
391
- urlParameters: [
392
- Parameters.$host,
393
- Parameters.subscriptionId,
394
- Parameters.nextLink,
395
- Parameters.resourceGroupName,
396
- Parameters.azureTrafficCollectorName
397
- ],
398
- headerParameters: [Parameters.accept],
399
- serializer
433
+ default: {
434
+ bodyMapper: Mappers.CloudError
435
+ }
436
+ },
437
+ queryParameters: [Parameters.apiVersion],
438
+ urlParameters: [
439
+ Parameters.$host,
440
+ Parameters.subscriptionId,
441
+ Parameters.nextLink,
442
+ Parameters.resourceGroupName,
443
+ Parameters.azureTrafficCollectorName
444
+ ],
445
+ headerParameters: [Parameters.accept],
446
+ serializer
447
+ };
448
+ export {
449
+ CollectorPoliciesImpl
400
450
  };
401
- //# sourceMappingURL=collectorPolicies.js.map