@aws-sdk/client-healthlake 3.183.0 → 3.185.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 (29) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist-cjs/protocols/Aws_json1_0.js +2 -2
  3. package/dist-es/HealthLake.js +61 -54
  4. package/dist-es/HealthLakeClient.js +28 -22
  5. package/dist-es/commands/CreateFHIRDatastoreCommand.js +28 -21
  6. package/dist-es/commands/DeleteFHIRDatastoreCommand.js +28 -21
  7. package/dist-es/commands/DescribeFHIRDatastoreCommand.js +28 -21
  8. package/dist-es/commands/DescribeFHIRExportJobCommand.js +28 -21
  9. package/dist-es/commands/DescribeFHIRImportJobCommand.js +28 -21
  10. package/dist-es/commands/ListFHIRDatastoresCommand.js +28 -21
  11. package/dist-es/commands/ListFHIRExportJobsCommand.js +28 -21
  12. package/dist-es/commands/ListFHIRImportJobsCommand.js +28 -21
  13. package/dist-es/commands/ListTagsForResourceCommand.js +28 -21
  14. package/dist-es/commands/StartFHIRExportJobCommand.js +28 -21
  15. package/dist-es/commands/StartFHIRImportJobCommand.js +28 -21
  16. package/dist-es/commands/TagResourceCommand.js +28 -21
  17. package/dist-es/commands/UntagResourceCommand.js +28 -21
  18. package/dist-es/endpoints.js +8 -8
  19. package/dist-es/models/HealthLakeServiceException.js +10 -5
  20. package/dist-es/models/models_0.js +124 -201
  21. package/dist-es/pagination/ListFHIRDatastoresPaginator.js +68 -25
  22. package/dist-es/pagination/ListFHIRExportJobsPaginator.js +68 -25
  23. package/dist-es/pagination/ListFHIRImportJobsPaginator.js +68 -25
  24. package/dist-es/protocols/Aws_json1_0.js +1181 -932
  25. package/dist-es/runtimeConfig.browser.js +12 -26
  26. package/dist-es/runtimeConfig.js +12 -30
  27. package/dist-es/runtimeConfig.native.js +5 -8
  28. package/dist-es/runtimeConfig.shared.js +11 -8
  29. package/package.json +5 -5
@@ -1,35 +1,36 @@
1
+ import { __assign, __extends } from "tslib";
1
2
  import { HealthLakeServiceException as __BaseException } from "./HealthLakeServiceException";
