text: "use strict";
  Object.defineProperty(exports, "__esModule", { value: true });
  exports.RegisterTypeCommand = void 0;
  const models_0_1 = require("../models/models_0");
  const Aws_query_1 = require("../protocols/Aws_query");
  const middleware_serde_1 = require("@aws-sdk/middleware-serde");
  const smithy_client_1 = require("@aws-sdk/smithy-client");
  /**
   * <p>Registers an extension with the CloudFormation service. Registering an extension makes it available for use in CloudFormation templates in your AWS account, and includes:</p>
   *          <ul>
   *             <li>
   *                <p>Validating the extension schema</p>
   *             </li>
   *             <li>
   *                <p>Determining which handlers, if any, have been specified for the extension</p>
   *             </li>
   *             <li>
   *                <p>Making the extension available for use in your account</p>
   *             </li>
   *          </ul>
   *          <p>For more information on how to develop extensions and ready them for registeration, see <a href="https://docs.aws.amazon.com/cloudformation-cli/latest/userguide/resource-types.html">Creating Resource Providers</a> in the <i>CloudFormation CLI User Guide</i>.</p>
   *          <p>You can have a maximum of 50 resource extension versions registered at a time. This maximum is per account and per region. Use <a href="AWSCloudFormation/latest/APIReference/API_DeregisterType.html">DeregisterType</a> to deregister specific extension versions if necessary.</p>
   *          <p>Once you have initiated a registration request using <code>
   *                <a>RegisterType</a>
   *             </code>, you can use <code>
   *                <a>DescribeTypeRegistration</a>
   *             </code> to monitor the progress of the registration request.</p>
   * @example
   * Use a bare-bones client and the command you need to make an API call.
   * ```javascript
   * import { CloudFormationClient, RegisterTypeCommand } from "@aws-sdk/client-cloudformation"; // ES Modules import
   * // const { CloudFormationClient, RegisterTypeCommand } = require("@aws-sdk/client-cloudformation"); // CommonJS import
   * const client = new CloudFormationClient(config);
   * const command = new RegisterTypeCommand(input);
   * const response = await client.send(command);
   * ```
   *
   * @see {@link RegisterTypeCommandInput} for command's `input` shape.
   * @see {@link RegisterTypeCommandOutput} for command's `response` shape.
   * @see {@link CloudFormationClientResolvedConfig | config} for command's `input` shape.
   *
   */
  class RegisterTypeCommand extends smithy_client_1.Command {
      // Start section: command_properties
      // End section: command_properties
      constructor(input) {
          // Start section: command_constructor
          super();
          this.input = input;
          // End section: command_constructor
      }
      /**
       * @internal
       */
      resolveMiddleware(clientStack, configuration, options) {
          this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize));
          const stack = clientStack.concat(this.middlewareStack);
          const { logger } = configuration;
          const clientName = "CloudFormationClient";
          const commandName = "RegisterTypeCommand";
          const handlerExecutionContext = {
              logger,
              clientName,
              commandName,
              inputFilterSensitiveLog: models_0_1.RegisterTypeInput.filterSensitiveLog,
              outputFilterSensitiveLog: models_0_1.RegisterTypeOutput.filterSensitiveLog,
          };
          const { requestHandler } = configuration;
          return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext);
      }
      serialize(input, context) {
          return Aws_query_1.serializeAws_queryRegisterTypeCommand(input, context);
      }
      deserialize(output, context) {
          return Aws_query_1.deserializeAws_queryRegisterTypeCommand(output, context);
      }
  }
  exports.RegisterTypeCommand = RegisterTypeCommand;
  //# sourceMappingURL=RegisterTypeCommand.js.map