@aws-sdk/client-auto-scaling-plans 3.52.0 → 3.54.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.
@@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.deserializeAws_json1_1UpdateScalingPlanCommand = exports.deserializeAws_json1_1GetScalingPlanResourceForecastDataCommand = exports.deserializeAws_json1_1DescribeScalingPlansCommand = exports.deserializeAws_json1_1DescribeScalingPlanResourcesCommand = exports.deserializeAws_json1_1DeleteScalingPlanCommand = exports.deserializeAws_json1_1CreateScalingPlanCommand = exports.serializeAws_json1_1UpdateScalingPlanCommand = exports.serializeAws_json1_1GetScalingPlanResourceForecastDataCommand = exports.serializeAws_json1_1DescribeScalingPlansCommand = exports.serializeAws_json1_1DescribeScalingPlanResourcesCommand = exports.serializeAws_json1_1DeleteScalingPlanCommand = exports.serializeAws_json1_1CreateScalingPlanCommand = void 0;
4
4
  const protocol_http_1 = require("@aws-sdk/protocol-http");
5
5
  const smithy_client_1 = require("@aws-sdk/smithy-client");
6
+ const AutoScalingPlansServiceException_1 = require("../models/AutoScalingPlansServiceException");
7
+ const models_0_1 = require("../models/models_0");
6
8
  const serializeAws_json1_1CreateScalingPlanCommand = async (input, context) => {
7
9
  const headers = {
8
10
  "content-type": "application/x-amz-json-1.1",
@@ -88,51 +90,25 @@ const deserializeAws_json1_1CreateScalingPlanCommandError = async (output, conte
88
90
  switch (errorCode) {
89
91
  case "ConcurrentUpdateException":
90
92
  case "com.amazonaws.autoscalingplans#ConcurrentUpdateException":
91
- response = {
92
- ...(await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)),
93
- name: errorCode,
94
- $metadata: deserializeMetadata(output),
95
- };
96
- break;
93
+ throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
97
94
  case "InternalServiceException":
98
95
  case "com.amazonaws.autoscalingplans#InternalServiceException":
99
- response = {
100
- ...(await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)),
101
- name: errorCode,
102
- $metadata: deserializeMetadata(output),
103
- };
104
- break;
96
+ throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
105
97
  case "LimitExceededException":
106
98
  case "com.amazonaws.autoscalingplans#LimitExceededException":
107
- response = {
108
- ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)),
109
- name: errorCode,
110
- $metadata: deserializeMetadata(output),
111
- };
112
- break;
99
+ throw await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context);
113
100
  case "ValidationException":
114
101
  case "com.amazonaws.autoscalingplans#ValidationException":
115
- response = {
116
- ...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
117
- name: errorCode,
118
- $metadata: deserializeMetadata(output),
119
- };
120
- break;
102
+ throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
121
103
  default:
122
104
  const parsedBody = parsedOutput.body;
123
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
124
- response = {
125
- ...parsedBody,
126
- name: `${errorCode}`,
127
- message: parsedBody.message || parsedBody.Message || errorCode,
105
+ response = new AutoScalingPlansServiceException_1.AutoScalingPlansServiceException({
106
+ name: parsedBody.code || parsedBody.Code || errorCode,
128
107
  $fault: "client",
129
108
  $metadata: deserializeMetadata(output),
130
- };
109
+ });
110
+ throw smithy_client_1.decorateServiceException(response, parsedBody);
131
111
  }
132
- const message = response.message || response.Message || errorCode;
133
- response.message = message;
134
- delete response.Message;
135
- return Promise.reject(Object.assign(new Error(message), response));
136
112
  };