2
- export class AccessDeniedException extends __BaseException {
3
- constructor(opts) {
4
- super({
5
- name: "AccessDeniedException",
6
- $fault: "client",
7
- ...opts,
8
- });
9
- this.name = "AccessDeniedException";
10
- this.$fault = "client";
11
- Object.setPrototypeOf(this, AccessDeniedException.prototype);
12
- this.Message = opts.Message;
3
+ var AccessDeniedException = (function (_super) {
4
+ __extends(AccessDeniedException, _super);
5
+ function AccessDeniedException(opts) {
6
+ var _this = _super.call(this, __assign({ name: "AccessDeniedException", $fault: "client" }, opts)) || this;
7
+ _this.name = "AccessDeniedException";
8
+ _this.$fault = "client";
9
+ Object.setPrototypeOf(_this, AccessDeniedException.prototype);
10
+ _this.Message = opts.Message;
11
+ return _this;
13
12
  }
14
- }
13
+ return AccessDeniedException;
14
+ }(__BaseException));
15
+ export { AccessDeniedException };
15
16
  export var CmkType;
16
17
  (function (CmkType) {
17
18
  CmkType["AO_CMK"] = "AWS_OWNED_KMS_KEY";
18
19
  CmkType["CM_CMK"] = "CUSTOMER_MANAGED_KMS_KEY";
19
20
  })(CmkType || (CmkType = {}));
20
- export class ConflictException extends __BaseException {
21
- constructor(opts) {
22
- super({
23
- name: "ConflictException",
24
- $fault: "client",
25
- ...opts,
26
- });
27
- this.name = "ConflictException";
28
- this.$fault = "client";
29
- Object.setPrototypeOf(this, ConflictException.prototype);
30
- this.Message = opts.Message;
21
+ var ConflictException = (function (_super) {
22
+ __extends(ConflictException, _super);
23
+ function ConflictException(opts) {
24
+ var _this = _super.call(this, __assign({ name: "ConflictException", $fault: "client" }, opts)) || this;
25
+ _this.name = "ConflictException";
26
+ _this.$fault = "client";
27
+ Object.setPrototypeOf(_this, ConflictException.prototype);
28
+ _this.Message = opts.Message;
29
+ return _this;
31
30
  }
32
- }
31
+ return ConflictException;
32
+ }(__BaseException));
33
+ export { ConflictException };
33
34
  export var FHIRVersion;
34
35
  (function (FHIRVersion) {
35
36
  FHIRVersion["R4"] = "R4";
@@ -45,58 +46,58 @@ export var DatastoreStatus;
45
46
  DatastoreStatus["DELETED"] = "DELETED";
46
47
  DatastoreStatus["DELETING"] = "DELETING";
47
48
  })(DatastoreStatus || (DatastoreStatus = {}));
48
- export class InternalServerException extends __BaseException {
49
- constructor(opts) {
50
- super({
51
- name: "InternalServerException",
52
- $fault: "server",
53
- ...opts,
54
- });
55
- this.name = "InternalServerException";
56
- this.$fault = "server";
57
- Object.setPrototypeOf(this, InternalServerException.prototype);
58
- this.Message = opts.Message;
49
+ var InternalServerException = (function (_super) {
50
+ __extends(InternalServerException, _super);
51
+ function InternalServerException(opts) {
52
+ var _this = _super.call(this, __assign({ name: "InternalServerException", $fault: "server" }, opts)) || this;
53
+ _this.name = "InternalServerException";
54
+ _this.$fault = "server";
55
+ Object.setPrototypeOf(_this, InternalServerException.prototype);
56
+ _this.Message = opts.Message;
57
+ return _this;
59
58
  }
60
- }
61
- export class ThrottlingException extends __BaseException {
62
- constructor(opts) {
63
- super({
64
- name: "ThrottlingException",
65
- $fault: "client",
66
- ...opts,
67
- });
68
- this.name = "ThrottlingException";
69
- this.$fault = "client";
70
- Object.setPrototypeOf(this, ThrottlingException.prototype);
71
- this.Message = opts.Message;
59
+ return InternalServerException;
60
+ }(__BaseException));
61
+ export { InternalServerException };
62
+ var ThrottlingException = (function (_super) {
63
+ __extends(ThrottlingException, _super);
64
+ function ThrottlingException(opts) {
65
+ var _this = _super.call(this, __assign({ name: "ThrottlingException", $fault: "client" }, opts)) || this;
66
+ _this.name = "ThrottlingException";
67
+ _this.$fault = "client";
68
+ Object.setPrototypeOf(_this, ThrottlingException.prototype);
69
+ _this.Message = opts.Message;
70
+ return _this;
72
71
  }
73
- }
74
- export class ValidationException extends __BaseException {
75
- constructor(opts) {
76
- super({
77
- name: "ValidationException",
78
- $fault: "client",
79
- ...opts,
80
- });
81
- this.name = "ValidationException";
82
- this.$fault = "client";
83
- Object.setPrototypeOf(this, ValidationException.prototype);
84
- this.Message = opts.Message;
72
+ return ThrottlingException;
73
+ }(__BaseException));
74
+ export { ThrottlingException };
75
+ var ValidationException = (function (_super) {
76
+ __extends(ValidationException, _super);
77
+ function ValidationException(opts) {
78
+ var _this = _super.call(this, __assign({ name: "ValidationException", $fault: "client" }, opts)) || this;
79
+ _this.name = "ValidationException";
80
+ _this.$fault = "client";
81
+ Object.setPrototypeOf(_this, ValidationException.prototype);
82
+ _this.Message = opts.Message;
83
+ return _this;
85
84
  }
86
- }
87
- export class ResourceNotFoundException extends __BaseException {
88
- constructor(opts) {
89
- super({
90
- name: "ResourceNotFoundException",
91
- $fault: "client",
92
- ...opts,
93
- });
94
- this.name = "ResourceNotFoundException";
95
- this.$fault = "client";
96
- Object.setPrototypeOf(this, ResourceNotFoundException.prototype);
97
- this.Message = opts.Message;
85
+ return ValidationException;
86
+ }(__BaseException));
87
+ export { ValidationException };
88
+ var ResourceNotFoundException = (function (_super) {
89
+ __extends(ResourceNotFoundException, _super);
90
+ function ResourceNotFoundException(opts) {
91
+ var _this = _super.call(this, __assign({ name: "ResourceNotFoundException", $fault: "client" }, opts)) || this;
92
+ _this.name = "ResourceNotFoundException";
93
+ _this.$fault = "client";
94
+ Object.setPrototypeOf(_this, ResourceNotFoundException.prototype);
95
+ _this.Message = opts.Message;
96
+ return _this;
98
97
  }
99
- }
98
+ return ResourceNotFoundException;
99
+ }(__BaseException));
100
+ export { ResourceNotFoundException };
100
101
  export var JobStatus;
101
102
  (function (JobStatus) {
102
103
  JobStatus["COMPLETED"] = "COMPLETED";
@@ -107,7 +108,7 @@ export var JobStatus;
107
108
  })(JobStatus || (JobStatus = {}));
108
109
  export var OutputDataConfig;
109
110
  (function (OutputDataConfig) {
110
- OutputDataConfig.visit = (value, visitor) => {
111
+ OutputDataConfig.visit = function (value, visitor) {
111
112
  if (value.S3Configuration !== undefined)
112
113
  return visitor.S3Configuration(value.S3Configuration);
113
114
  return visitor._(value.$unknown[0], value.$unknown[1]);
@@ -115,144 +116,66 @@ export var OutputDataConfig;
115
116
  })(OutputDataConfig || (OutputDataConfig = {}));
116
117
  export var InputDataConfig;
117
118
  (function (InputDataConfig) {
118
- InputDataConfig.visit = (value, visitor) => {
119
+ InputDataConfig.visit = function (value, visitor) {
119
120
  if (value.S3Uri !== undefined)
120
121
  return visitor.S3Uri(value.S3Uri);
121
122
  return visitor._(value.$unknown[0], value.$unknown[1]);
122
123
  };
123
124
  })(InputDataConfig || (InputDataConfig = {}));
124
- export const PreloadDataConfigFilterSensitiveLog = (obj) => ({
125
- ...obj,
126
- });
127
- export const KmsEncryptionConfigFilterSensitiveLog = (obj) => ({
128
- ...obj,
129
- });
130
- export const SseConfigurationFilterSensitiveLog = (obj) => ({
131
- ...obj,
132
- });
133
- export const TagFilterSensitiveLog = (obj) => ({
134
- ...obj,
135
- });
136
- export const CreateFHIRDatastoreRequestFilterSensitiveLog = (obj) => ({
137
- ...obj,
138
- });
139
- export const CreateFHIRDatastoreResponseFilterSensitiveLog = (obj) => ({
140
- ...obj,
141
- });
142
- export const DatastoreFilterFilterSensitiveLog = (obj) => ({
143
- ...obj,
144
- });
145
- export const DatastorePropertiesFilterSensitiveLog = (obj) => ({
146
- ...obj,
147
- });
148
- export const DeleteFHIRDatastoreRequestFilterSensitiveLog = (obj) => ({
149
- ...obj,
150
- });
151
- export const DeleteFHIRDatastoreResponseFilterSensitiveLog = (obj) => ({
152
- ...obj,
153
- });
154
- export const DescribeFHIRDatastoreRequestFilterSensitiveLog = (obj) => ({
155
- ...obj,
156
- });
157
- export const DescribeFHIRDatastoreResponseFilterSensitiveLog = (obj) => ({
158
- ...obj,
159
- });
160
- export const DescribeFHIRExportJobRequestFilterSensitiveLog = (obj) => ({
161
- ...obj,
162
- });
163
- export const S3ConfigurationFilterSensitiveLog = (obj) => ({
164
- ...obj,
165
- });
166
- export const OutputDataConfigFilterSensitiveLog = (obj) => {
125
+ export var PreloadDataConfigFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
126
+ export var KmsEncryptionConfigFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
127
+ export var SseConfigurationFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
128
+ export var TagFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
129
+ export var CreateFHIRDatastoreRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
130
+ export var CreateFHIRDatastoreResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
131
+ export var DatastoreFilterFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
132
+ export var DatastorePropertiesFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
133
+ export var DeleteFHIRDatastoreRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
134
+ export var DeleteFHIRDatastoreResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
135
+ export var DescribeFHIRDatastoreRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
136
+ export var DescribeFHIRDatastoreResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
137
+ export var DescribeFHIRExportJobRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
138
+ export var S3ConfigurationFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
139
+ export var OutputDataConfigFilterSensitiveLog = function (obj) {
140
+ var _a;
167
141
  if (obj.S3Configuration !== undefined)
168
142
  return { S3Configuration: S3ConfigurationFilterSensitiveLog(obj.S3Configuration) };
169
143
  if (obj.$unknown !== undefined)
170
- return { [obj.$unknown[0]]: "UNKNOWN" };
144
+ return _a = {}, _a[obj.$unknown[0]] = "UNKNOWN", _a;
171
145
  };
172
- export const ExportJobPropertiesFilterSensitiveLog = (obj) => ({
173
- ...obj,
174
- ...(obj.OutputDataConfig && { OutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.OutputDataConfig) }),
175
- });
176
- export const DescribeFHIRExportJobResponseFilterSensitiveLog = (obj) => ({
177
- ...obj,
178
- ...(obj.ExportJobProperties && {
179
- ExportJobProperties: ExportJobPropertiesFilterSensitiveLog(obj.ExportJobProperties),
180
- }),
181
- });
182
- export const DescribeFHIRImportJobRequestFilterSensitiveLog = (obj) => ({
183
- ...obj,
184
- });
185
- export const InputDataConfigFilterSensitiveLog = (obj) => {
146
+ export var ExportJobPropertiesFilterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.OutputDataConfig && { OutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.OutputDataConfig) }))); };
147
+ export var DescribeFHIRExportJobResponseFilterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.ExportJobProperties && {
148
+ ExportJobProperties: ExportJobPropertiesFilterSensitiveLog(obj.ExportJobProperties),
149
+ }))); };
150
+ export var DescribeFHIRImportJobRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
151
+ export var InputDataConfigFilterSensitiveLog = function (obj) {
152
+ var _a;
186
153
  if (obj.S3Uri !== undefined)
187
154
  return { S3Uri: obj.S3Uri };
188
155
  if (obj.$unknown !== undefined)
189
- return { [obj.$unknown[0]]: "UNKNOWN" };
156
+ return _a = {}, _a[obj.$unknown[0]] = "UNKNOWN", _a;
190
157
  };
191
- export const ImportJobPropertiesFilterSensitiveLog = (obj) => ({
192
- ...obj,
193
- ...(obj.InputDataConfig && { InputDataConfig: InputDataConfigFilterSensitiveLog(obj.InputDataConfig) }),
194
- ...(obj.JobOutputDataConfig && { JobOutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.JobOutputDataConfig) }),
195
- });
196
- export const DescribeFHIRImportJobResponseFilterSensitiveLog = (obj) => ({
197
- ...obj,
198
- ...(obj.ImportJobProperties && {
199
- ImportJobProperties: ImportJobPropertiesFilterSensitiveLog(obj.ImportJobProperties),
200
- }),
201
- });
202
- export const ListFHIRDatastoresRequestFilterSensitiveLog = (obj) => ({
203
- ...obj,
204
- });
205
- export const ListFHIRDatastoresResponseFilterSensitiveLog = (obj) => ({
206
- ...obj,
207
- });
208
- export const ListFHIRExportJobsRequestFilterSensitiveLog = (obj) => ({
209
- ...obj,
210
- });
211
- export const ListFHIRExportJobsResponseFilterSensitiveLog = (obj) => ({
212
- ...obj,
213
- ...(obj.ExportJobPropertiesList && {
214
- ExportJobPropertiesList: obj.ExportJobPropertiesList.map((item) => ExportJobPropertiesFilterSensitiveLog(item)),
215
- }),
216
- });
217
- export const ListFHIRImportJobsRequestFilterSensitiveLog = (obj) => ({
218
- ...obj,
219
- });
220
- export const ListFHIRImportJobsResponseFilterSensitiveLog = (obj) => ({
221
- ...obj,
222
- ...(obj.ImportJobPropertiesList && {
223
- ImportJobPropertiesList: obj.ImportJobPropertiesList.map((item) => ImportJobPropertiesFilterSensitiveLog(item)),
224
- }),
225
- });
226
- export const ListTagsForResourceRequestFilterSensitiveLog = (obj) => ({
227
- ...obj,
228
- });
229
- export const ListTagsForResourceResponseFilterSensitiveLog = (obj) => ({
230
- ...obj,
231
- });
232
- export const StartFHIRExportJobRequestFilterSensitiveLog = (obj) => ({
233
- ...obj,
234
- ...(obj.OutputDataConfig && { OutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.OutputDataConfig) }),
235
- });
236
- export const StartFHIRExportJobResponseFilterSensitiveLog = (obj) => ({
237
- ...obj,
238
- });
239
- export const StartFHIRImportJobRequestFilterSensitiveLog = (obj) => ({
240
- ...obj,
241
- ...(obj.InputDataConfig && { InputDataConfig: InputDataConfigFilterSensitiveLog(obj.InputDataConfig) }),
242
- ...(obj.JobOutputDataConfig && { JobOutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.JobOutputDataConfig) }),
243
- });
244
- export const StartFHIRImportJobResponseFilterSensitiveLog = (obj) => ({
245
- ...obj,
246
- });
247
- export const TagResourceRequestFilterSensitiveLog = (obj) => ({
248
- ...obj,
249
- });
250
- export const TagResourceResponseFilterSensitiveLog = (obj) => ({
251
- ...obj,
252
- });
253
- export const UntagResourceRequestFilterSensitiveLog = (obj) => ({
254
- ...obj,
255
- });
256
- export const UntagResourceResponseFilterSensitiveLog = (obj) => ({
257
- ...obj,
258
- });
158
+ export var ImportJobPropertiesFilterSensitiveLog = function (obj) { return (__assign(__assign(__assign({}, obj), (obj.InputDataConfig && { InputDataConfig: InputDataConfigFilterSensitiveLog(obj.InputDataConfig) })), (obj.JobOutputDataConfig && { JobOutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.JobOutputDataConfig) }))); };
159
+ export var DescribeFHIRImportJobResponseFilterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.ImportJobProperties && {
160
+ ImportJobProperties: ImportJobPropertiesFilterSensitiveLog(obj.ImportJobProperties),
161
+ }))); };
162
+ export var ListFHIRDatastoresRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
163
+ export var ListFHIRDatastoresResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
164
+ export var ListFHIRExportJobsRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
165
+ export var ListFHIRExportJobsResponseFilterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.ExportJobPropertiesList && {
166
+ ExportJobPropertiesList: obj.ExportJobPropertiesList.map(function (item) { return ExportJobPropertiesFilterSensitiveLog(item); }),
167
+ }))); };
168
+ export var ListFHIRImportJobsRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
169
+ export var ListFHIRImportJobsResponseFilterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.ImportJobPropertiesList && {
170
+ ImportJobPropertiesList: obj.ImportJobPropertiesList.map(function (item) { return ImportJobPropertiesFilterSensitiveLog(item); }),
171
+ }))); };
172
+ export var ListTagsForResourceRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
173
+ export var ListTagsForResourceResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
174
+ export var StartFHIRExportJobRequestFilterSensitiveLog = function (obj) { return (__assign(__assign({}, obj), (obj.OutputDataConfig && { OutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.OutputDataConfig) }))); };
175
+ export var StartFHIRExportJobResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
176
+ export var StartFHIRImportJobRequestFilterSensitiveLog = function (obj) { return (__assign(__assign(__assign({}, obj), (obj.InputDataConfig && { InputDataConfig: InputDataConfigFilterSensitiveLog(obj.InputDataConfig) })), (obj.JobOutputDataConfig && { JobOutputDataConfig: OutputDataConfigFilterSensitiveLog(obj.JobOutputDataConfig) }))); };
177
+ export var StartFHIRImportJobResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
178
+ export var TagResourceRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
179
+ export var TagResourceResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
180
+ export var UntagResourceRequestFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
181
+ export var UntagResourceResponseFilterSensitiveLog = function (obj) { return (__assign({}, obj)); };
@@ -1,32 +1,75 @@
1
+ import { __asyncGenerator, __await, __awaiter, __generator, __read, __spreadArray } from "tslib";
1
2
  import { ListFHIRDatastoresCommand, } from "../commands/ListFHIRDatastoresCommand";
