UNPKG

@softchef/cdk-iot-device-management

Version:

IoT device management is composed of things, thing types, thing groups, jobs, files API services. The constructs can be used independently, that are based on full-managed service to create an API Gateway & Lambda function.

44 lines (43 loc) 2.26 kB
import { __extends } from "tslib"; import { getApplyMd5BodyChecksumPlugin } from "@aws-sdk/middleware-apply-body-checksum"; import { getBucketEndpointPlugin } from "@aws-sdk/middleware-bucket-endpoint"; import { getSerdePlugin } from "@aws-sdk/middleware-serde"; import { Command as $Command } from "@aws-sdk/smithy-client"; import { PutBucketPolicyRequest } from "../models/models_0"; import { deserializeAws_restXmlPutBucketPolicyCommand, serializeAws_restXmlPutBucketPolicyCommand, } from "../protocols/Aws_restXml"; var PutBucketPolicyCommand = (function (_super) { __extends(PutBucketPolicyCommand, _super); function PutBucketPolicyCommand(input) { var _this = _super.call(this) || this; _this.input = input; return _this; } PutBucketPolicyCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) { this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); this.middlewareStack.use(getBucketEndpointPlugin(configuration)); this.middlewareStack.use(getApplyMd5BodyChecksumPlugin(configuration)); var stack = clientStack.concat(this.middlewareStack); var logger = configuration.logger; var clientName = "S3Client"; var commandName = "PutBucketPolicyCommand"; var handlerExecutionContext = { logger: logger, clientName: clientName, commandName: commandName, inputFilterSensitiveLog: PutBucketPolicyRequest.filterSensitiveLog, outputFilterSensitiveLog: function (output) { return output; }, }; var requestHandler = configuration.requestHandler; return stack.resolve(function (request) { return requestHandler.handle(request.request, options || {}); }, handlerExecutionContext); }; PutBucketPolicyCommand.prototype.serialize = function (input, context) { return serializeAws_restXmlPutBucketPolicyCommand(input, context); }; PutBucketPolicyCommand.prototype.deserialize = function (output, context) { return deserializeAws_restXmlPutBucketPolicyCommand(output, context); }; return PutBucketPolicyCommand; }($Command)); export { PutBucketPolicyCommand };