137
113
  const deserializeAws_json1_1DeleteScalingPlanCommand = async (output, context) => {
138
114
  if (output.statusCode >= 300) {
@@ -159,51 +135,25 @@ const deserializeAws_json1_1DeleteScalingPlanCommandError = async (output, conte
159
135
  switch (errorCode) {
160
136
  case "ConcurrentUpdateException":
161
137
  case "com.amazonaws.autoscalingplans#ConcurrentUpdateException":
162
- response = {
163
- ...(await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)),
164
- name: errorCode,
165
- $metadata: deserializeMetadata(output),
166
- };
167
- break;
138
+ throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
168
139
  case "InternalServiceException":
169
140
  case "com.amazonaws.autoscalingplans#InternalServiceException":
170
- response = {
171
- ...(await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)),
172
- name: errorCode,
173
- $metadata: deserializeMetadata(output),
174
- };
175
- break;
141
+ throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
176
142
  case "ObjectNotFoundException":
177
143
  case "com.amazonaws.autoscalingplans#ObjectNotFoundException":
178
- response = {
179
- ...(await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)),
180
- name: errorCode,
181
- $metadata: deserializeMetadata(output),
182
- };
183
- break;
144
+ throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
184
145
  case "ValidationException":
185
146
  case "com.amazonaws.autoscalingplans#ValidationException":
186
- response = {
187
- ...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
188
- name: errorCode,
189
- $metadata: deserializeMetadata(output),
190
- };
191
- break;
147
+ throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
192
148
  default:
193
149
  const parsedBody = parsedOutput.body;
194
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
195
- response = {
196
- ...parsedBody,
197
- name: `${errorCode}`,
198
- message: parsedBody.message || parsedBody.Message || errorCode,
150
+ response = new AutoScalingPlansServiceException_1.AutoScalingPlansServiceException({
151
+ name: parsedBody.code || parsedBody.Code || errorCode,
199
152
  $fault: "client",
200
153
  $metadata: deserializeMetadata(output),
201
- };
154
+ });
155
+ throw smithy_client_1.decorateServiceException(response, parsedBody);
202
156
  }
203
- const message = response.message || response.Message || errorCode;
204
- response.message = message;
205
- delete response.Message;
206
- return Promise.reject(Object.assign(new Error(message), response));
207
157
  };
208
158
  const deserializeAws_json1_1DescribeScalingPlanResourcesCommand = async (output, context) => {
209
159
  if (output.statusCode >= 300) {
@@ -230,51 +180,25 @@ const deserializeAws_json1_1DescribeScalingPlanResourcesCommandError = async (ou
230
180
  switch (errorCode) {
231
181
  case "ConcurrentUpdateException":
232
182
  case "com.amazonaws.autoscalingplans#ConcurrentUpdateException":
233
- response = {
234
- ...(await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)),
235
- name: errorCode,
236
- $metadata: deserializeMetadata(output),
237
- };
238
- break;
183
+ throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
239
184
  case "InternalServiceException":
240
185
  case "com.amazonaws.autoscalingplans#InternalServiceException":
241
- response = {
242
- ...(await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)),
243
- name: errorCode,
244
- $metadata: deserializeMetadata(output),
245
- };
246
- break;
186
+ throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
247
187
  case "InvalidNextTokenException":
248
188
  case "com.amazonaws.autoscalingplans#InvalidNextTokenException":
249
- response = {
250
- ...(await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context)),
251
- name: errorCode,
252
- $metadata: deserializeMetadata(output),
253
- };
254
- break;
189
+ throw await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context);
255
190
  case "ValidationException":
256
191
  case "com.amazonaws.autoscalingplans#ValidationException":
257
- response = {
258
- ...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
259
- name: errorCode,
260
- $metadata: deserializeMetadata(output),
261
- };
262
- break;
192
+ throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
263
193
  default:
264
194
  const parsedBody = parsedOutput.body;
265
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
266
- response = {
267
- ...parsedBody,
268
- name: `${errorCode}`,
269
- message: parsedBody.message || parsedBody.Message || errorCode,
195
+ response = new AutoScalingPlansServiceException_1.AutoScalingPlansServiceException({
196
+ name: parsedBody.code || parsedBody.Code || errorCode,
270
197
  $fault: "client",
271
198
  $metadata: deserializeMetadata(output),
272
- };
199
+ });
200
+ throw smithy_client_1.decorateServiceException(response, parsedBody);
273
201
  }
274
- const message = response.message || response.Message || errorCode;
275
- response.message = message;
276
- delete response.Message;
277
- return Promise.reject(Object.assign(new Error(message), response));
278
202
  };
