@aws-sdk/client-batch 3.476.0 → 3.478.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/dist-cjs/pagination/DescribeComputeEnvironmentsPaginator.js +2 -24
- package/dist-cjs/pagination/DescribeJobDefinitionsPaginator.js +2 -24
- package/dist-cjs/pagination/DescribeJobQueuesPaginator.js +2 -24
- package/dist-cjs/pagination/ListJobsPaginator.js +2 -24
- package/dist-cjs/pagination/ListSchedulingPoliciesPaginator.js +2 -24
- package/dist-cjs/protocols/Aws_restJson1.js +103 -271
- package/dist-es/pagination/DescribeComputeEnvironmentsPaginator.js +2 -23
- package/dist-es/pagination/DescribeJobDefinitionsPaginator.js +2 -23
- package/dist-es/pagination/DescribeJobQueuesPaginator.js +2 -23
- package/dist-es/pagination/ListJobsPaginator.js +2 -23
- package/dist-es/pagination/ListSchedulingPoliciesPaginator.js +2 -23
- package/dist-es/protocols/Aws_restJson1.js +104 -272
- package/dist-types/pagination/DescribeComputeEnvironmentsPaginator.d.ts +1 -1
- package/dist-types/pagination/DescribeJobDefinitionsPaginator.d.ts +1 -1
- package/dist-types/pagination/DescribeJobQueuesPaginator.d.ts +1 -1
- package/dist-types/pagination/ListJobsPaginator.d.ts +1 -1
- package/dist-types/pagination/ListSchedulingPoliciesPaginator.d.ts +1 -1
- package/dist-types/ts3.4/pagination/DescribeComputeEnvironmentsPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/DescribeJobDefinitionsPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/DescribeJobQueuesPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListJobsPaginator.d.ts +3 -3
- package/dist-types/ts3.4/pagination/ListSchedulingPoliciesPaginator.d.ts +3 -3
- package/package.json +7 -6
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { BatchClient } from "../BatchClient";
|
|
2
3
|
import { DescribeComputeEnvironmentsCommand, } from "../commands/DescribeComputeEnvironmentsCommand";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new DescribeComputeEnvironmentsCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateDescribeComputeEnvironments(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 BatchClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected Batch | BatchClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.nextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateDescribeComputeEnvironments = createPaginator(BatchClient, DescribeComputeEnvironmentsCommand, "nextToken", "nextToken", "maxResults");
|
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { BatchClient } from "../BatchClient";
|
|
2
3
|
import { DescribeJobDefinitionsCommand, } from "../commands/DescribeJobDefinitionsCommand";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new DescribeJobDefinitionsCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateDescribeJobDefinitions(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 BatchClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected Batch | BatchClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.nextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateDescribeJobDefinitions = createPaginator(BatchClient, DescribeJobDefinitionsCommand, "nextToken", "nextToken", "maxResults");
|
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { BatchClient } from "../BatchClient";
|
|
2
3
|
import { DescribeJobQueuesCommand, } from "../commands/DescribeJobQueuesCommand";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new DescribeJobQueuesCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateDescribeJobQueues(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 BatchClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected Batch | BatchClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.nextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateDescribeJobQueues = createPaginator(BatchClient, DescribeJobQueuesCommand, "nextToken", "nextToken", "maxResults");
|
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { BatchClient } from "../BatchClient";
|
|
2
3
|
import { ListJobsCommand } from "../commands/ListJobsCommand";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListJobsCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListJobs(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 BatchClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected Batch | BatchClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.nextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateListJobs = createPaginator(BatchClient, ListJobsCommand, "nextToken", "nextToken", "maxResults");
|
|
@@ -1,25 +1,4 @@
|
|
|
1
|
+
import { createPaginator } from "@smithy/core";
|
|
1
2
|
import { BatchClient } from "../BatchClient";
|
|
2
3
|
import { ListSchedulingPoliciesCommand, } from "../commands/ListSchedulingPoliciesCommand";
|
|
3
|
-
const
|
|
4
|
-
return await client.send(new ListSchedulingPoliciesCommand(input), ...args);
|
|
5
|
-
};
|
|
6
|
-
export async function* paginateListSchedulingPolicies(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 BatchClient) {
|
|
14
|
-
page = await makePagedClientRequest(config.client, input, ...additionalArguments);
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
throw new Error("Invalid client, expected Batch | BatchClient");
|
|
18
|
-
}
|
|
19
|
-
yield page;
|
|
20
|
-
const prevToken = token;
|
|
21
|
-
token = page.nextToken;
|
|
22
|
-
hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
|
|
23
|
-
}
|
|
24
|
-
return undefined;
|
|
25
|
-
}
|
|
4
|
+
export const paginateListSchedulingPolicies = createPaginator(BatchClient, ListSchedulingPoliciesCommand, "nextToken", "nextToken", "maxResults");
|