2
3
  import { HealthLake } from "../HealthLake";
3
4
  import { HealthLakeClient } from "../HealthLakeClient";
4
- const makePagedClientRequest = async (client, input, ...args) => {
5
- return await client.send(new ListFHIRDatastoresCommand(input), ...args);
5
+ var makePagedClientRequest = function (client, input) {
6
+ var args = [];
7
+ for (var _i = 2; _i < arguments.length; _i++) {
8
+ args[_i - 2] = arguments[_i];
9
+ }
10
+ return __awaiter(void 0, void 0, void 0, function () {
11
+ return __generator(this, function (_a) {
12
+ switch (_a.label) {
13
+ case 0: return [4, client.send.apply(client, __spreadArray([new ListFHIRDatastoresCommand(input)], __read(args), false))];
14
+ case 1: return [2, _a.sent()];
15
+ }
16
+ });
17
+ });
6
18
  };
7
- const makePagedRequest = async (client, input, ...args) => {
8
- return await client.listFHIRDatastores(input, ...args);
19
+ var makePagedRequest = function (client, input) {
20
+ var args = [];
21
+ for (var _i = 2; _i < arguments.length; _i++) {
22
+ args[_i - 2] = arguments[_i];
23
+ }
24
+ return __awaiter(void 0, void 0, void 0, function () {
25
+ return __generator(this, function (_a) {
26
+ switch (_a.label) {
27
+ case 0: return [4, client.listFHIRDatastores.apply(client, __spreadArray([input], __read(args), false))];
28
+ case 1: return [2, _a.sent()];
29
+ }
30
+ });
31
+ });
9
32
  };
10
- export async function* paginateListFHIRDatastores(config, input, ...additionalArguments) {
11
- let token = config.startingToken || undefined;
12
- let hasNext = true;
13
- let page;
14
- while (hasNext) {
15
- input.NextToken = token;
16
- input["MaxResults"] = config.pageSize;
17
- if (config.client instanceof HealthLake) {
18
- page = await makePagedRequest(config.client, input, ...additionalArguments);
19
- }
20
- else if (config.client instanceof HealthLakeClient) {
21
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
22
- }
23
- else {
24
- throw new Error("Invalid client, expected HealthLake | HealthLakeClient");
25
- }
26
- yield page;
27
- const prevToken = token;
28
- token = page.NextToken;
29
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
33
+ export function paginateListFHIRDatastores(config, input) {
34
+ var additionalArguments = [];
35
+ for (var _i = 2; _i < arguments.length; _i++) {
36
+ additionalArguments[_i - 2] = arguments[_i];
30
37
  }
31
- return undefined;
38
+ return __asyncGenerator(this, arguments, function paginateListFHIRDatastores_1() {
39
+ var token, hasNext, page, prevToken;
40
+ return __generator(this, function (_a) {
41
+ switch (_a.label) {
42
+ case 0:
43
+ token = config.startingToken || undefined;
44
+ hasNext = true;
45
+ _a.label = 1;
46
+ case 1:
47
+ if (!hasNext) return [3, 9];
48
+ input.NextToken = token;
49
+ input["MaxResults"] = config.pageSize;
50
+ if (!(config.client instanceof HealthLake)) return [3, 3];
51
+ return [4, __await(makePagedRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
52
+ case 2:
53
+ page = _a.sent();
54
+ return [3, 6];
55
+ case 3:
56
+ if (!(config.client instanceof HealthLakeClient)) return [3, 5];
57
+ return [4, __await(makePagedClientRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
58
+ case 4:
59
+ page = _a.sent();
60
+ return [3, 6];
61
+ case 5: throw new Error("Invalid client, expected HealthLake | HealthLakeClient");
62
+ case 6: return [4, __await(page)];
63
+ case 7: return [4, _a.sent()];
64
+ case 8:
65
+ _a.sent();
66
+ prevToken = token;
67
+ token = page.NextToken;
68
+ hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
69
+ return [3, 1];
70
+ case 9: return [4, __await(undefined)];
71
+ case 10: return [2, _a.sent()];
72
+ }
73
+ });
74
+ });
32
75
  }
@@ -1,32 +1,75 @@
1
+ import { __asyncGenerator, __await, __awaiter, __generator, __read, __spreadArray } from "tslib";
1
2
  import { ListFHIRExportJobsCommand, } from "../commands/ListFHIRExportJobsCommand";
2
3
  import { HealthLake } from "../HealthLake";
3
4
  import { HealthLakeClient } from "../HealthLakeClient";
4
- const makePagedClientRequest = async (client, input, ...args) => {
5
- return await client.send(new ListFHIRExportJobsCommand(input), ...args);
5
+ var makePagedClientRequest = function (client, input) {
6
+ var args = [];
7
+ for (var _i = 2; _i < arguments.length; _i++) {
8
+ args[_i - 2] = arguments[_i];
9
+ }
10
+ return __awaiter(void 0, void 0, void 0, function () {
11
+ return __generator(this, function (_a) {
12
+ switch (_a.label) {
13
+ case 0: return [4, client.send.apply(client, __spreadArray([new ListFHIRExportJobsCommand(input)], __read(args), false))];
14
+ case 1: return [2, _a.sent()];
15
+ }
16
+ });
17
+ });
6
18
  };
7
- const makePagedRequest = async (client, input, ...args) => {
8
- return await client.listFHIRExportJobs(input, ...args);
19
+ var makePagedRequest = function (client, input) {
20
+ var args = [];
21
+ for (var _i = 2; _i < arguments.length; _i++) {
22
+ args[_i - 2] = arguments[_i];
23
+ }
24
+ return __awaiter(void 0, void 0, void 0, function () {
25
+ return __generator(this, function (_a) {
26
+ switch (_a.label) {
27
+ case 0: return [4, client.listFHIRExportJobs.apply(client, __spreadArray([input], __read(args), false))];
28
+ case 1: return [2, _a.sent()];
29
+ }
30
+ });
31
+ });
9
32
  };
10
- export async function* paginateListFHIRExportJobs(config, input, ...additionalArguments) {
11
- let token = config.startingToken || undefined;
12
- let hasNext = true;
13
- let page;
14
- while (hasNext) {
15
- input.NextToken = token;
16
- input["MaxResults"] = config.pageSize;
17
- if (config.client instanceof HealthLake) {
18
- page = await makePagedRequest(config.client, input, ...additionalArguments);
19
- }
20
- else if (config.client instanceof HealthLakeClient) {
21
- page = await makePagedClientRequest(config.client, input, ...additionalArguments);
22
- }
23
- else {
24
- throw new Error("Invalid client, expected HealthLake | HealthLakeClient");
25
- }
26
- yield page;
27
- const prevToken = token;
28
- token = page.NextToken;
29
- hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
33
+ export function paginateListFHIRExportJobs(config, input) {
34
+ var additionalArguments = [];
35
+ for (var _i = 2; _i < arguments.length; _i++) {
36
+ additionalArguments[_i - 2] = arguments[_i];
30
37
  }
31
- return undefined;
38
+ return __asyncGenerator(this, arguments, function paginateListFHIRExportJobs_1() {
39
+ var token, hasNext, page, prevToken;
40
+ return __generator(this, function (_a) {
41
+ switch (_a.label) {
42
+ case 0:
43
+ token = config.startingToken || undefined;
44
+ hasNext = true;
45
+ _a.label = 1;
46
+ case 1:
47
+ if (!hasNext) return [3, 9];
48
+ input.NextToken = token;
49
+ input["MaxResults"] = config.pageSize;
50
+ if (!(config.client instanceof HealthLake)) return [3, 3];
51
+ return [4, __await(makePagedRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
52
+ case 2:
53
+ page = _a.sent();
54
+ return [3, 6];
55
+ case 3:
56
+ if (!(config.client instanceof HealthLakeClient)) return [3, 5];
57
+ return [4, __await(makePagedClientRequest.apply(void 0, __spreadArray([config.client, input], __read(additionalArguments), false)))];
58
+ case 4:
59
+ page = _a.sent();
60
+ return [3, 6];
61
+ case 5: throw new Error("Invalid client, expected HealthLake | HealthLakeClient");
62
+ case 6: return [4, __await(page)];
63
+ case 7: return [4, _a.sent()];
64
+ case 8:
65
+ _a.sent();
66
+ prevToken = token;
67
+ token = page.NextToken;
68
+ hasNext = !!(token && (!config.stopOnSameToken || token !== prevToken));
69
+ return [3, 1];
70
+ case 9: return [4, __await(undefined)];
71
+ case 10: return [2, _a.sent()];
72
+ }
73
+ });
74
+ });
32
75
  }