279
203
  const deserializeAws_json1_1DescribeScalingPlansCommand = async (output, context) => {
280
204
  if (output.statusCode >= 300) {
@@ -301,51 +225,25 @@ const deserializeAws_json1_1DescribeScalingPlansCommandError = async (output, co
301
225
  switch (errorCode) {
302
226
  case "ConcurrentUpdateException":
303
227
  case "com.amazonaws.autoscalingplans#ConcurrentUpdateException":
304
- response = {
305
- ...(await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)),
306
- name: errorCode,
307
- $metadata: deserializeMetadata(output),
308
- };
309
- break;
228
+ throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
310
229
  case "InternalServiceException":
311
230
  case "com.amazonaws.autoscalingplans#InternalServiceException":
312
- response = {
313
- ...(await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)),
314
- name: errorCode,
315
- $metadata: deserializeMetadata(output),
316
- };
317
- break;
231
+ throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
318
232
  case "InvalidNextTokenException":
319
233
  case "com.amazonaws.autoscalingplans#InvalidNextTokenException":
320
- response = {
321
- ...(await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context)),
322
- name: errorCode,
323
- $metadata: deserializeMetadata(output),
324
- };
325
- break;
234
+ throw await deserializeAws_json1_1InvalidNextTokenExceptionResponse(parsedOutput, context);
326
235
  case "ValidationException":
327
236
  case "com.amazonaws.autoscalingplans#ValidationException":
328
- response = {
329
- ...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
330
- name: errorCode,
331
- $metadata: deserializeMetadata(output),
332
- };
333
- break;
237
+ throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
334
238
  default:
335
239
  const parsedBody = parsedOutput.body;
336
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
337
- response = {
338
- ...parsedBody,
339
- name: `${errorCode}`,
340
- message: parsedBody.message || parsedBody.Message || errorCode,
240
+ response = new AutoScalingPlansServiceException_1.AutoScalingPlansServiceException({
241
+ name: parsedBody.code || parsedBody.Code || errorCode,
341
242
  $fault: "client",
342
243
  $metadata: deserializeMetadata(output),
343
- };
244
+ });
245
+ throw smithy_client_1.decorateServiceException(response, parsedBody);
344
246
  }
345
- const message = response.message || response.Message || errorCode;
346
- response.message = message;
347
- delete response.Message;
348
- return Promise.reject(Object.assign(new Error(message), response));
349
247
  };
350
248
  const deserializeAws_json1_1GetScalingPlanResourceForecastDataCommand = async (output, context) => {
351
249
  if (output.statusCode >= 300) {
@@ -372,35 +270,19 @@ const deserializeAws_json1_1GetScalingPlanResourceForecastDataCommandError = asy
372
270
  switch (errorCode) {
373
271
  case "InternalServiceException":
374
272
  case "com.amazonaws.autoscalingplans#InternalServiceException":
375
- response = {
376
- ...(await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)),
377
- name: errorCode,
378
- $metadata: deserializeMetadata(output),
379
- };
380
- break;
273
+ throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
381
274
  case "ValidationException":
382
275
  case "com.amazonaws.autoscalingplans#ValidationException":
383
- response = {
384
- ...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
385
- name: errorCode,
386
- $metadata: deserializeMetadata(output),
387
- };
388
- break;
276
+ throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
389
277
  default:
390
278
  const parsedBody = parsedOutput.body;
391
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
392
- response = {
393
- ...parsedBody,
394
- name: `${errorCode}`,
395
- message: parsedBody.message || parsedBody.Message || errorCode,
279
+ response = new AutoScalingPlansServiceException_1.AutoScalingPlansServiceException({
280
+ name: parsedBody.code || parsedBody.Code || errorCode,
396
281
  $fault: "client",
397
282
  $metadata: deserializeMetadata(output),
398
- };
283
+ });
284
+ throw smithy_client_1.decorateServiceException(response, parsedBody);
399
285
  }
400
- const message = response.message || response.Message || errorCode;
401
- response.message = message;
402
- delete response.Message;
403
- return Promise.reject(Object.assign(new Error(message), response));
404
286
  };
