@aws-sdk/client-mediaconnect 3.310.0 → 3.313.0
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/README.md +167 -7
- package/dist-cjs/MediaConnect.js +300 -0
- package/dist-cjs/commands/AddBridgeOutputsCommand.js +45 -0
- package/dist-cjs/commands/AddBridgeSourcesCommand.js +45 -0
- package/dist-cjs/commands/CreateBridgeCommand.js +45 -0
- package/dist-cjs/commands/CreateGatewayCommand.js +45 -0
- package/dist-cjs/commands/DeleteBridgeCommand.js +45 -0
- package/dist-cjs/commands/DeleteGatewayCommand.js +45 -0
- package/dist-cjs/commands/DeregisterGatewayInstanceCommand.js +45 -0
- package/dist-cjs/commands/DescribeBridgeCommand.js +45 -0
- package/dist-cjs/commands/DescribeGatewayCommand.js +45 -0
- package/dist-cjs/commands/DescribeGatewayInstanceCommand.js +45 -0
- package/dist-cjs/commands/ListBridgesCommand.js +45 -0
- package/dist-cjs/commands/ListGatewayInstancesCommand.js +45 -0
- package/dist-cjs/commands/ListGatewaysCommand.js +45 -0
- package/dist-cjs/commands/RemoveBridgeOutputCommand.js +45 -0
- package/dist-cjs/commands/RemoveBridgeSourceCommand.js +45 -0
- package/dist-cjs/commands/UpdateBridgeCommand.js +45 -0
- package/dist-cjs/commands/UpdateBridgeOutputCommand.js +45 -0
- package/dist-cjs/commands/UpdateBridgeSourceCommand.js +45 -0
- package/dist-cjs/commands/UpdateBridgeStateCommand.js +45 -0
- package/dist-cjs/commands/UpdateGatewayInstanceCommand.js +45 -0
- package/dist-cjs/commands/index.js +20 -0
- package/dist-cjs/endpoint/ruleset.js +3 -3
- package/dist-cjs/models/models_0.js +106 -20
- package/dist-cjs/pagination/ListBridgesPaginator.js +29 -0
- package/dist-cjs/pagination/ListGatewayInstancesPaginator.js +29 -0
- package/dist-cjs/pagination/ListGatewaysPaginator.js +29 -0
- package/dist-cjs/pagination/index.js +3 -0
- package/dist-cjs/protocols/Aws_restJson1.js +2045 -140
- package/dist-es/MediaConnect.js +300 -0
- package/dist-es/commands/AddBridgeOutputsCommand.js +41 -0
- package/dist-es/commands/AddBridgeSourcesCommand.js +41 -0
- package/dist-es/commands/CreateBridgeCommand.js +41 -0
- package/dist-es/commands/CreateGatewayCommand.js +41 -0
- package/dist-es/commands/DeleteBridgeCommand.js +41 -0
- package/dist-es/commands/DeleteGatewayCommand.js +41 -0
- package/dist-es/commands/DeregisterGatewayInstanceCommand.js +41 -0
- package/dist-es/commands/DescribeBridgeCommand.js +41 -0
- package/dist-es/commands/DescribeGatewayCommand.js +41 -0
- package/dist-es/commands/DescribeGatewayInstanceCommand.js +41 -0
- package/dist-es/commands/ListBridgesCommand.js +41 -0
- package/dist-es/commands/ListGatewayInstancesCommand.js +41 -0
- package/dist-es/commands/ListGatewaysCommand.js +41 -0
- package/dist-es/commands/RemoveBridgeOutputCommand.js +41 -0
- package/dist-es/commands/RemoveBridgeSourceCommand.js +41 -0
- package/dist-es/commands/UpdateBridgeCommand.js +41 -0
- package/dist-es/commands/UpdateBridgeOutputCommand.js +41 -0
- package/dist-es/commands/UpdateBridgeSourceCommand.js +41 -0
- package/dist-es/commands/UpdateBridgeStateCommand.js +41 -0
- package/dist-es/commands/UpdateGatewayInstanceCommand.js +41 -0
- package/dist-es/commands/index.js +20 -0
- package/dist-es/endpoint/ruleset.js +3 -3
- package/dist-es/models/models_0.js +102 -19
- package/dist-es/pagination/ListBridgesPaginator.js +25 -0
- package/dist-es/pagination/ListGatewayInstancesPaginator.js +25 -0
- package/dist-es/pagination/ListGatewaysPaginator.js +25 -0
- package/dist-es/pagination/index.js +3 -0
- package/dist-es/protocols/Aws_restJson1.js +2002 -137
- package/dist-types/MediaConnect.d.ts +160 -0
- package/dist-types/MediaConnectClient.d.ts +22 -2
- package/dist-types/commands/AddBridgeOutputsCommand.d.ts +96 -0
- package/dist-types/commands/AddBridgeSourcesCommand.d.ts +102 -0
- package/dist-types/commands/AddFlowOutputsCommand.d.ts +1 -1
- package/dist-types/commands/AddFlowSourcesCommand.d.ts +7 -1
- package/dist-types/commands/CreateBridgeCommand.d.ts +130 -0
- package/dist-types/commands/CreateFlowCommand.d.ts +15 -3
- package/dist-types/commands/CreateGatewayCommand.d.ts +93 -0
- package/dist-types/commands/DeleteBridgeCommand.d.ts +84 -0
- package/dist-types/commands/DeleteGatewayCommand.d.ts +84 -0
- package/dist-types/commands/DeregisterGatewayInstanceCommand.d.ts +85 -0
- package/dist-types/commands/DescribeBridgeCommand.d.ts +84 -0
- package/dist-types/commands/DescribeGatewayCommand.d.ts +84 -0
- package/dist-types/commands/DescribeGatewayInstanceCommand.d.ts +84 -0
- package/dist-types/commands/ListBridgesCommand.d.ts +80 -0
- package/dist-types/commands/ListGatewayInstancesCommand.d.ts +80 -0
- package/dist-types/commands/ListGatewaysCommand.d.ts +79 -0
- package/dist-types/commands/RemoveBridgeOutputCommand.d.ts +85 -0
- package/dist-types/commands/RemoveBridgeSourceCommand.d.ts +85 -0
- package/dist-types/commands/UpdateBridgeCommand.d.ts +99 -0
- package/dist-types/commands/UpdateBridgeOutputCommand.d.ts +92 -0
- package/dist-types/commands/UpdateBridgeSourceCommand.d.ts +97 -0
- package/dist-types/commands/UpdateBridgeStateCommand.d.ts +85 -0
- package/dist-types/commands/UpdateFlowOutputCommand.d.ts +1 -1
- package/dist-types/commands/UpdateFlowSourceCommand.d.ts +7 -1
- package/dist-types/commands/UpdateGatewayInstanceCommand.d.ts +85 -0
- package/dist-types/commands/index.d.ts +20 -0
- package/dist-types/models/models_0.d.ts +1340 -85
- package/dist-types/pagination/ListBridgesPaginator.d.ts +7 -0
- package/dist-types/pagination/ListGatewayInstancesPaginator.d.ts +7 -0
- package/dist-types/pagination/ListGatewaysPaginator.d.ts +7 -0
- package/dist-types/pagination/index.d.ts +3 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +180 -0
- package/dist-types/ts3.4/MediaConnect.d.ts +340 -0
- package/dist-types/ts3.4/MediaConnectClient.d.ts +122 -2
- package/dist-types/ts3.4/commands/AddBridgeOutputsCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/AddBridgeSourcesCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/CreateBridgeCommand.d.ts +34 -0
- package/dist-types/ts3.4/commands/CreateGatewayCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/DeleteBridgeCommand.d.ts +34 -0
- package/dist-types/ts3.4/commands/DeleteGatewayCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/DeregisterGatewayInstanceCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/DescribeBridgeCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/DescribeGatewayCommand.d.ts +37 -0
- package/dist-types/ts3.4/commands/DescribeGatewayInstanceCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ListBridgesCommand.d.ts +34 -0
- package/dist-types/ts3.4/commands/ListGatewayInstancesCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/ListGatewaysCommand.d.ts +34 -0
- package/dist-types/ts3.4/commands/RemoveBridgeOutputCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/RemoveBridgeSourceCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UpdateBridgeCommand.d.ts +34 -0
- package/dist-types/ts3.4/commands/UpdateBridgeOutputCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UpdateBridgeSourceCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UpdateBridgeStateCommand.d.ts +38 -0
- package/dist-types/ts3.4/commands/UpdateGatewayInstanceCommand.d.ts +41 -0
- package/dist-types/ts3.4/commands/index.d.ts +20 -0
- package/dist-types/ts3.4/models/models_0.d.ts +442 -33
- package/dist-types/ts3.4/pagination/ListBridgesPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListGatewayInstancesPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListGatewaysPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/index.d.ts +3 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +240 -0
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
2
|
-
const a = "
|
|
3
|
-
const _data = { version: "1.0", parameters: { Region:
|
|
1
|
+
const q = "required", r = "fn", s = "argv", t = "ref";
|
|
2
|
+
const a = "isSet", b = "tree", c = "error", d = "endpoint", e = "PartitionResult", f = { [q]: false, "type": "String" }, g = { [q]: true, "default": false, "type": "Boolean" }, h = { [t]: "Endpoint" }, i = { [r]: "booleanEquals", [s]: [{ [t]: "UseFIPS" }, true] }, j = { [r]: "booleanEquals", [s]: [{ [t]: "UseDualStack" }, true] }, k = {}, l = { [r]: "booleanEquals", [s]: [true, { [r]: "getAttr", [s]: [{ [t]: e }, "supportsFIPS"] }] }, m = { [r]: "booleanEquals", [s]: [true, { [r]: "getAttr", [s]: [{ [t]: e }, "supportsDualStack"] }] }, n = [i], o = [j], p = [{ [t]: "Region" }];
|
|
3
|
+
const _data = { version: "1.0", parameters: { Region: f, UseDualStack: g, UseFIPS: g, Endpoint: f }, rules: [{ conditions: [{ [r]: a, [s]: [h] }], type: b, rules: [{ conditions: n, error: "Invalid Configuration: FIPS and custom endpoint are not supported", type: c }, { type: b, rules: [{ conditions: o, error: "Invalid Configuration: Dualstack and custom endpoint are not supported", type: c }, { endpoint: { url: h, properties: k, headers: k }, type: d }] }] }, { type: b, rules: [{ conditions: [{ [r]: a, [s]: p }], type: b, rules: [{ conditions: [{ [r]: "aws.partition", [s]: p, assign: e }], type: b, rules: [{ conditions: [i, j], type: b, rules: [{ conditions: [l, m], type: b, rules: [{ type: b, rules: [{ endpoint: { url: "https://mediaconnect-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: k, headers: k }, type: d }] }] }, { error: "FIPS and DualStack are enabled, but this partition does not support one or both", type: c }] }, { conditions: n, type: b, rules: [{ conditions: [l], type: b, rules: [{ type: b, rules: [{ endpoint: { url: "https://mediaconnect-fips.{Region}.{PartitionResult#dnsSuffix}", properties: k, headers: k }, type: d }] }] }, { error: "FIPS is enabled but this partition does not support FIPS", type: c }] }, { conditions: o, type: b, rules: [{ conditions: [m], type: b, rules: [{ type: b, rules: [{ endpoint: { url: "https://mediaconnect.{Region}.{PartitionResult#dualStackDnsSuffix}", properties: k, headers: k }, type: d }] }] }, { error: "DualStack is enabled but this partition does not support DualStack", type: c }] }, { type: b, rules: [{ endpoint: { url: "https://mediaconnect.{Region}.{PartitionResult#dnsSuffix}", properties: k, headers: k }, type: d }] }] }] }, { error: "Invalid Configuration: Missing Region", type: c }] }] };
|
|
4
4
|
export const ruleSet = _data;
|
|
@@ -1,4 +1,17 @@
|
|
|
1
1
|
import { MediaConnectServiceException as __BaseException } from "./MediaConnectServiceException";
|
|
2
|
+
export const Protocol = {
|
|
3
|
+
cdi: "cdi",
|
|
4
|
+
fujitsu_qos: "fujitsu-qos",
|
|
5
|
+
rist: "rist",
|
|
6
|
+
rtp: "rtp",
|
|
7
|
+
rtp_fec: "rtp-fec",
|
|
8
|
+
srt_caller: "srt-caller",
|
|
9
|
+
srt_listener: "srt-listener",
|
|
10
|
+
st2110_jpegxs: "st2110-jpegxs",
|
|
11
|
+
udp: "udp",
|
|
12
|
+
zixi_pull: "zixi-pull",
|
|
13
|
+
zixi_push: "zixi-push",
|
|
14
|
+
};
|
|
2
15
|
export const Colorimetry = {
|
|
3
16
|
BT2020: "BT2020",
|
|
4
17
|
BT2100: "BT2100",
|
|
@@ -54,22 +67,24 @@ export const EncoderProfile = {
|
|
|
54
67
|
high: "high",
|
|
55
68
|
main: "main",
|
|
56
69
|
};
|
|
57
|
-
export const Protocol = {
|
|
58
|
-
cdi: "cdi",
|
|
59
|
-
fujitsu_qos: "fujitsu-qos",
|
|
60
|
-
rist: "rist",
|
|
61
|
-
rtp: "rtp",
|
|
62
|
-
rtp_fec: "rtp-fec",
|
|
63
|
-
srt_caller: "srt-caller",
|
|
64
|
-
srt_listener: "srt-listener",
|
|
65
|
-
st2110_jpegxs: "st2110-jpegxs",
|
|
66
|
-
zixi_pull: "zixi-pull",
|
|
67
|
-
zixi_push: "zixi-push",
|
|
68
|
-
};
|
|
69
70
|
export const EntitlementStatus = {
|
|
70
71
|
DISABLED: "DISABLED",
|
|
71
72
|
ENABLED: "ENABLED",
|
|
72
73
|
};
|
|
74
|
+
export const BridgeState = {
|
|
75
|
+
ACTIVE: "ACTIVE",
|
|
76
|
+
CREATING: "CREATING",
|
|
77
|
+
DELETED: "DELETED",
|
|
78
|
+
DELETING: "DELETING",
|
|
79
|
+
DEPLOYING: "DEPLOYING",
|
|
80
|
+
STANDBY: "STANDBY",
|
|
81
|
+
STARTING: "STARTING",
|
|
82
|
+
START_FAILED: "START_FAILED",
|
|
83
|
+
START_PENDING: "START_PENDING",
|
|
84
|
+
STOPPING: "STOPPING",
|
|
85
|
+
STOP_FAILED: "STOP_FAILED",
|
|
86
|
+
UPDATING: "UPDATING",
|
|
87
|
+
};
|
|
73
88
|
export const MaintenanceDay = {
|
|
74
89
|
Friday: "Friday",
|
|
75
90
|
Monday: "Monday",
|
|
@@ -92,6 +107,22 @@ export const Status = {
|
|
|
92
107
|
STOPPING: "STOPPING",
|
|
93
108
|
UPDATING: "UPDATING",
|
|
94
109
|
};
|
|
110
|
+
export const GatewayState = {
|
|
111
|
+
ACTIVE: "ACTIVE",
|
|
112
|
+
CREATING: "CREATING",
|
|
113
|
+
DELETED: "DELETED",
|
|
114
|
+
DELETING: "DELETING",
|
|
115
|
+
ERROR: "ERROR",
|
|
116
|
+
UPDATING: "UPDATING",
|
|
117
|
+
};
|
|
118
|
+
export const InstanceState = {
|
|
119
|
+
ACTIVE: "ACTIVE",
|
|
120
|
+
DEREGISTERED: "DEREGISTERED",
|
|
121
|
+
DEREGISTERING: "DEREGISTERING",
|
|
122
|
+
DEREGISTRATION_ERROR: "DEREGISTRATION_ERROR",
|
|
123
|
+
REGISTERING: "REGISTERING",
|
|
124
|
+
REGISTRATION_ERROR: "REGISTRATION_ERROR",
|
|
125
|
+
};
|
|
95
126
|
export const DurationUnits = {
|
|
96
127
|
MONTHS: "MONTHS",
|
|
97
128
|
};
|
|
@@ -124,6 +155,19 @@ export class BadRequestException extends __BaseException {
|
|
|
124
155
|
this.Message = opts.Message;
|
|
125
156
|
}
|
|
126
157
|
}
|
|
158
|
+
export class ConflictException extends __BaseException {
|
|
159
|
+
constructor(opts) {
|
|
160
|
+
super({
|
|
161
|
+
name: "ConflictException",
|
|
162
|
+
$fault: "client",
|
|
163
|
+
...opts,
|
|
164
|
+
});
|
|
165
|
+
this.name = "ConflictException";
|
|
166
|
+
this.$fault = "client";
|
|
167
|
+
Object.setPrototypeOf(this, ConflictException.prototype);
|
|
168
|
+
this.Message = opts.Message;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
127
171
|
export class ForbiddenException extends __BaseException {
|
|
128
172
|
constructor(opts) {
|
|
129
173
|
super({
|
|
@@ -202,6 +246,35 @@ export class AddFlowOutputs420Exception extends __BaseException {
|
|
|
202
246
|
this.Message = opts.Message;
|
|
203
247
|
}
|
|
204
248
|
}
|
|
249
|
+
export const FailoverMode = {
|
|
250
|
+
FAILOVER: "FAILOVER",
|
|
251
|
+
MERGE: "MERGE",
|
|
252
|
+
};
|
|
253
|
+
export const State = {
|
|
254
|
+
DISABLED: "DISABLED",
|
|
255
|
+
ENABLED: "ENABLED",
|
|
256
|
+
};
|
|
257
|
+
export const BridgePlacement = {
|
|
258
|
+
AVAILABLE: "AVAILABLE",
|
|
259
|
+
LOCKED: "LOCKED",
|
|
260
|
+
};
|
|
261
|
+
export const ConnectionStatus = {
|
|
262
|
+
CONNECTED: "CONNECTED",
|
|
263
|
+
DISCONNECTED: "DISCONNECTED",
|
|
264
|
+
};
|
|
265
|
+
export class CreateBridge420Exception extends __BaseException {
|
|
266
|
+
constructor(opts) {
|
|
267
|
+
super({
|
|
268
|
+
name: "CreateBridge420Exception",
|
|
269
|
+
$fault: "client",
|
|
270
|
+
...opts,
|
|
271
|
+
});
|
|
272
|
+
this.name = "CreateBridge420Exception";
|
|
273
|
+
this.$fault = "client";
|
|
274
|
+
Object.setPrototypeOf(this, CreateBridge420Exception.prototype);
|
|
275
|
+
this.Message = opts.Message;
|
|
276
|
+
}
|
|
277
|
+
}
|
|
205
278
|
export class CreateFlow420Exception extends __BaseException {
|
|
206
279
|
constructor(opts) {
|
|
207
280
|
super({
|
|
@@ -215,13 +288,23 @@ export class CreateFlow420Exception extends __BaseException {
|
|
|
215
288
|
this.Message = opts.Message;
|
|
216
289
|
}
|
|
217
290
|
}
|
|
218
|
-
export
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
291
|
+
export class CreateGateway420Exception extends __BaseException {
|
|
292
|
+
constructor(opts) {
|
|
293
|
+
super({
|
|
294
|
+
name: "CreateGateway420Exception",
|
|
295
|
+
$fault: "client",
|
|
296
|
+
...opts,
|
|
297
|
+
});
|
|
298
|
+
this.name = "CreateGateway420Exception";
|
|
299
|
+
this.$fault = "client";
|
|
300
|
+
Object.setPrototypeOf(this, CreateGateway420Exception.prototype);
|
|
301
|
+
this.Message = opts.Message;
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
export const DesiredState = {
|
|
305
|
+
ACTIVE: "ACTIVE",
|
|
306
|
+
DELETED: "DELETED",
|
|
307
|
+
STANDBY: "STANDBY",
|
|
225
308
|
};
|
|
226
309
|
export class GrantFlowEntitlements420Exception extends __BaseException {
|
|
227
310
|
constructor(opts) {
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ListBridgesCommand } from "../commands/ListBridgesCommand";
|
|
2
|
+
import { MediaConnectClient } from "../MediaConnectClient";
|
|
3
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
4
|
+
return await client.send(new ListBridgesCommand(input), ...args);
|
|
5
|
+
};
|
|
6
|
+
export async function* paginateListBridges(config, input, ...additionalArguments) {
|
|
7
|
+
let token = config.startingToken || undefined;
|
|
8
|
+
let hasNext = true;
|
|
9
|
+
let page;
|
|
10
|
+
while (hasNext) {
|
|
11
|
+
input.NextToken = token;
|
|
12
|
+
input["MaxResults"] = config.pageSize;
|
|
13
|
+
if (config.client instanceof MediaConnectClient) {
|
|
14
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
throw new Error("Invalid client, expected MediaConnect | MediaConnectClient");
|
|
18
|
+
}
|
|
19
|
+
yield page;
|
|
20
|
+
const prevToken = token;
|
|
21
|
+
token = page.NextToken;
|
|
22
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
+
}
|
|
24
|
+
return undefined;
|
|
25
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ListGatewayInstancesCommand, } from "../commands/ListGatewayInstancesCommand";
|
|
2
|
+
import { MediaConnectClient } from "../MediaConnectClient";
|
|
3
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
4
|
+
return await client.send(new ListGatewayInstancesCommand(input), ...args);
|
|
5
|
+
};
|
|
6
|
+
export async function* paginateListGatewayInstances(config, input, ...additionalArguments) {
|
|
7
|
+
let token = config.startingToken || undefined;
|
|
8
|
+
let hasNext = true;
|
|
9
|
+
let page;
|
|
10
|
+
while (hasNext) {
|
|
11
|
+
input.NextToken = token;
|
|
12
|
+
input["MaxResults"] = config.pageSize;
|
|
13
|
+
if (config.client instanceof MediaConnectClient) {
|
|
14
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
throw new Error("Invalid client, expected MediaConnect | MediaConnectClient");
|
|
18
|
+
}
|
|
19
|
+
yield page;
|
|
20
|
+
const prevToken = token;
|
|
21
|
+
token = page.NextToken;
|
|
22
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
+
}
|
|
24
|
+
return undefined;
|
|
25
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ListGatewaysCommand, } from "../commands/ListGatewaysCommand";
|
|
2
|
+
import { MediaConnectClient } from "../MediaConnectClient";
|
|
3
|
+
const makePagedClientRequest = async (client, input, ...args) => {
|
|
4
|
+
return await client.send(new ListGatewaysCommand(input), ...args);
|
|
5
|
+
};
|
|
6
|
+
export async function* paginateListGateways(config, input, ...additionalArguments) {
|
|
7
|
+
let token = config.startingToken || undefined;
|
|
8
|
+
let hasNext = true;
|
|
9
|
+
let page;
|
|
10
|
+
while (hasNext) {
|
|
11
|
+
input.NextToken = token;
|
|
12
|
+
input["MaxResults"] = config.pageSize;
|
|
13
|
+
if (config.client instanceof MediaConnectClient) {
|
|
14
|
+
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
throw new Error("Invalid client, expected MediaConnect | MediaConnectClient");
|
|
18
|
+
}
|
|
19
|
+
yield page;
|
|
20
|
+
const prevToken = token;
|
|
21
|
+
token = page.NextToken;
|
|
22
|
+
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
+
}
|
|
24
|
+
return undefined;
|
|
25
|
+
}
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
export * from "./Interfaces";
|
|
2
|
+
export * from "./ListBridgesPaginator";
|
|
2
3
|
export * from "./ListEntitlementsPaginator";
|
|
3
4
|
export * from "./ListFlowsPaginator";
|
|
5
|
+
export * from "./ListGatewayInstancesPaginator";
|
|
6
|
+
export * from "./ListGatewaysPaginator";
|
|
4
7
|
export * from "./ListOfferingsPaginator";
|
|
5
8
|
export * from "./ListReservationsPaginator";
|