@aws-sdk/client-rekognition 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.
Files changed (73) hide show
  1. package/dist-cjs/pagination/DescribeProjectVersionsPaginator.js +2 -24
  2. package/dist-cjs/pagination/DescribeProjectsPaginator.js +2 -24
  3. package/dist-cjs/pagination/GetCelebrityRecognitionPaginator.js +2 -24
  4. package/dist-cjs/pagination/GetContentModerationPaginator.js +2 -24
  5. package/dist-cjs/pagination/GetFaceDetectionPaginator.js +2 -24
  6. package/dist-cjs/pagination/GetFaceSearchPaginator.js +2 -24
  7. package/dist-cjs/pagination/GetLabelDetectionPaginator.js +2 -24
  8. package/dist-cjs/pagination/GetPersonTrackingPaginator.js +2 -24
  9. package/dist-cjs/pagination/GetSegmentDetectionPaginator.js +2 -24
  10. package/dist-cjs/pagination/GetTextDetectionPaginator.js +2 -24
  11. package/dist-cjs/pagination/ListCollectionsPaginator.js +2 -24
  12. package/dist-cjs/pagination/ListDatasetEntriesPaginator.js +2 -24
  13. package/dist-cjs/pagination/ListDatasetLabelsPaginator.js +2 -24
  14. package/dist-cjs/pagination/ListFacesPaginator.js +2 -24
  15. package/dist-cjs/pagination/ListMediaAnalysisJobsPaginator.js +2 -24
  16. package/dist-cjs/pagination/ListProjectPoliciesPaginator.js +2 -24
  17. package/dist-cjs/pagination/ListStreamProcessorsPaginator.js +2 -24
  18. package/dist-cjs/pagination/ListUsersPaginator.js +2 -24
  19. package/dist-es/pagination/DescribeProjectVersionsPaginator.js +2 -23
  20. package/dist-es/pagination/DescribeProjectsPaginator.js +2 -23
  21. package/dist-es/pagination/GetCelebrityRecognitionPaginator.js +2 -23
  22. package/dist-es/pagination/GetContentModerationPaginator.js +2 -23
  23. package/dist-es/pagination/GetFaceDetectionPaginator.js +2 -23
  24. package/dist-es/pagination/GetFaceSearchPaginator.js +2 -23
  25. package/dist-es/pagination/GetLabelDetectionPaginator.js +2 -23
  26. package/dist-es/pagination/GetPersonTrackingPaginator.js +2 -23
  27. package/dist-es/pagination/GetSegmentDetectionPaginator.js +2 -23
  28. package/dist-es/pagination/GetTextDetectionPaginator.js +2 -23
  29. package/dist-es/pagination/ListCollectionsPaginator.js +2 -23
  30. package/dist-es/pagination/ListDatasetEntriesPaginator.js +2 -23
  31. package/dist-es/pagination/ListDatasetLabelsPaginator.js +2 -23
  32. package/dist-es/pagination/ListFacesPaginator.js +2 -23
  33. package/dist-es/pagination/ListMediaAnalysisJobsPaginator.js +2 -23
  34. package/dist-es/pagination/ListProjectPoliciesPaginator.js +2 -23
  35. package/dist-es/pagination/ListStreamProcessorsPaginator.js +2 -23
  36. package/dist-es/pagination/ListUsersPaginator.js +2 -23
  37. package/dist-types/pagination/DescribeProjectVersionsPaginator.d.ts +1 -1
  38. package/dist-types/pagination/DescribeProjectsPaginator.d.ts +1 -1
  39. package/dist-types/pagination/GetCelebrityRecognitionPaginator.d.ts +1 -1
  40. package/dist-types/pagination/GetContentModerationPaginator.d.ts +1 -1
  41. package/dist-types/pagination/GetFaceDetectionPaginator.d.ts +1 -1
  42. package/dist-types/pagination/GetFaceSearchPaginator.d.ts +1 -1
  43. package/dist-types/pagination/GetLabelDetectionPaginator.d.ts +1 -1
  44. package/dist-types/pagination/GetPersonTrackingPaginator.d.ts +1 -1
  45. package/dist-types/pagination/GetSegmentDetectionPaginator.d.ts +1 -1
  46. package/dist-types/pagination/GetTextDetectionPaginator.d.ts +1 -1
  47. package/dist-types/pagination/ListCollectionsPaginator.d.ts +1 -1
  48. package/dist-types/pagination/ListDatasetEntriesPaginator.d.ts +1 -1
  49. package/dist-types/pagination/ListDatasetLabelsPaginator.d.ts +1 -1
  50. package/dist-types/pagination/ListFacesPaginator.d.ts +1 -1
  51. package/dist-types/pagination/ListMediaAnalysisJobsPaginator.d.ts +1 -1
  52. package/dist-types/pagination/ListProjectPoliciesPaginator.d.ts +1 -1
  53. package/dist-types/pagination/ListStreamProcessorsPaginator.d.ts +1 -1
  54. package/dist-types/pagination/ListUsersPaginator.d.ts +1 -1
  55. package/dist-types/ts3.4/pagination/DescribeProjectVersionsPaginator.d.ts +3 -3
  56. package/dist-types/ts3.4/pagination/DescribeProjectsPaginator.d.ts +3 -3
  57. package/dist-types/ts3.4/pagination/GetCelebrityRecognitionPaginator.d.ts +3 -3
  58. package/dist-types/ts3.4/pagination/GetContentModerationPaginator.d.ts +3 -3
  59. package/dist-types/ts3.4/pagination/GetFaceDetectionPaginator.d.ts +3 -3
  60. package/dist-types/ts3.4/pagination/GetFaceSearchPaginator.d.ts +3 -3
  61. package/dist-types/ts3.4/pagination/GetLabelDetectionPaginator.d.ts +3 -3
  62. package/dist-types/ts3.4/pagination/GetPersonTrackingPaginator.d.ts +3 -3
  63. package/dist-types/ts3.4/pagination/GetSegmentDetectionPaginator.d.ts +3 -3
  64. package/dist-types/ts3.4/pagination/GetTextDetectionPaginator.d.ts +3 -3
  65. package/dist-types/ts3.4/pagination/ListCollectionsPaginator.d.ts +3 -3
  66. package/dist-types/ts3.4/pagination/ListDatasetEntriesPaginator.d.ts +3 -3
  67. package/dist-types/ts3.4/pagination/ListDatasetLabelsPaginator.d.ts +3 -3
  68. package/dist-types/ts3.4/pagination/ListFacesPaginator.d.ts +3 -3
  69. package/dist-types/ts3.4/pagination/ListMediaAnalysisJobsPaginator.d.ts +3 -3
  70. package/dist-types/ts3.4/pagination/ListProjectPoliciesPaginator.d.ts +3 -3
  71. package/dist-types/ts3.4/pagination/ListStreamProcessorsPaginator.d.ts +3 -3
  72. package/dist-types/ts3.4/pagination/ListUsersPaginator.d.ts +3 -3
  73. package/package.json +7 -6
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateDescribeProjectVersions = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const DescribeProjectVersionsCommand_1 = require("../commands/DescribeProjectVersionsCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new DescribeProjectVersionsCommand_1.DescribeProjectVersionsCommand(input), ...args);
8
- };
9
- async function* paginateDescribeProjectVersions(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateDescribeProjectVersions = paginateDescribeProjectVersions;
7
+ exports.paginateDescribeProjectVersions = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, DescribeProjectVersionsCommand_1.DescribeProjectVersionsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateDescribeProjects = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const DescribeProjectsCommand_1 = require("../commands/DescribeProjectsCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new DescribeProjectsCommand_1.DescribeProjectsCommand(input), ...args);
8
- };
9
- async function* paginateDescribeProjects(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateDescribeProjects = paginateDescribeProjects;
7
+ exports.paginateDescribeProjects = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, DescribeProjectsCommand_1.DescribeProjectsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetCelebrityRecognition = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetCelebrityRecognitionCommand_1 = require("../commands/GetCelebrityRecognitionCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetCelebrityRecognitionCommand_1.GetCelebrityRecognitionCommand(input), ...args);
8
- };
9
- async function* paginateGetCelebrityRecognition(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetCelebrityRecognition = paginateGetCelebrityRecognition;
7
+ exports.paginateGetCelebrityRecognition = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetCelebrityRecognitionCommand_1.GetCelebrityRecognitionCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetContentModeration = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetContentModerationCommand_1 = require("../commands/GetContentModerationCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetContentModerationCommand_1.GetContentModerationCommand(input), ...args);
8
- };
9
- async function* paginateGetContentModeration(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetContentModeration = paginateGetContentModeration;
7
+ exports.paginateGetContentModeration = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetContentModerationCommand_1.GetContentModerationCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetFaceDetection = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetFaceDetectionCommand_1 = require("../commands/GetFaceDetectionCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetFaceDetectionCommand_1.GetFaceDetectionCommand(input), ...args);
8
- };
9
- async function* paginateGetFaceDetection(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetFaceDetection = paginateGetFaceDetection;
7
+ exports.paginateGetFaceDetection = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetFaceDetectionCommand_1.GetFaceDetectionCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetFaceSearch = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetFaceSearchCommand_1 = require("../commands/GetFaceSearchCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetFaceSearchCommand_1.GetFaceSearchCommand(input), ...args);
8
- };
9
- async function* paginateGetFaceSearch(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetFaceSearch = paginateGetFaceSearch;
7
+ exports.paginateGetFaceSearch = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetFaceSearchCommand_1.GetFaceSearchCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetLabelDetection = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetLabelDetectionCommand_1 = require("../commands/GetLabelDetectionCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetLabelDetectionCommand_1.GetLabelDetectionCommand(input), ...args);
8
- };
9
- async function* paginateGetLabelDetection(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetLabelDetection = paginateGetLabelDetection;
7
+ exports.paginateGetLabelDetection = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetLabelDetectionCommand_1.GetLabelDetectionCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetPersonTracking = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetPersonTrackingCommand_1 = require("../commands/GetPersonTrackingCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetPersonTrackingCommand_1.GetPersonTrackingCommand(input), ...args);
8
- };
9
- async function* paginateGetPersonTracking(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetPersonTracking = paginateGetPersonTracking;
7
+ exports.paginateGetPersonTracking = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetPersonTrackingCommand_1.GetPersonTrackingCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetSegmentDetection = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetSegmentDetectionCommand_1 = require("../commands/GetSegmentDetectionCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetSegmentDetectionCommand_1.GetSegmentDetectionCommand(input), ...args);
8
- };
9
- async function* paginateGetSegmentDetection(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetSegmentDetection = paginateGetSegmentDetection;
7
+ exports.paginateGetSegmentDetection = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetSegmentDetectionCommand_1.GetSegmentDetectionCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateGetTextDetection = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const GetTextDetectionCommand_1 = require("../commands/GetTextDetectionCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new GetTextDetectionCommand_1.GetTextDetectionCommand(input), ...args);
8
- };
9
- async function* paginateGetTextDetection(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateGetTextDetection = paginateGetTextDetection;
7
+ exports.paginateGetTextDetection = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, GetTextDetectionCommand_1.GetTextDetectionCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListCollections = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListCollectionsCommand_1 = require("../commands/ListCollectionsCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListCollectionsCommand_1.ListCollectionsCommand(input), ...args);
8
- };
9
- async function* paginateListCollections(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListCollections = paginateListCollections;
7
+ exports.paginateListCollections = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListCollectionsCommand_1.ListCollectionsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListDatasetEntries = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListDatasetEntriesCommand_1 = require("../commands/ListDatasetEntriesCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListDatasetEntriesCommand_1.ListDatasetEntriesCommand(input), ...args);
8
- };
9
- async function* paginateListDatasetEntries(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListDatasetEntries = paginateListDatasetEntries;
7
+ exports.paginateListDatasetEntries = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListDatasetEntriesCommand_1.ListDatasetEntriesCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListDatasetLabels = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListDatasetLabelsCommand_1 = require("../commands/ListDatasetLabelsCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListDatasetLabelsCommand_1.ListDatasetLabelsCommand(input), ...args);
8
- };
9
- async function* paginateListDatasetLabels(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListDatasetLabels = paginateListDatasetLabels;
7
+ exports.paginateListDatasetLabels = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListDatasetLabelsCommand_1.ListDatasetLabelsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListFaces = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListFacesCommand_1 = require("../commands/ListFacesCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListFacesCommand_1.ListFacesCommand(input), ...args);
8
- };
9
- async function* paginateListFaces(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListFaces = paginateListFaces;
7
+ exports.paginateListFaces = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListFacesCommand_1.ListFacesCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListMediaAnalysisJobs = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListMediaAnalysisJobsCommand_1 = require("../commands/ListMediaAnalysisJobsCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListMediaAnalysisJobsCommand_1.ListMediaAnalysisJobsCommand(input), ...args);
8
- };
9
- async function* paginateListMediaAnalysisJobs(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListMediaAnalysisJobs = paginateListMediaAnalysisJobs;
7
+ exports.paginateListMediaAnalysisJobs = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListMediaAnalysisJobsCommand_1.ListMediaAnalysisJobsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListProjectPolicies = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListProjectPoliciesCommand_1 = require("../commands/ListProjectPoliciesCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListProjectPoliciesCommand_1.ListProjectPoliciesCommand(input), ...args);
8
- };
9
- async function* paginateListProjectPolicies(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListProjectPolicies = paginateListProjectPolicies;
7
+ exports.paginateListProjectPolicies = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListProjectPoliciesCommand_1.ListProjectPoliciesCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListStreamProcessors = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListStreamProcessorsCommand_1 = require("../commands/ListStreamProcessorsCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListStreamProcessorsCommand_1.ListStreamProcessorsCommand(input), ...args);
8
- };
9
- async function* paginateListStreamProcessors(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListStreamProcessors = paginateListStreamProcessors;
7
+ exports.paginateListStreamProcessors = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListStreamProcessorsCommand_1.ListStreamProcessorsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,29 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.paginateListUsers = void 0;
4
+ const core_1 = require("@smithy/core");
4
5
  const ListUsersCommand_1 = require("../commands/ListUsersCommand");
5
6
  const RekognitionClient_1 = require("../RekognitionClient");
6
- const makePagedClientRequest = async (client, input, ...args) => {
7
- return await client.send(new ListUsersCommand_1.ListUsersCommand(input), ...args);
8
- };
9
- async function* paginateListUsers(config, input, ...additionalArguments) {
10
- let token = config.startingToken || undefined;
11
- let hasNext = true;
12
- let page;
13
- while (hasNext) {
14
- input.NextToken = token;
15
- input["MaxResults"] = config.pageSize;
16
- if (config.client instanceof RekognitionClient_1.RekognitionClient) {
17
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
18
- }
19
- else {
20
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
21
- }
22
- yield page;
23
- const prevToken = token;
24
- token = page.NextToken;
25
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
26
- }
27
- return undefined;
28
- }
29
- exports.paginateListUsers = paginateListUsers;
7
+ exports.paginateListUsers = (0, core_1.createPaginator)(RekognitionClient_1.RekognitionClient, ListUsersCommand_1.ListUsersCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { DescribeProjectVersionsCommand, } from "../commands/DescribeProjectVersionsCommand";
2
3
  import { RekognitionClient } from "../RekognitionClient";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new DescribeProjectVersionsCommand(input), ...args);
5
- };
6
- export async function* paginateDescribeProjectVersions(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 RekognitionClient) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
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 paginateDescribeProjectVersions = createPaginator(RekognitionClient, DescribeProjectVersionsCommand, "NextToken", "NextToken", "MaxResults");
@@ -1,25 +1,4 @@
1
+ import { createPaginator } from "@smithy/core";
1
2
  import { DescribeProjectsCommand, } from "../commands/DescribeProjectsCommand";
2
3
  import { RekognitionClient } from "../RekognitionClient";
3
- const makePagedClientRequest = async (client, input, ...args) => {
4
- return await client.send(new DescribeProjectsCommand(input), ...args);
5
- };
6
- export async function* paginateDescribeProjects(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 RekognitionClient) {
14
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
15
- }
16
- else {
17
- throw new Error("Invalid client, expected Rekognition | RekognitionClient");
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 paginateDescribeProjects = createPaginator(RekognitionClient, DescribeProjectsCommand, "NextToken", "NextToken", "MaxResults");