@azure/arm-reservations 9.0.1-alpha.20250103.1 → 9.0.1-alpha.20250106.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.
package/dist/index.js CHANGED
@@ -47,14 +47,14 @@ function getContinuationToken(page) {
47
47
  if (typeof page !== "object" || page === null) {
48
48
  return undefined;
49
49
  }
50
- return (_a = pageMap.get(page)) === null || _a === void 0 ? void 0 : _a.continuationToken;
50
+ return (_a = pageMap.get(page)) === null || _a === undefined ? undefined : _a.continuationToken;
51
51
  }
52
52
  function setContinuationToken(page, continuationToken) {
53
53
  var _a;
54
54
  if (typeof page !== "object" || page === null || !continuationToken) {
55
55
  return;
56
56
  }
57
- const pageInfo = (_a = pageMap.get(page)) !== null && _a !== void 0 ? _a : {};
57
+ const pageInfo = (_a = pageMap.get(page)) !== null && _a !== undefined ? _a : {};
58
58
  pageInfo.continuationToken = continuationToken;
59
59
  pageMap.set(page, pageInfo);
60
60
  }
@@ -4911,7 +4911,7 @@ function createLroSpec(inputs) {
4911
4911
  sendInitialRequest: () => sendOperationFn(args, spec),
4912
4912
  sendPollRequest: (path, options) => {
4913
4913
  const restSpec = tslib.__rest(spec, ["requestBody"]);
4914
- return sendOperationFn(args, Object.assign(Object.assign({}, restSpec), { httpMethod: "GET", path, abortSignal: options === null || options === void 0 ? void 0 : options.abortSignal }));
4914
+ return sendOperationFn(args, Object.assign(Object.assign({}, restSpec), { httpMethod: "GET", path, abortSignal: options === null || options === undefined ? undefined : options.abortSignal }));
4915
4915
  }
4916
4916
  };
4917
4917
  }
@@ -4948,7 +4948,7 @@ class ReservationImpl {
4948
4948
  return this;
4949
4949
  },
4950
4950
  byPage: (settings) => {
4951
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
4951
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
4952
4952
  throw new Error("maxPageSize is not supported by this operation.");
4953
4953
  }
4954
4954
  return this.listPagingPage(reservationOrderId, options, settings);