405
287
  const deserializeAws_json1_1UpdateScalingPlanCommand = async (output, context) => {
406
288
  if (output.statusCode >= 300) {
@@ -427,117 +309,79 @@ const deserializeAws_json1_1UpdateScalingPlanCommandError = async (output, conte
427
309
  switch (errorCode) {
428
310
  case "ConcurrentUpdateException":
429
311
  case "com.amazonaws.autoscalingplans#ConcurrentUpdateException":
430
- response = {
431
- ...(await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context)),
432
- name: errorCode,
433
- $metadata: deserializeMetadata(output),
434
- };
435
- break;
312
+ throw await deserializeAws_json1_1ConcurrentUpdateExceptionResponse(parsedOutput, context);
436
313
  case "InternalServiceException":
437
314
  case "com.amazonaws.autoscalingplans#InternalServiceException":
438
- response = {
439
- ...(await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context)),
440
- name: errorCode,
441
- $metadata: deserializeMetadata(output),
442
- };
443
- break;
315
+ throw await deserializeAws_json1_1InternalServiceExceptionResponse(parsedOutput, context);
444
316
  case "ObjectNotFoundException":
445
317
  case "com.amazonaws.autoscalingplans#ObjectNotFoundException":
446
- response = {
447
- ...(await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context)),
448
- name: errorCode,
449
- $metadata: deserializeMetadata(output),
450
- };
451
- break;
318
+ throw await deserializeAws_json1_1ObjectNotFoundExceptionResponse(parsedOutput, context);
452
319
  case "ValidationException":
453
320
  case "com.amazonaws.autoscalingplans#ValidationException":
454
- response = {
455
- ...(await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context)),
456
- name: errorCode,
457
- $metadata: deserializeMetadata(output),
458
- };
459
- break;
321
+ throw await deserializeAws_json1_1ValidationExceptionResponse(parsedOutput, context);
460
322
  default:
461
323
  const parsedBody = parsedOutput.body;
462
- errorCode = parsedBody.code || parsedBody.Code || errorCode;
463
- response = {
464
- ...parsedBody,
465
- name: `${errorCode}`,
466
- message: parsedBody.message || parsedBody.Message || errorCode,
324
+ response = new AutoScalingPlansServiceException_1.AutoScalingPlansServiceException({
325
+ name: parsedBody.code || parsedBody.Code || errorCode,
467
326
  $fault: "client",
468
327
  $metadata: deserializeMetadata(output),
469
- };
328
+ });
329
+ throw smithy_client_1.decorateServiceException(response, parsedBody);
470
330
  }
471
- const message = response.message || response.Message || errorCode;
472
- response.message = message;
473
- delete response.Message;
474
- return Promise.reject(Object.assign(new Error(message), response));
475
331
  };
476
332
  const deserializeAws_json1_1ConcurrentUpdateExceptionResponse = async (parsedOutput, context) => {
477
333
  const body = parsedOutput.body;
478
334
  const deserialized = deserializeAws_json1_1ConcurrentUpdateException(body, context);
479
- const contents = {
480
- name: "ConcurrentUpdateException",
481
- $fault: "server",
335
+ const exception = new models_0_1.ConcurrentUpdateException({
482
336
  $metadata: deserializeMetadata(parsedOutput),
483
337
  ...deserialized,
484
- };
485
- return contents;
338
+ });
339
+ return smithy_client_1.decorateServiceException(exception, body);
486
340
  };
487
341
  const deserializeAws_json1_1InternalServiceExceptionResponse = async (parsedOutput, context) => {
488
342
  const body = parsedOutput.body;
489
343
  const deserialized = deserializeAws_json1_1InternalServiceException(body, context);
490
- const contents = {
491
- name: "InternalServiceException",
492
- $fault: "server",
344
+ const exception = new models_0_1.InternalServiceException({
493
345
  $metadata: deserializeMetadata(parsedOutput),
494
346
  ...deserialized,
495
- };
496
- return contents;
347
+ });
348
+ return smithy_client_1.decorateServiceException(exception, body);
497
349
  };
498
350
  const deserializeAws_json1_1InvalidNextTokenExceptionResponse = async (parsedOutput, context) => {
499
351
  const body = parsedOutput.body;
500
352
  const deserialized = deserializeAws_json1_1InvalidNextTokenException(body, context);
501
- const contents = {
502
- name: "InvalidNextTokenException",
503
- $fault: "client",
353
+ const exception = new models_0_1.InvalidNextTokenException({
504
354
  $metadata: deserializeMetadata(parsedOutput),
505
355
  ...deserialized,
506
- };
507
- return contents;
356
+ });
357
+ return smithy_client_1.decorateServiceException(exception, body);
508
358
  };
509
359
  const deserializeAws_json1_1LimitExceededExceptionResponse = async (parsedOutput, context) => {
510
360
  const body = parsedOutput.body;
511
361
  const deserialized = deserializeAws_json1_1LimitExceededException(body, context);
512
- const contents = {
513
- name: "LimitExceededException",
514
- $fault: "client",
362
+ const exception = new models_0_1.LimitExceededException({
515
363
  $metadata: deserializeMetadata(parsedOutput),
516
364
  ...deserialized,
517
- };
518
- return contents;
365
+ });
366
+ return smithy_client_1.decorateServiceException(exception, body);
519
367
  };
