Class CfnModelProps.Builder

java.lang.Object
software.amazon.awscdk.services.apigateway.CfnModelProps.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CfnModelProps>
Enclosing interface:
CfnModelProps

@Stability(Stable) public static final class CfnModelProps.Builder extends Object implements software.amazon.jsii.Builder<CfnModelProps>
A builder for CfnModelProps
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • restApiId

      @Stability(Stable) public CfnModelProps.Builder restApiId(String restApiId)
      Parameters:
      restApiId - The string identifier of the associated RestApi. This parameter is required.
      Returns:
      this
    • contentType

      @Stability(Stable) public CfnModelProps.Builder contentType(String contentType)
      Parameters:
      contentType - The content-type for the model.
      Returns:
      this
    • description

      @Stability(Stable) public CfnModelProps.Builder description(String description)
      Parameters:
      description - The description of the model.
      Returns:
      this
    • name

      @Stability(Stable) public CfnModelProps.Builder name(String name)
      Sets the value of CfnModelProps.getName()
      Parameters:
      name - A name for the model. If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the model name. For more information, see Name Type .

      If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.

      Returns:
      this
    • schema

      @Stability(Stable) public CfnModelProps.Builder schema(Object schema)
      Sets the value of CfnModelProps.getSchema()
      Parameters:
      schema - The schema for the model. For application/json models, this should be JSON schema draft 4 model. Do not include "* /" characters in the description of any properties because such "* /" characters may be interpreted as the closing marker for comments in some languages, such as Java or JavaScript, causing the installation of your API's SDK generated by API Gateway to fail.
      Returns:
      this
    • build

      @Stability(Stable) public CfnModelProps build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnModelProps>
      Returns:
      a new instance of CfnModelProps
      Throws:
      NullPointerException - if any required attribute was not provided