@@ -4958,7 +4958,7 @@ class ReservationImpl {
4958
4958
  listPagingPage(reservationOrderId, options, settings) {
4959
4959
  return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
4960
4960
  let result;
4961
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
4961
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
4962
4962
  if (!continuationToken) {
4963
4963
  result = yield tslib.__await(this._list(reservationOrderId, options));
4964
4964
  let page = result.value || [];
@@ -5011,7 +5011,7 @@ class ReservationImpl {
5011
5011
  return this;
5012
5012
  },
5013
5013
  byPage: (settings) => {
5014
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
5014
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
5015
5015
  throw new Error("maxPageSize is not supported by this operation.");
5016
5016
  }
5017
5017
  return this.listRevisionsPagingPage(reservationOrderId, reservationId, options, settings);
@@ -5021,7 +5021,7 @@ class ReservationImpl {
5021
5021
  listRevisionsPagingPage(reservationOrderId, reservationId, options, settings) {
5022
5022
  return tslib.__asyncGenerator(this, arguments, function* listRevisionsPagingPage_1() {
5023
5023
  let result;
5024
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
5024
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
5025
5025
  if (!continuationToken) {
5026
5026
  result = yield tslib.__await(this._listRevisions(reservationOrderId, reservationId, options));
5027
5027
  let page = result.value || [];
@@ -5073,7 +5073,7 @@ class ReservationImpl {
5073
5073
  return this;
5074
5074
  },
5075
5075
  byPage: (settings) => {
5076
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
5076
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
5077
5077
  throw new Error("maxPageSize is not supported by this operation.");
5078
5078
  }
5079
5079
  return this.listAllPagingPage(options, settings);
@@ -5083,7 +5083,7 @@ class ReservationImpl {
5083
5083
  listAllPagingPage(options, settings) {
5084
5084
  return tslib.__asyncGenerator(this, arguments, function* listAllPagingPage_1() {
5085
5085
  let result;
5086
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
5086
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
5087
5087
  if (!continuationToken) {
5088
5088
  result = yield tslib.__await(this._listAll(options));
5089
5089
  let page = result.value || [];
@@ -5129,17 +5129,17 @@ class ReservationImpl {
5129
5129
  * @param options The options parameters.
5130
5130
  */
5131
5131
  beginAvailableScopes(reservationOrderId, reservationId, body, options) {
5132
- return tslib.__awaiter(this, void 0, void 0, function* () {
5133
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5132
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5133
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5134
5134
  return this.client.sendOperationRequest(args, spec);
5135
5135
  });
5136
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5136
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5137
5137
  var _a;
5138
5138
  let currentRawResponse = undefined;
5139
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
5139
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
5140
5140
  const callback = (rawResponse, flatResponse) => {
5141
5141
  currentRawResponse = rawResponse;
5142
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
5142
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
5143
5143
  };
5144
5144
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
5145
5145
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -5158,8 +5158,8 @@ class ReservationImpl {
5158
5158
  spec: availableScopesOperationSpec
5159
5159
  });
5160
5160
  const poller = yield coreLro.createHttpPoller(lro, {
5161
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
5162
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
5161
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
5162
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs
5163
5163
  });
5164
5164
  yield poller.poll();
5165
5165
  return poller;
@@ -5174,7 +5174,7 @@ class ReservationImpl {
5174
5174
  * @param options The options parameters.
5175
5175
  */
5176
5176
  beginAvailableScopesAndWait(reservationOrderId, reservationId, body, options) {
5177
- return tslib.__awaiter(this, void 0, void 0, function* () {
5177
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5178
5178
  const poller = yield this.beginAvailableScopes(reservationOrderId, reservationId, body, options);
5179
5179
  return poller.pollUntilDone();
5180
5180
  });
@@ -5186,17 +5186,17 @@ class ReservationImpl {
5186
5186
  * @param options The options parameters.
5187
5187
  */
5188
5188
  beginSplit(reservationOrderId, body, options) {
5189
- return tslib.__awaiter(this, void 0, void 0, function* () {
5190
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5189
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5190
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5191
5191
  return this.client.sendOperationRequest(args, spec);
5192
5192
  });
5193
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5193
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5194
5194
  var _a;
5195
5195
  let currentRawResponse = undefined;
5196
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
5196
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
5197
5197
  const callback = (rawResponse, flatResponse) => {
5198
5198
  currentRawResponse = rawResponse;
5199
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
5199
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
5200
5200
  };
5201
5201
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
5202
5202
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -5215,8 +5215,8 @@ class ReservationImpl {
5215
5215
  spec: splitOperationSpec
5216
5216
  });
5217
5217
  const poller = yield coreLro.createHttpPoller(lro, {
5218
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
5219
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
5218
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
5219
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
5220
5220
  resourceLocationConfig: "location"
5221
5221
  });
5222
5222
  yield poller.poll();
@@ -5230,7 +5230,7 @@ class ReservationImpl {
5230
5230
  * @param options The options parameters.
5231
5231
  */
5232
5232
  beginSplitAndWait(reservationOrderId, body, options) {
5233
- return tslib.__awaiter(this, void 0, void 0, function* () {
5233
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5234
5234
  const poller = yield this.beginSplit(reservationOrderId, body, options);
5235
5235
  return poller.pollUntilDone();
5236
5236
  });
@@ -5243,17 +5243,17 @@ class ReservationImpl {
5243
5243
  * @param options The options parameters.
5244
5244
  */
5245
5245
  beginMerge(reservationOrderId, body, options) {
5246
- return tslib.__awaiter(this, void 0, void 0, function* () {
5247
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5246
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5247
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5248
5248
  return this.client.sendOperationRequest(args, spec);
5249
5249
  });
5250
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5250
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5251
5251
  var _a;
5252
5252
  let currentRawResponse = undefined;
5253
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
5253
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
5254
5254
  const callback = (rawResponse, flatResponse) => {
5255
5255
  currentRawResponse = rawResponse;
5256
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
5256
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
5257
5257
  };
5258
5258
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
5259
5259
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -5272,8 +5272,8 @@ class ReservationImpl {
5272
5272
  spec: mergeOperationSpec
5273
5273
  });
5274
5274
  const poller = yield coreLro.createHttpPoller(lro, {
5275
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
5276
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
5275
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
5276
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
5277
5277
  resourceLocationConfig: "location"
5278
5278
  });
5279
5279
  yield poller.poll();
@@ -5288,7 +5288,7 @@ class ReservationImpl {
5288
5288
  * @param options The options parameters.
5289
5289
  */
5290
5290
  beginMergeAndWait(reservationOrderId, body, options) {
5291
- return tslib.__awaiter(this, void 0, void 0, function* () {
5291
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5292
5292
  const poller = yield this.beginMerge(reservationOrderId, body, options);
5293
5293
  return poller.pollUntilDone();
5294
5294
  });
@@ -5318,17 +5318,17 @@ class ReservationImpl {
5318
5318
  * @param options The options parameters.
5319
5319
  */
5320
5320
  beginUpdate(reservationOrderId, reservationId, parameters, options) {
5321
- return tslib.__awaiter(this, void 0, void 0, function* () {
5322
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5321
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5322
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5323
5323
  return this.client.sendOperationRequest(args, spec);
5324
5324
  });
5325
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5325
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5326
5326
  var _a;
5327
5327
  let currentRawResponse = undefined;
5328
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
5328
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
5329
5329
  const callback = (rawResponse, flatResponse) => {
5330
5330
  currentRawResponse = rawResponse;
5331
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
5331
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
5332
5332
  };
5333
5333
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
5334
5334
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -5347,8 +5347,8 @@ class ReservationImpl {
5347
5347
  spec: updateOperationSpec$1
5348
5348
  });
5349
5349
  const poller = yield coreLro.createHttpPoller(lro, {
5350
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
5351
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
5350
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
5351
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
5352
5352
  resourceLocationConfig: "azure-async-operation"
5353
5353
  });
5354
5354
  yield poller.poll();
@@ -5363,7 +5363,7 @@ class ReservationImpl {
5363
5363
  * @param options The options parameters.
5364
5364
  */
5365
5365
  beginUpdateAndWait(reservationOrderId, reservationId, parameters, options) {
5366
- return tslib.__awaiter(this, void 0, void 0, function* () {
5366
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5367
5367
  const poller = yield this.beginUpdate(reservationOrderId, reservationId, parameters, options);
5368
5368
  return poller.pollUntilDone();
5369
5369
  });
@@ -5808,7 +5808,7 @@ class ReservationOrderImpl {
5808
5808
  return this;
5809
5809
  },
5810
5810
  byPage: (settings) => {
5811
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
5811
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
5812
5812
  throw new Error("maxPageSize is not supported by this operation.");
5813
5813
  }
5814
5814
  return this.listPagingPage(options, settings);
@@ -5818,7 +5818,7 @@ class ReservationOrderImpl {
5818
5818
  listPagingPage(options, settings) {
5819
5819
  return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
5820
5820
  let result;
5821
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
5821
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
5822
5822
  if (!continuationToken) {
5823
5823
  result = yield tslib.__await(this._list(options));
5824
5824
  let page = result.value || [];
@@ -5877,17 +5877,17 @@ class ReservationOrderImpl {
5877
5877
  * @param options The options parameters.
5878
5878
  */
5879
5879
  beginPurchase(reservationOrderId, body, options) {
5880
- return tslib.__awaiter(this, void 0, void 0, function* () {
5881
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5880
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5881
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5882
5882
  return this.client.sendOperationRequest(args, spec);
5883
5883
  });
5884
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
5884
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
5885
5885
  var _a;
5886
5886
  let currentRawResponse = undefined;
5887
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
5887
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
5888
5888
  const callback = (rawResponse, flatResponse) => {
5889
5889
  currentRawResponse = rawResponse;
5890
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
5890
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
5891
5891
  };
5892
5892
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
5893
5893
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -5906,8 +5906,8 @@ class ReservationOrderImpl {
5906
5906
  spec: purchaseOperationSpec
5907
5907
  });
5908
5908
  const poller = yield coreLro.createHttpPoller(lro, {
5909
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
5910
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
5909
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
5910
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
5911
5911
  resourceLocationConfig: "location"
5912
5912
  });
5913
5913
  yield poller.poll();
@@ -5921,7 +5921,7 @@ class ReservationOrderImpl {
5921
5921
  * @param options The options parameters.
5922
5922
  */
5923
5923
  beginPurchaseAndWait(reservationOrderId, body, options) {
5924
- return tslib.__awaiter(this, void 0, void 0, function* () {
5924
+ return tslib.__awaiter(this, undefined, undefined, function* () {
5925
5925
  const poller = yield this.beginPurchase(reservationOrderId, body, options);
5926
5926
  return poller.pollUntilDone();
5927
5927
  });
@@ -6097,7 +6097,7 @@ class OperationImpl {
6097
6097
  return this;
6098
6098
  },
6099
6099
  byPage: (settings) => {
6100
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
6100
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
6101
6101
  throw new Error("maxPageSize is not supported by this operation.");
6102
6102
  }
6103
6103
  return this.listPagingPage(options, settings);
@@ -6107,7 +6107,7 @@ class OperationImpl {
6107
6107
  listPagingPage(options, settings) {
6108
6108
  return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
6109
6109
  let result;
6110
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
6110
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
6111
6111
  if (!continuationToken) {
6112
6112
  result = yield tslib.__await(this._list(options));
6113
6113
  let page = result.value || [];
@@ -6265,17 +6265,17 @@ class ReturnImpl {
6265
6265
  * @param options The options parameters.
6266
6266
  */
6267
6267
  beginPost(reservationOrderId, body, options) {
6268
- return tslib.__awaiter(this, void 0, void 0, function* () {
6269
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6268
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6269
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6270
6270
  return this.client.sendOperationRequest(args, spec);
6271
6271
  });
6272
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6272
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6273
6273
  var _a;
6274
6274
  let currentRawResponse = undefined;
6275
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
6275
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
6276
6276
  const callback = (rawResponse, flatResponse) => {
6277
6277
  currentRawResponse = rawResponse;
6278
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
6278
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
6279
6279
  };
6280
6280
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
6281
6281
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -6294,8 +6294,8 @@ class ReturnImpl {
6294
6294
  spec: postOperationSpec$2
6295
6295
  });
6296
6296
  const poller = yield coreLro.createHttpPoller(lro, {
6297
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
6298
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
6297
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
6298
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
6299
6299
  resourceLocationConfig: "location"
6300
6300
  });
6301
6301
  yield poller.poll();
@@ -6309,7 +6309,7 @@ class ReturnImpl {
6309
6309
  * @param options The options parameters.
6310
6310
  */
6311
6311
  beginPostAndWait(reservationOrderId, body, options) {
6312
- return tslib.__awaiter(this, void 0, void 0, function* () {
6312
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6313
6313
  const poller = yield this.beginPost(reservationOrderId, body, options);
6314
6314
  return poller.pollUntilDone();
6315
6315
  });
@@ -6368,17 +6368,17 @@ class CalculateExchangeImpl {
6368
6368
  * @param options The options parameters.
6369
6369
  */
6370
6370
  beginPost(body, options) {
6371
- return tslib.__awaiter(this, void 0, void 0, function* () {
6372
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6371
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6372
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6373
6373
  return this.client.sendOperationRequest(args, spec);
6374
6374
  });
6375
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6375
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6376
6376
  var _a;
6377
6377
  let currentRawResponse = undefined;
6378
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
6378
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
6379
6379
  const callback = (rawResponse, flatResponse) => {
6380
6380
  currentRawResponse = rawResponse;
6381
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
6381
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
6382
6382
  };
6383
6383
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
6384
6384
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -6397,8 +6397,8 @@ class CalculateExchangeImpl {
6397
6397
  spec: postOperationSpec$1
6398
6398
  });
6399
6399
  const poller = yield coreLro.createHttpPoller(lro, {
6400
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
6401
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
6400
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
6401
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
6402
6402
  resourceLocationConfig: "azure-async-operation"
6403
6403
  });
6404
6404
  yield poller.poll();
@@ -6412,7 +6412,7 @@ class CalculateExchangeImpl {
6412
6412
  * @param options The options parameters.
6413
6413
  */
6414
6414
  beginPostAndWait(body, options) {
6415
- return tslib.__awaiter(this, void 0, void 0, function* () {
6415
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6416
6416
  const poller = yield this.beginPost(body, options);
6417
6417
  return poller.pollUntilDone();
6418
6418
  });
@@ -6471,17 +6471,17 @@ class ExchangeImpl {
6471
6471
  * @param options The options parameters.
6472
6472
  */
6473
6473
  beginPost(body, options) {
6474
- return tslib.__awaiter(this, void 0, void 0, function* () {
6475
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6474
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6475
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6476
6476
  return this.client.sendOperationRequest(args, spec);
6477
6477
  });
6478
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6478
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6479
6479
  var _a;
6480
6480
  let currentRawResponse = undefined;
6481
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
6481
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
6482
6482
  const callback = (rawResponse, flatResponse) => {
6483
6483
  currentRawResponse = rawResponse;
6484
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
6484
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
6485
6485
  };
6486
6486
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
6487
6487
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -6500,8 +6500,8 @@ class ExchangeImpl {
6500
6500
  spec: postOperationSpec
6501
6501
  });
6502
6502
  const poller = yield coreLro.createHttpPoller(lro, {
6503
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
6504
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
6503
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
6504
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
6505
6505
  resourceLocationConfig: "azure-async-operation"
6506
6506
  });
6507
6507
  yield poller.poll();
@@ -6515,7 +6515,7 @@ class ExchangeImpl {
6515
6515
  * @param options The options parameters.
6516
6516
  */
6517
6517
  beginPostAndWait(body, options) {
6518
- return tslib.__awaiter(this, void 0, void 0, function* () {
6518
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6519
6519
  const poller = yield this.beginPost(body, options);
6520
6520
  return poller.pollUntilDone();
6521
6521
  });
@@ -6586,7 +6586,7 @@ class QuotaImpl {
6586
6586
  return this;
6587
6587
  },
6588
6588
  byPage: (settings) => {
6589
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
6589
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
6590
6590
  throw new Error("maxPageSize is not supported by this operation.");
6591
6591
  }
6592
6592
  return this.listPagingPage(subscriptionId, providerId, location, options, settings);
@@ -6596,7 +6596,7 @@ class QuotaImpl {
6596
6596
  listPagingPage(subscriptionId, providerId, location, options, settings) {
6597
6597
  return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
6598
6598
  let result;
6599
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
6599
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
6600
6600
  if (!continuationToken) {
6601
6601
  result = yield tslib.__await(this._list(subscriptionId, providerId, location, options));
6602
6602
  let page = result.value || [];
@@ -6663,17 +6663,17 @@ class QuotaImpl {
6663
6663
  * @param options The options parameters.
6664
6664
  */
6665
6665
  beginCreateOrUpdate(subscriptionId, providerId, location, resourceName, createQuotaRequest, options) {
6666
- return tslib.__awaiter(this, void 0, void 0, function* () {
6667
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6666
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6667
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6668
6668
  return this.client.sendOperationRequest(args, spec);
6669
6669
  });
6670
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6670
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6671
6671
  var _a;
6672
6672
  let currentRawResponse = undefined;
6673
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
6673
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
6674
6674
  const callback = (rawResponse, flatResponse) => {
6675
6675
  currentRawResponse = rawResponse;
6676
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
6676
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
6677
6677
  };
6678
6678
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
6679
6679
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -6699,8 +6699,8 @@ class QuotaImpl {
6699
6699
  spec: createOrUpdateOperationSpec
6700
6700
  });
6701
6701
  const poller = yield coreLro.createHttpPoller(lro, {
6702
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
6703
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
6702
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
6703
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
6704
6704
  resourceLocationConfig: "original-uri"
6705
6705
  });
6706
6706
  yield poller.poll();
@@ -6724,7 +6724,7 @@ class QuotaImpl {
6724
6724
  * @param options The options parameters.
6725
6725
  */
6726
6726
  beginCreateOrUpdateAndWait(subscriptionId, providerId, location, resourceName, createQuotaRequest, options) {
6727
- return tslib.__awaiter(this, void 0, void 0, function* () {
6727
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6728
6728
  const poller = yield this.beginCreateOrUpdate(subscriptionId, providerId, location, resourceName, createQuotaRequest, options);
6729
6729
  return poller.pollUntilDone();
6730
6730
  });
@@ -6745,17 +6745,17 @@ class QuotaImpl {
6745
6745
  * @param options The options parameters.
6746
6746
  */
6747
6747
  beginUpdate(subscriptionId, providerId, location, resourceName, createQuotaRequest, options) {
6748
- return tslib.__awaiter(this, void 0, void 0, function* () {
6749
- const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6748
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6749
+ const directSendOperation = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6750
6750
  return this.client.sendOperationRequest(args, spec);
6751
6751
  });
6752
- const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
6752
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, undefined, undefined, function* () {
6753
6753
  var _a;
6754
6754
  let currentRawResponse = undefined;
6755
- const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
6755
+ const providedCallback = (_a = args.options) === null || _a === undefined ? undefined : _a.onResponse;
6756
6756
  const callback = (rawResponse, flatResponse) => {
6757
6757
  currentRawResponse = rawResponse;
6758
- providedCallback === null || providedCallback === void 0 ? void 0 : providedCallback(rawResponse, flatResponse);
6758
+ providedCallback === null || providedCallback === undefined ? undefined : providedCallback(rawResponse, flatResponse);
6759
6759
  };
6760
6760
  const updatedArgs = Object.assign(Object.assign({}, args), { options: Object.assign(Object.assign({}, args.options), { onResponse: callback }) });
6761
6761
  const flatResponse = yield directSendOperation(updatedArgs, spec);
@@ -6781,8 +6781,8 @@ class QuotaImpl {
6781
6781
  spec: updateOperationSpec
6782
6782
  });
6783
6783
  const poller = yield coreLro.createHttpPoller(lro, {
6784
- restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
6785
- intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs,
6784
+ restoreFrom: options === null || options === undefined ? undefined : options.resumeFrom,
6785
+ intervalInMs: options === null || options === undefined ? undefined : options.updateIntervalInMs,
6786
6786
  resourceLocationConfig: "original-uri"
6787
6787
  });
6788
6788
  yield poller.poll();
@@ -6805,7 +6805,7 @@ class QuotaImpl {
6805
6805
  * @param options The options parameters.
6806
6806
  */
6807
6807
  beginUpdateAndWait(subscriptionId, providerId, location, resourceName, createQuotaRequest, options) {
6808
- return tslib.__awaiter(this, void 0, void 0, function* () {
6808
+ return tslib.__awaiter(this, undefined, undefined, function* () {
6809
6809
  const poller = yield this.beginUpdate(subscriptionId, providerId, location, resourceName, createQuotaRequest, options);
6810
6810
  return poller.pollUntilDone();
6811
6811
  });
@@ -7004,7 +7004,7 @@ class QuotaRequestStatusImpl {
7004
7004
  return this;
7005
7005
  },
7006
7006
  byPage: (settings) => {
7007
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
7007
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
7008
7008
  throw new Error("maxPageSize is not supported by this operation.");
7009
7009
  }
7010
7010
  return this.listPagingPage(subscriptionId, providerId, location, options, settings);
@@ -7014,7 +7014,7 @@ class QuotaRequestStatusImpl {
7014
7014
  listPagingPage(subscriptionId, providerId, location, options, settings) {
7015
7015
  return tslib.__asyncGenerator(this, arguments, function* listPagingPage_1() {
7016
7016
  let result;
7017
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
7017
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
7018
7018
  if (!continuationToken) {
7019
7019
  result = yield tslib.__await(this._list(subscriptionId, providerId, location, options));
7020
7020
  let page = result.value || [];
@@ -7192,10 +7192,10 @@ class AzureReservationAPI extends coreClient__namespace.ServiceClient {
7192
7192
  : `${packageDetails}`;
7193
7193
  const optionsWithDefaults = Object.assign(Object.assign(Object.assign({}, defaults), options), { userAgentOptions: {
7194
7194
  userAgentPrefix
7195
- }, endpoint: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "https://management.azure.com" });
7195
+ }, endpoint: (_b = (_a = options.endpoint) !== null && _a !== undefined ? _a : options.baseUri) !== null && _b !== undefined ? _b : "https://management.azure.com" });
7196
7196
  super(optionsWithDefaults);
7197
7197
  let bearerTokenAuthenticationPolicyFound = false;
7198
- if ((options === null || options === void 0 ? void 0 : options.pipeline) && options.pipeline.getOrderedPolicies().length > 0) {
7198
+ if ((options === null || options === undefined ? undefined : options.pipeline) && options.pipeline.getOrderedPolicies().length > 0) {
7199
7199
  const pipelinePolicies = options.pipeline.getOrderedPolicies();
7200
7200
  bearerTokenAuthenticationPolicyFound = pipelinePolicies.some((pipelinePolicy) => pipelinePolicy.name ===
7201
7201
  coreRestPipeline__namespace.bearerTokenAuthenticationPolicyName);
@@ -7209,7 +7209,7 @@ class AzureReservationAPI extends coreClient__namespace.ServiceClient {
7209
7209
  });
7210
7210
  this.pipeline.addPolicy(coreRestPipeline__namespace.bearerTokenAuthenticationPolicy({
7211
7211
  credential: credentials,
7212
- scopes: (_c = optionsWithDefaults.credentialScopes) !== null && _c !== void 0 ? _c : `${optionsWithDefaults.endpoint}/.default`,
7212
+ scopes: (_c = optionsWithDefaults.credentialScopes) !== null && _c !== undefined ? _c : `${optionsWithDefaults.endpoint}/.default`,
7213
7213
  challengeCallbacks: {
7214
7214
  authorizeRequestOnChallenge: coreClient__namespace.authorizeRequestOnClaimChallenge
7215
7215
  }
@@ -7242,7 +7242,7 @@ class AzureReservationAPI extends coreClient__namespace.ServiceClient {
7242
7242
  return this;
7243
7243
  },
7244
7244
  byPage: (settings) => {
7245
- if (settings === null || settings === void 0 ? void 0 : settings.maxPageSize) {
7245
+ if (settings === null || settings === undefined ? undefined : settings.maxPageSize) {
7246
7246
  throw new Error("maxPageSize is not supported by this operation.");
7247
7247
  }
7248
7248
  return this.getCatalogPagingPage(subscriptionId, options, settings);
@@ -7252,7 +7252,7 @@ class AzureReservationAPI extends coreClient__namespace.ServiceClient {
7252
7252
  getCatalogPagingPage(subscriptionId, options, settings) {
7253
7253
  return tslib.__asyncGenerator(this, arguments, function* getCatalogPagingPage_1() {
7254
7254
  let result;
7255
- let continuationToken = settings === null || settings === void 0 ? void 0 : settings.continuationToken;
7255
+ let continuationToken = settings === null || settings === undefined ? undefined : settings.continuationToken;
7256
7256
  if (!continuationToken) {
7257
7257
  result = yield tslib.__await(this._getCatalog(subscriptionId, options));
7258
7258
  let page = result.value || [];