@aws-sdk/lib-dynamodb 3.131.0 → 3.142.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 +27 -0
- package/README.md +73 -0
- package/dist-cjs/baseCommand/DynamoDBDocumentClientCommand.js +28 -0
- package/dist-cjs/commands/BatchExecuteStatementCommand.js +8 -13
- package/dist-cjs/commands/BatchGetCommand.js +8 -13
- package/dist-cjs/commands/BatchWriteCommand.js +8 -13
- package/dist-cjs/commands/DeleteCommand.js +8 -13
- package/dist-cjs/commands/ExecuteStatementCommand.js +8 -13
- package/dist-cjs/commands/ExecuteTransactionCommand.js +8 -13
- package/dist-cjs/commands/GetCommand.js +8 -13
- package/dist-cjs/commands/PutCommand.js +8 -13
- package/dist-cjs/commands/QueryCommand.js +8 -13
- package/dist-cjs/commands/ScanCommand.js +8 -13
- package/dist-cjs/commands/TransactGetCommand.js +8 -13
- package/dist-cjs/commands/TransactWriteCommand.js +8 -13
- package/dist-cjs/commands/UpdateCommand.js +8 -13
- package/dist-es/baseCommand/DynamoDBDocumentClientCommand.js +45 -0
- package/dist-es/commands/BatchExecuteStatementCommand.js +11 -18
- package/dist-es/commands/BatchGetCommand.js +11 -18
- package/dist-es/commands/BatchWriteCommand.js +11 -18
- package/dist-es/commands/DeleteCommand.js +11 -18
- package/dist-es/commands/ExecuteStatementCommand.js +11 -18
- package/dist-es/commands/ExecuteTransactionCommand.js +11 -18
- package/dist-es/commands/GetCommand.js +11 -18
- package/dist-es/commands/PutCommand.js +11 -18
- package/dist-es/commands/QueryCommand.js +11 -18
- package/dist-es/commands/ScanCommand.js +11 -18
- package/dist-es/commands/TransactGetCommand.js +11 -18
- package/dist-es/commands/TransactWriteCommand.js +11 -18
- package/dist-es/commands/UpdateCommand.js +11 -18
- package/dist-types/baseCommand/DynamoDBDocumentClientCommand.d.ts +15 -0
- package/dist-types/commands/BatchExecuteStatementCommand.d.ts +17 -5
- package/dist-types/commands/BatchGetCommand.d.ts +26 -5
- package/dist-types/commands/BatchWriteCommand.d.ts +34 -5
- package/dist-types/commands/DeleteCommand.d.ts +25 -5
- package/dist-types/commands/ExecuteStatementCommand.d.ts +11 -5
- package/dist-types/commands/ExecuteTransactionCommand.d.ts +17 -5
- package/dist-types/commands/GetCommand.d.ts +11 -5
- package/dist-types/commands/PutCommand.d.ts +25 -5
- package/dist-types/commands/QueryCommand.d.ts +19 -5
- package/dist-types/commands/ScanCommand.d.ts +19 -5
- package/dist-types/commands/TransactGetCommand.d.ts +20 -5
- package/dist-types/commands/TransactWriteCommand.d.ts +22 -5
- package/dist-types/commands/UpdateCommand.d.ts +25 -5
- package/dist-types/ts3.4/baseCommand/DynamoDBDocumentClientCommand.d.ts +12 -0
- package/dist-types/ts3.4/commands/BatchExecuteStatementCommand.d.ts +17 -5
- package/dist-types/ts3.4/commands/BatchGetCommand.d.ts +26 -5
- package/dist-types/ts3.4/commands/BatchWriteCommand.d.ts +34 -5
- package/dist-types/ts3.4/commands/DeleteCommand.d.ts +25 -5
- package/dist-types/ts3.4/commands/ExecuteStatementCommand.d.ts +11 -5
- package/dist-types/ts3.4/commands/ExecuteTransactionCommand.d.ts +17 -5
- package/dist-types/ts3.4/commands/GetCommand.d.ts +11 -5
- package/dist-types/ts3.4/commands/PutCommand.d.ts +25 -5
- package/dist-types/ts3.4/commands/QueryCommand.d.ts +19 -5
- package/dist-types/ts3.4/commands/ScanCommand.d.ts +19 -5
- package/dist-types/ts3.4/commands/TransactGetCommand.d.ts +20 -5
- package/dist-types/ts3.4/commands/TransactWriteCommand.d.ts +22 -5
- package/dist-types/ts3.4/commands/UpdateCommand.d.ts +25 -5
- package/package.json +4 -4
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
|
+
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
3
|
+
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
4
|
+
var DynamoDBDocumentClientCommand = (function (_super) {
|
|
5
|
+
__extends(DynamoDBDocumentClientCommand, _super);
|
|
6
|
+
function DynamoDBDocumentClientCommand() {
|
|
7
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
8
|
+
}
|
|
9
|
+
DynamoDBDocumentClientCommand.prototype.addMarshallingMiddleware = function (configuration) {
|
|
10
|
+
var _this = this;
|
|
11
|
+
var _a = configuration.translateConfig || {}, marshallOptions = _a.marshallOptions, unmarshallOptions = _a.unmarshallOptions;
|
|
12
|
+
this.clientCommand.middlewareStack.add(function (next) {
|
|
13
|
+
return function (args) { return __awaiter(_this, void 0, void 0, function () {
|
|
14
|
+
return __generator(this, function (_a) {
|
|
15
|
+
args.input = marshallInput(this.input, this.inputKeyNodes, marshallOptions);
|
|
16
|
+
return [2, next(args)];
|
|
17
|
+
});
|
|
18
|
+
}); };
|
|
19
|
+
}, {
|
|
20
|
+
name: "DocumentMarshall",
|
|
21
|
+
step: "initialize",
|
|
22
|
+
override: true,
|
|
23
|
+
});
|
|
24
|
+
this.clientCommand.middlewareStack.add(function (next) {
|
|
25
|
+
return function (args) { return __awaiter(_this, void 0, void 0, function () {
|
|
26
|
+
var deserialized;
|
|
27
|
+
return __generator(this, function (_a) {
|
|
28
|
+
switch (_a.label) {
|
|
29
|
+
case 0: return [4, next(args)];
|
|
30
|
+
case 1:
|
|
31
|
+
deserialized = _a.sent();
|
|
32
|
+
deserialized.output = unmarshallOutput(deserialized.output, this.outputKeyNodes, unmarshallOptions);
|
|
33
|
+
return [2, deserialized];
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
}); };
|
|
37
|
+
}, {
|
|
38
|
+
name: "DocumentUnmarshall",
|
|
39
|
+
step: "deserialize",
|
|
40
|
+
override: true,
|
|
41
|
+
});
|
|
42
|
+
};
|
|
43
|
+
return DynamoDBDocumentClientCommand;
|
|
44
|
+
}($Command));
|
|
45
|
+
export { DynamoDBDocumentClientCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { BatchExecuteStatementCommand as __BatchExecuteStatementCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var BatchExecuteStatementCommand = (function (_super) {
|
|
6
5
|
__extends(BatchExecuteStatementCommand, _super);
|
|
7
6
|
function BatchExecuteStatementCommand(input) {
|
|
@@ -9,25 +8,19 @@ var BatchExecuteStatementCommand = (function (_super) {
|
|
|
9
8
|
_this.input = input;
|
|
10
9
|
_this.inputKeyNodes = [{ key: "Statements", children: [{ key: "Parameters" }] }];
|
|
11
10
|
_this.outputKeyNodes = [{ key: "Responses", children: [{ key: "Item" }] }];
|
|
11
|
+
_this.clientCommand = new __BatchExecuteStatementCommand(_this.input);
|
|
12
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
12
13
|
return _this;
|
|
13
14
|
}
|
|
14
15
|
BatchExecuteStatementCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
15
16
|
var _this = this;
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
var handler =
|
|
19
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
switch (_a.label) {
|
|
23
|
-
case 0: return [4, handler(command)];
|
|
24
|
-
case 1:
|
|
25
|
-
data = _a.sent();
|
|
26
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
}); };
|
|
17
|
+
this.addMarshallingMiddleware(configuration);
|
|
18
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
19
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
20
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
return [2, handler(this.clientCommand)];
|
|
22
|
+
}); }); };
|
|
30
23
|
};
|
|
31
24
|
return BatchExecuteStatementCommand;
|
|
32
|
-
}(
|
|
25
|
+
}(DynamoDBDocumentClientCommand));
|
|
33
26
|
export { BatchExecuteStatementCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { BatchGetItemCommand as __BatchGetItemCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var BatchGetCommand = (function (_super) {
|
|
6
5
|
__extends(BatchGetCommand, _super);
|
|
7
6
|
function BatchGetCommand(input) {
|
|
@@ -24,25 +23,19 @@ var BatchGetCommand = (function (_super) {
|
|
|
24
23
|
},
|
|
25
24
|
},
|
|
26
25
|
];
|
|
26
|
+
_this.clientCommand = new __BatchGetItemCommand(_this.input);
|
|
27
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
27
28
|
return _this;
|
|
28
29
|
}
|
|
29
30
|
BatchGetCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
30
31
|
var _this = this;
|
|
31
|
-
|
|
32
|
-
var
|
|
33
|
-
var handler =
|
|
34
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
switch (_a.label) {
|
|
38
|
-
case 0: return [4, handler(command)];
|
|
39
|
-
case 1:
|
|
40
|
-
data = _a.sent();
|
|
41
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
}); };
|
|
32
|
+
this.addMarshallingMiddleware(configuration);
|
|
33
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
34
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
35
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
36
|
+
return [2, handler(this.clientCommand)];
|
|
37
|
+
}); }); };
|
|
45
38
|
};
|
|
46
39
|
return BatchGetCommand;
|
|
47
|
-
}(
|
|
40
|
+
}(DynamoDBDocumentClientCommand));
|
|
48
41
|
export { BatchGetCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { BatchWriteItemCommand as __BatchWriteItemCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var BatchWriteCommand = (function (_super) {
|
|
6
5
|
__extends(BatchWriteCommand, _super);
|
|
7
6
|
function BatchWriteCommand(input) {
|
|
@@ -35,25 +34,19 @@ var BatchWriteCommand = (function (_super) {
|
|
|
35
34
|
},
|
|
36
35
|
},
|
|
37
36
|
];
|
|
37
|
+
_this.clientCommand = new __BatchWriteItemCommand(_this.input);
|
|
38
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
38
39
|
return _this;
|
|
39
40
|
}
|
|
40
41
|
BatchWriteCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
41
42
|
var _this = this;
|
|
42
|
-
|
|
43
|
-
var
|
|
44
|
-
var handler =
|
|
45
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
switch (_a.label) {
|
|
49
|
-
case 0: return [4, handler(command)];
|
|
50
|
-
case 1:
|
|
51
|
-
data = _a.sent();
|
|
52
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
53
|
-
}
|
|
54
|
-
});
|
|
55
|
-
}); };
|
|
43
|
+
this.addMarshallingMiddleware(configuration);
|
|
44
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
45
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
46
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
47
|
+
return [2, handler(this.clientCommand)];
|
|
48
|
+
}); }); };
|
|
56
49
|
};
|
|
57
50
|
return BatchWriteCommand;
|
|
58
|
-
}(
|
|
51
|
+
}(DynamoDBDocumentClientCommand));
|
|
59
52
|
export { BatchWriteCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { DeleteItemCommand as __DeleteItemCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var DeleteCommand = (function (_super) {
|
|
6
5
|
__extends(DeleteCommand, _super);
|
|
7
6
|
function DeleteCommand(input) {
|
|
@@ -21,25 +20,19 @@ var DeleteCommand = (function (_super) {
|
|
|
21
20
|
{ key: "Attributes" },
|
|
22
21
|
{ key: "ItemCollectionMetrics", children: [{ key: "ItemCollectionKey" }] },
|
|
23
22
|
];
|
|
23
|
+
_this.clientCommand = new __DeleteItemCommand(_this.input);
|
|
24
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
24
25
|
return _this;
|
|
25
26
|
}
|
|
26
27
|
DeleteCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
27
28
|
var _this = this;
|
|
28
|
-
|
|
29
|
-
var
|
|
30
|
-
var handler =
|
|
31
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
switch (_a.label) {
|
|
35
|
-
case 0: return [4, handler(command)];
|
|
36
|
-
case 1:
|
|
37
|
-
data = _a.sent();
|
|
38
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
39
|
-
}
|
|
40
|
-
});
|
|
41
|
-
}); };
|
|
29
|
+
this.addMarshallingMiddleware(configuration);
|
|
30
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
31
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
32
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
33
|
+
return [2, handler(this.clientCommand)];
|
|
34
|
+
}); }); };
|
|
42
35
|
};
|
|
43
36
|
return DeleteCommand;
|
|
44
|
-
}(
|
|
37
|
+
}(DynamoDBDocumentClientCommand));
|
|
45
38
|
export { DeleteCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { ExecuteStatementCommand as __ExecuteStatementCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var ExecuteStatementCommand = (function (_super) {
|
|
6
5
|
__extends(ExecuteStatementCommand, _super);
|
|
7
6
|
function ExecuteStatementCommand(input) {
|
|
@@ -9,25 +8,19 @@ var ExecuteStatementCommand = (function (_super) {
|
|
|
9
8
|
_this.input = input;
|
|
10
9
|
_this.inputKeyNodes = [{ key: "Parameters" }];
|
|
11
10
|
_this.outputKeyNodes = [{ key: "Items" }, { key: "LastEvaluatedKey" }];
|
|
11
|
+
_this.clientCommand = new __ExecuteStatementCommand(_this.input);
|
|
12
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
12
13
|
return _this;
|
|
13
14
|
}
|
|
14
15
|
ExecuteStatementCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
15
16
|
var _this = this;
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
var handler =
|
|
19
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
switch (_a.label) {
|
|
23
|
-
case 0: return [4, handler(command)];
|
|
24
|
-
case 1:
|
|
25
|
-
data = _a.sent();
|
|
26
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
}); };
|
|
17
|
+
this.addMarshallingMiddleware(configuration);
|
|
18
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
19
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
20
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
return [2, handler(this.clientCommand)];
|
|
22
|
+
}); }); };
|
|
30
23
|
};
|
|
31
24
|
return ExecuteStatementCommand;
|
|
32
|
-
}(
|
|
25
|
+
}(DynamoDBDocumentClientCommand));
|
|
33
26
|
export { ExecuteStatementCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { ExecuteTransactionCommand as __ExecuteTransactionCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var ExecuteTransactionCommand = (function (_super) {
|
|
6
5
|
__extends(ExecuteTransactionCommand, _super);
|
|
7
6
|
function ExecuteTransactionCommand(input) {
|
|
@@ -9,25 +8,19 @@ var ExecuteTransactionCommand = (function (_super) {
|
|
|
9
8
|
_this.input = input;
|
|
10
9
|
_this.inputKeyNodes = [{ key: "TransactStatements", children: [{ key: "Parameters" }] }];
|
|
11
10
|
_this.outputKeyNodes = [{ key: "Responses", children: [{ key: "Item" }] }];
|
|
11
|
+
_this.clientCommand = new __ExecuteTransactionCommand(_this.input);
|
|
12
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
12
13
|
return _this;
|
|
13
14
|
}
|
|
14
15
|
ExecuteTransactionCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
15
16
|
var _this = this;
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
var handler =
|
|
19
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
switch (_a.label) {
|
|
23
|
-
case 0: return [4, handler(command)];
|
|
24
|
-
case 1:
|
|
25
|
-
data = _a.sent();
|
|
26
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
}); };
|
|
17
|
+
this.addMarshallingMiddleware(configuration);
|
|
18
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
19
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
20
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
return [2, handler(this.clientCommand)];
|
|
22
|
+
}); }); };
|
|
30
23
|
};
|
|
31
24
|
return ExecuteTransactionCommand;
|
|
32
|
-
}(
|
|
25
|
+
}(DynamoDBDocumentClientCommand));
|
|
33
26
|
export { ExecuteTransactionCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { GetItemCommand as __GetItemCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var GetCommand = (function (_super) {
|
|
6
5
|
__extends(GetCommand, _super);
|
|
7
6
|
function GetCommand(input) {
|
|
@@ -9,25 +8,19 @@ var GetCommand = (function (_super) {
|
|
|
9
8
|
_this.input = input;
|
|
10
9
|
_this.inputKeyNodes = [{ key: "Key" }];
|
|
11
10
|
_this.outputKeyNodes = [{ key: "Item" }];
|
|
11
|
+
_this.clientCommand = new __GetItemCommand(_this.input);
|
|
12
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
12
13
|
return _this;
|
|
13
14
|
}
|
|
14
15
|
GetCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
15
16
|
var _this = this;
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
var handler =
|
|
19
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
switch (_a.label) {
|
|
23
|
-
case 0: return [4, handler(command)];
|
|
24
|
-
case 1:
|
|
25
|
-
data = _a.sent();
|
|
26
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
}); };
|
|
17
|
+
this.addMarshallingMiddleware(configuration);
|
|
18
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
19
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
20
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
return [2, handler(this.clientCommand)];
|
|
22
|
+
}); }); };
|
|
30
23
|
};
|
|
31
24
|
return GetCommand;
|
|
32
|
-
}(
|
|
25
|
+
}(DynamoDBDocumentClientCommand));
|
|
33
26
|
export { GetCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { PutItemCommand as __PutItemCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var PutCommand = (function (_super) {
|
|
6
5
|
__extends(PutCommand, _super);
|
|
7
6
|
function PutCommand(input) {
|
|
@@ -21,25 +20,19 @@ var PutCommand = (function (_super) {
|
|
|
21
20
|
{ key: "Attributes" },
|
|
22
21
|
{ key: "ItemCollectionMetrics", children: [{ key: "ItemCollectionKey" }] },
|
|
23
22
|
];
|
|
23
|
+
_this.clientCommand = new __PutItemCommand(_this.input);
|
|
24
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
24
25
|
return _this;
|
|
25
26
|
}
|
|
26
27
|
PutCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
27
28
|
var _this = this;
|
|
28
|
-
|
|
29
|
-
var
|
|
30
|
-
var handler =
|
|
31
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
switch (_a.label) {
|
|
35
|
-
case 0: return [4, handler(command)];
|
|
36
|
-
case 1:
|
|
37
|
-
data = _a.sent();
|
|
38
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
39
|
-
}
|
|
40
|
-
});
|
|
41
|
-
}); };
|
|
29
|
+
this.addMarshallingMiddleware(configuration);
|
|
30
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
31
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
32
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
33
|
+
return [2, handler(this.clientCommand)];
|
|
34
|
+
}); }); };
|
|
42
35
|
};
|
|
43
36
|
return PutCommand;
|
|
44
|
-
}(
|
|
37
|
+
}(DynamoDBDocumentClientCommand));
|
|
45
38
|
export { PutCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { QueryCommand as __QueryCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var QueryCommand = (function (_super) {
|
|
6
5
|
__extends(QueryCommand, _super);
|
|
7
6
|
function QueryCommand(input) {
|
|
@@ -24,25 +23,19 @@ var QueryCommand = (function (_super) {
|
|
|
24
23
|
{ key: "ExpressionAttributeValues" },
|
|
25
24
|
];
|
|
26
25
|
_this.outputKeyNodes = [{ key: "Items" }, { key: "LastEvaluatedKey" }];
|
|
26
|
+
_this.clientCommand = new __QueryCommand(_this.input);
|
|
27
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
27
28
|
return _this;
|
|
28
29
|
}
|
|
29
30
|
QueryCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
30
31
|
var _this = this;
|
|
31
|
-
|
|
32
|
-
var
|
|
33
|
-
var handler =
|
|
34
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
switch (_a.label) {
|
|
38
|
-
case 0: return [4, handler(command)];
|
|
39
|
-
case 1:
|
|
40
|
-
data = _a.sent();
|
|
41
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
42
|
-
}
|
|
43
|
-
});
|
|
44
|
-
}); };
|
|
32
|
+
this.addMarshallingMiddleware(configuration);
|
|
33
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
34
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
35
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
36
|
+
return [2, handler(this.clientCommand)];
|
|
37
|
+
}); }); };
|
|
45
38
|
};
|
|
46
39
|
return QueryCommand;
|
|
47
|
-
}(
|
|
40
|
+
}(DynamoDBDocumentClientCommand));
|
|
48
41
|
export { QueryCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { ScanCommand as __ScanCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var ScanCommand = (function (_super) {
|
|
6
5
|
__extends(ScanCommand, _super);
|
|
7
6
|
function ScanCommand(input) {
|
|
@@ -18,25 +17,19 @@ var ScanCommand = (function (_super) {
|
|
|
18
17
|
{ key: "ExpressionAttributeValues" },
|
|
19
18
|
];
|
|
20
19
|
_this.outputKeyNodes = [{ key: "Items" }, { key: "LastEvaluatedKey" }];
|
|
20
|
+
_this.clientCommand = new __ScanCommand(_this.input);
|
|
21
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
21
22
|
return _this;
|
|
22
23
|
}
|
|
23
24
|
ScanCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
24
25
|
var _this = this;
|
|
25
|
-
|
|
26
|
-
var
|
|
27
|
-
var handler =
|
|
28
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
switch (_a.label) {
|
|
32
|
-
case 0: return [4, handler(command)];
|
|
33
|
-
case 1:
|
|
34
|
-
data = _a.sent();
|
|
35
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
}); };
|
|
26
|
+
this.addMarshallingMiddleware(configuration);
|
|
27
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
28
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
29
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
30
|
+
return [2, handler(this.clientCommand)];
|
|
31
|
+
}); }); };
|
|
39
32
|
};
|
|
40
33
|
return ScanCommand;
|
|
41
|
-
}(
|
|
34
|
+
}(DynamoDBDocumentClientCommand));
|
|
42
35
|
export { ScanCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { TransactGetItemsCommand as __TransactGetItemsCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var TransactGetCommand = (function (_super) {
|
|
6
5
|
__extends(TransactGetCommand, _super);
|
|
7
6
|
function TransactGetCommand(input) {
|
|
@@ -9,25 +8,19 @@ var TransactGetCommand = (function (_super) {
|
|
|
9
8
|
_this.input = input;
|
|
10
9
|
_this.inputKeyNodes = [{ key: "TransactItems", children: [{ key: "Get", children: [{ key: "Key" }] }] }];
|
|
11
10
|
_this.outputKeyNodes = [{ key: "Responses", children: [{ key: "Item" }] }];
|
|
11
|
+
_this.clientCommand = new __TransactGetItemsCommand(_this.input);
|
|
12
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
12
13
|
return _this;
|
|
13
14
|
}
|
|
14
15
|
TransactGetCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
15
16
|
var _this = this;
|
|
16
|
-
|
|
17
|
-
var
|
|
18
|
-
var handler =
|
|
19
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
switch (_a.label) {
|
|
23
|
-
case 0: return [4, handler(command)];
|
|
24
|
-
case 1:
|
|
25
|
-
data = _a.sent();
|
|
26
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
}); };
|
|
17
|
+
this.addMarshallingMiddleware(configuration);
|
|
18
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
19
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
20
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
21
|
+
return [2, handler(this.clientCommand)];
|
|
22
|
+
}); }); };
|
|
30
23
|
};
|
|
31
24
|
return TransactGetCommand;
|
|
32
|
-
}(
|
|
25
|
+
}(DynamoDBDocumentClientCommand));
|
|
33
26
|
export { TransactGetCommand };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { __awaiter, __extends, __generator } from "tslib";
|
|
2
2
|
import { TransactWriteItemsCommand as __TransactWriteItemsCommand, } from "@aws-sdk/client-dynamodb";
|
|
3
|
-
import {
|
|
4
|
-
import { marshallInput, unmarshallOutput } from "../commands/utils";
|
|
3
|
+
import { DynamoDBDocumentClientCommand } from "../baseCommand/DynamoDBDocumentClientCommand";
|
|
5
4
|
var TransactWriteCommand = (function (_super) {
|
|
6
5
|
__extends(TransactWriteCommand, _super);
|
|
7
6
|
function TransactWriteCommand(input) {
|
|
@@ -26,25 +25,19 @@ var TransactWriteCommand = (function (_super) {
|
|
|
26
25
|
},
|
|
27
26
|
},
|
|
28
27
|
];
|
|
28
|
+
_this.clientCommand = new __TransactWriteItemsCommand(_this.input);
|
|
29
|
+
_this.middlewareStack = _this.clientCommand.middlewareStack;
|
|
29
30
|
return _this;
|
|
30
31
|
}
|
|
31
32
|
TransactWriteCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
|
|
32
33
|
var _this = this;
|
|
33
|
-
|
|
34
|
-
var
|
|
35
|
-
var handler =
|
|
36
|
-
return function () { return __awaiter(_this, void 0, void 0, function () {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
switch (_a.label) {
|
|
40
|
-
case 0: return [4, handler(command)];
|
|
41
|
-
case 1:
|
|
42
|
-
data = _a.sent();
|
|
43
|
-
return [2, __assign(__assign({}, data), { output: unmarshallOutput(data.output, this.outputKeyNodes, unmarshallOptions) })];
|
|
44
|
-
}
|
|
45
|
-
});
|
|
46
|
-
}); };
|
|
34
|
+
this.addMarshallingMiddleware(configuration);
|
|
35
|
+
var stack = clientStack.concat(this.middlewareStack);
|
|
36
|
+
var handler = this.clientCommand.resolveMiddleware(stack, configuration, options);
|
|
37
|
+
return function () { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
|
|
38
|
+
return [2, handler(this.clientCommand)];
|
|
39
|
+
}); }); };
|
|
47
40
|
};
|
|
48
41
|
return TransactWriteCommand;
|
|
49
|
-
}(
|
|
42
|
+
}(DynamoDBDocumentClientCommand));
|
|
50
43
|
export { TransactWriteCommand };
|