520
368
  const deserializeAws_json1_1ObjectNotFoundExceptionResponse = async (parsedOutput, context) => {
521
369
  const body = parsedOutput.body;
522
370
  const deserialized = deserializeAws_json1_1ObjectNotFoundException(body, context);
523
- const contents = {
524
- name: "ObjectNotFoundException",
525
- $fault: "client",
371
+ const exception = new models_0_1.ObjectNotFoundException({
526
372
  $metadata: deserializeMetadata(parsedOutput),
527
373
  ...deserialized,
528
- };
529
- return contents;
374
+ });
375
+ return smithy_client_1.decorateServiceException(exception, body);
530
376
  };
531
377
  const deserializeAws_json1_1ValidationExceptionResponse = async (parsedOutput, context) => {
532
378
  const body = parsedOutput.body;
533
379
  const deserialized = deserializeAws_json1_1ValidationException(body, context);
534
- const contents = {
535
- name: "ValidationException",
536
- $fault: "client",
380
+ const exception = new models_0_1.ValidationException({
537
381
  $metadata: deserializeMetadata(parsedOutput),
538
382
  ...deserialized,
539
- };
540
- return contents;
383
+ });
384
+ return smithy_client_1.decorateServiceException(exception, body);
541
385
  };
542
386
  const serializeAws_json1_1ApplicationSource = (input, context) => {
543
387
  return {
@@ -857,7 +701,7 @@ const deserializeAws_json1_1Datapoint = (output, context) => {
857
701
  };
858
702
  };
859
703
  const deserializeAws_json1_1Datapoints = (output, context) => {
860
- return (output || [])
704
+ const retVal = (output || [])
861
705
  .filter((e) => e != null)
862
706
  .map((entry) => {
863
707
  if (entry === null) {
@@ -865,6 +709,7 @@ const deserializeAws_json1_1Datapoints = (output, context) => {
865
709
  }
866
710
  return deserializeAws_json1_1Datapoint(entry, context);
867
711
  });
712
+ return retVal;
868
713
  };
869
714
  const deserializeAws_json1_1DeleteScalingPlanResponse = (output, context) => {
870
715
  return {};
@@ -914,7 +759,7 @@ const deserializeAws_json1_1MetricDimension = (output, context) => {
914
759
  };
915
760
  };
916
761
  const deserializeAws_json1_1MetricDimensions = (output, context) => {
917
- return (output || [])
762
+ const retVal = (output || [])
918
763
  .filter((e) => e != null)
919
764
  .map((entry) => {
920
765
  if (entry === null) {
@@ -922,6 +767,7 @@ const deserializeAws_json1_1MetricDimensions = (output, context) => {
922
767
  }
923
768
  return deserializeAws_json1_1MetricDimension(entry, context);
924
769
  });
770
+ return retVal;
925
771
  };
926
772
  const deserializeAws_json1_1ObjectNotFoundException = (output, context) => {
927
773
  return {
@@ -965,7 +811,7 @@ const deserializeAws_json1_1ScalingInstruction = (output, context) => {
965
811
  };
966
812
  };
967
813
  const deserializeAws_json1_1ScalingInstructions = (output, context) => {
968
- return (output || [])
814
+ const retVal = (output || [])
969
815
  .filter((e) => e != null)
970
816
  .map((entry) => {
971
817
  if (entry === null) {
@@ -973,6 +819,7 @@ const deserializeAws_json1_1ScalingInstructions = (output, context) => {
973
819
  }
974
820
  return deserializeAws_json1_1ScalingInstruction(entry, context);
975
821
  });
822
+ return retVal;
976
823
  };
977
824
  const deserializeAws_json1_1ScalingPlan = (output, context) => {
978
825
  return {
@@ -1009,7 +856,7 @@ const deserializeAws_json1_1ScalingPlanResource = (output, context) => {
1009
856
  };
1010
857
  };
1011
858
  const deserializeAws_json1_1ScalingPlanResources = (output, context) => {
1012
- return (output || [])
859
+ const retVal = (output || [])
1013
860
  .filter((e) => e != null)
1014
861
  .map((entry) => {
1015
862
  if (entry === null) {
@@ -1017,9 +864,10 @@ const deserializeAws_json1_1ScalingPlanResources = (output, context) => {
1017
864
  }
1018
865
  return deserializeAws_json1_1ScalingPlanResource(entry, context);
1019
866
  });
867
+ return retVal;
1020
868
  };
1021
869
  const deserializeAws_json1_1ScalingPlans = (output, context) => {
1022
- return (output || [])
870
+ const retVal = (output || [])
1023
871
  .filter((e) => e != null)
1024
872
  .map((entry) => {
1025
873
  if (entry === null) {
@@ -1027,9 +875,10 @@ const deserializeAws_json1_1ScalingPlans = (output, context) => {
1027
875
  }
1028
876
  return deserializeAws_json1_1ScalingPlan(entry, context);
1029
877
  });
878
+ return retVal;
1030
879
  };
1031
880
  const deserializeAws_json1_1ScalingPolicies = (output, context) => {
1032
- return (output || [])
881
+ const retVal = (output || [])
1033
882
  .filter((e) => e != null)
1034
883
  .map((entry) => {
1035
884
  if (entry === null) {
@@ -1037,6 +886,7 @@ const deserializeAws_json1_1ScalingPolicies = (output, context) => {
1037
886
  }
1038
887
  return deserializeAws_json1_1ScalingPolicy(entry, context);
1039
888
  });
889
+ return retVal;
1040
890
  };
1041
891
  const deserializeAws_json1_1ScalingPolicy = (output, context) => {
1042
892
  return {
@@ -1056,7 +906,7 @@ const deserializeAws_json1_1TagFilter = (output, context) => {
1056
906
  };
1057
907
  };
1058
908
  const deserializeAws_json1_1TagFilters = (output, context) => {
1059
- return (output || [])
909
+ const retVal = (output || [])
1060
910
  .filter((e) => e != null)
1061
911
  .map((entry) => {
1062
912
  if (entry === null) {
@@ -1064,9 +914,10 @@ const deserializeAws_json1_1TagFilters = (output, context) => {
1064
914
  }
1065
915
  return deserializeAws_json1_1TagFilter(entry, context);
1066
916
  });
917
+ return retVal;
1067
918
  };
1068
919
  const deserializeAws_json1_1TagValues = (output, context) => {
1069
- return (output || [])
920
+ const retVal = (output || [])
1070
921
  .filter((e) => e != null)
1071
922
  .map((entry) => {
1072
923
  if (entry === null) {
@@ -1074,6 +925,7 @@ const deserializeAws_json1_1TagValues = (output, context) => {
1074
925
  }
1075
926
  return smithy_client_1.expectString(entry);
1076
927
  });
928
+ return retVal;
1077
929
  };
1078
930
  const deserializeAws_json1_1TargetTrackingConfiguration = (output, context) => {
1079
931
  return {
@@ -1091,7 +943,7 @@ const deserializeAws_json1_1TargetTrackingConfiguration = (output, context) => {
1091
943
  };
1092
944
  };
1093
945
  const deserializeAws_json1_1TargetTrackingConfigurations = (output, context) => {
1094
- return (output || [])
946
+ const retVal = (output || [])
1095
947
  .filter((e) => e != null)
1096
948
  .map((entry) => {
1097
949
  if (entry === null) {
@@ -1099,6 +951,7 @@ const deserializeAws_json1_1TargetTrackingConfigurations = (output, context) =>
1099
951
  }
1100
952
  return deserializeAws_json1_1TargetTrackingConfiguration(entry, context);
1101
953
  });
954
+ return retVal;
1102
955
  };
1103
956
  const deserializeAws_json1_1UpdateScalingPlanResponse = (output, context) => {
1104
957
  return {};
package/dist-es/index.js CHANGED
@@ -2,3 +2,4 @@ export * from "./AutoScalingPlans";
2
2
  export * from "./AutoScalingPlansClient";
3
3
  export * from "./commands";
4
4
  export * from "./models";
5
+ export { AutoScalingPlansServiceException } from "./models/AutoScalingPlansServiceException";
@@ -0,0 +1,12 @@
1
+ import { __extends } from "tslib";
2
+ import { ServiceException as __ServiceException, } from "@aws-sdk/smithy-client";
3
+ var AutoScalingPlansServiceException = (function (_super) {
4
+ __extends(AutoScalingPlansServiceException, _super);
5
+ function AutoScalingPlansServiceException(options) {
6
+ var _this = _super.call(this, options) || this;
7
+ Object.setPrototypeOf(_this, AutoScalingPlansServiceException.prototype);
8
+ return _this;
9
+ }
10
+ return AutoScalingPlansServiceException;
11
+ }(__ServiceException));
12
+ export { AutoScalingPlansServiceException };