import { __extends } from "tslib";
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
import { Command as $Command } from "@aws-sdk/smithy-client";
import { DeleteTransitGatewayRouteTableAnnouncementRequest, DeleteTransitGatewayRouteTableAnnouncementResult, } from "../models/models_2";
import { deserializeAws_ec2DeleteTransitGatewayRouteTableAnnouncementCommand, serializeAws_ec2DeleteTransitGatewayRouteTableAnnouncementCommand, } from "../protocols/Aws_ec2";
var DeleteTransitGatewayRouteTableAnnouncementCommand = (function (_super) {
    __extends(DeleteTransitGatewayRouteTableAnnouncementCommand, _super);
    function DeleteTransitGatewayRouteTableAnnouncementCommand(input) {
        var _this = _super.call(this) || this;
        _this.input = input;
        return _this;
    }
    DeleteTransitGatewayRouteTableAnnouncementCommand.prototype.resolveMiddleware = function (clientStack, configuration, options) {
        this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
        var stack = clientStack.concat(this.middlewareStack);
        var logger = configuration.logger;
        var clientName = "EC2Client";
        var commandName = "DeleteTransitGatewayRouteTableAnnouncementCommand";
        var handlerExecutionContext = {
            logger: logger,
            clientName: clientName,
            commandName: commandName,
            inputFilterSensitiveLog: DeleteTransitGatewayRouteTableAnnouncementRequest.filterSensitiveLog,
            outputFilterSensitiveLog: DeleteTransitGatewayRouteTableAnnouncementResult.filterSensitiveLog,
        };
        var requestHandler = configuration.requestHandler;
        return stack.resolve(function (request) {
            return requestHandler.handle(request.request, options || {});
        }, handlerExecutionContext);
    };
    DeleteTransitGatewayRouteTableAnnouncementCommand.prototype.serialize = function (input, context) {
        return serializeAws_ec2DeleteTransitGatewayRouteTableAnnouncementCommand(input, context);
    };
    DeleteTransitGatewayRouteTableAnnouncementCommand.prototype.deserialize = function (output, context) {
        return deserializeAws_ec2DeleteTransitGatewayRouteTableAnnouncementCommand(output, context);
    };
    return DeleteTransitGatewayRouteTableAnnouncementCommand;
}($Command));
export { DeleteTransitGatewayRouteTableAnnouncementCommand };
