aws-sdk 2.948.0 → 2.949.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/CHANGELOG.md +8 -1
- package/README.md +1 -1
- package/apis/emr-containers-2020-10-01.min.json +25 -23
- package/apis/health-2016-08-04.min.json +29 -29
- package/apis/location-2020-11-19.min.json +205 -0
- package/apis/robomaker-2018-06-29.min.json +6 -3
- package/clients/directconnect.d.ts +11 -8
- package/clients/emrcontainers.d.ts +12 -2
- package/clients/health.d.ts +3 -2
- package/clients/imagebuilder.d.ts +27 -27
- package/clients/location.d.ts +227 -35
- package/clients/robomaker.d.ts +12 -0
- package/dist/aws-sdk-core-react-native.js +6 -1
- package/dist/aws-sdk-react-native.js +10 -5
- package/dist/aws-sdk.js +213 -3
- package/dist/aws-sdk.min.js +36 -36
- package/lib/core.d.ts +1 -0
- package/lib/core.js +1 -1
- package/lib/json/builder.js +3 -0
- package/lib/json/parser.js +1 -0
- package/lib/model/index.d.ts +4 -0
- package/lib/model/shape.js +1 -0
- package/package.json +1 -1
- package/scripts/lib/ts-generator.js +16 -0
package/lib/core.d.ts
CHANGED
package/lib/core.js
CHANGED
package/lib/json/builder.js
CHANGED
package/lib/json/parser.js
CHANGED
package/lib/model/shape.js
CHANGED
|
@@ -166,6 +166,7 @@ function StructureShape(shape, options) {
|
|
|
166
166
|
property(this, 'memberNames', []);
|
|
167
167
|
property(this, 'required', []);
|
|
168
168
|
property(this, 'isRequired', function() { return false; });
|
|
169
|
+
property(this, 'isDocument', Boolean(shape.document));
|
|
169
170
|
}
|
|
170
171
|
|
|
171
172
|
if (shape.members) {
|
package/package.json
CHANGED
|
@@ -308,6 +308,9 @@ TSGenerator.prototype.generateTypingsFromShape = function generateTypingsFromSha
|
|
|
308
308
|
return code += tabs(tabCount) + 'export type ' + shapeKey + ' = EventStream<{' + events.join(',') + '}>;\n';
|
|
309
309
|
}
|
|
310
310
|
if (type === 'structure') {
|
|
311
|
+
if (shape.isDocument) {
|
|
312
|
+
return code += tabs(tabCount) + 'export type ' + shapeKey + ' = DocumentType;\n'
|
|
313
|
+
}
|
|
311
314
|
code += tabs(tabCount) + 'export interface ' + shapeKey + ' {\n';
|
|
312
315
|
var members = shape.members;
|
|
313
316
|
// cycle through members
|
|
@@ -508,6 +511,16 @@ TSGenerator.prototype.containsEventStreams = function containsEventStreams(model
|
|
|
508
511
|
return false;
|
|
509
512
|
};
|
|
510
513
|
|
|
514
|
+
TSGenerator.prototype.containsDocumentType = function containsDocumentType(model) {
|
|
515
|
+
var shapeNames = Object.keys(model.shapes);
|
|
516
|
+
for (var name of shapeNames) {
|
|
517
|
+
if (model.shapes[name].isDocument) {
|
|
518
|
+
return true;
|
|
519
|
+
}
|
|
520
|
+
}
|
|
521
|
+
return false;
|
|
522
|
+
};
|
|
523
|
+
|
|
511
524
|
/**
|
|
512
525
|
* Generates the typings for a service based on the serviceIdentifier.
|
|
513
526
|
*/
|
|
@@ -552,6 +565,9 @@ TSGenerator.prototype.processServiceModel = function processServiceModel(service
|
|
|
552
565
|
if (this.containsEventStreams(model)) {
|
|
553
566
|
code += 'import {EventStream} from \'../lib/event-stream/event-stream\';\n';
|
|
554
567
|
}
|
|
568
|
+
if (this.containsDocumentType(model)) {
|
|
569
|
+
code += 'import {DocumentType} from \'../lib/model\';\n';
|
|
570
|
+
}
|
|
555
571
|
// import custom namespaces
|
|
556
572
|
if (customNamespaces) {
|
|
557
573
|
code += customNamespaces.importCode;
|