@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)", date="2022-05-20T22:20:03.622Z") public interface ModelProps extends ModelOptions
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.apigateway.*; Object default_; Object enum_; JsonSchema jsonSchema_; RestApi restApi; ModelProps modelProps = ModelProps.builder() .restApi(restApi) .schema(JsonSchema.builder() .additionalItems(List.of(jsonSchema_)) .additionalProperties(false) .allOf(List.of(jsonSchema_)) .anyOf(List.of(jsonSchema_)) .contains(jsonSchema_) .default(default_) .definitions(Map.of( "definitionsKey", jsonSchema_)) .dependencies(Map.of( "dependenciesKey", List.of("dependencies"))) .description("description") .enum(List.of(enum_)) .exclusiveMaximum(false) .exclusiveMinimum(false) .format("format") .id("id") .items(jsonSchema_) .maximum(123) .maxItems(123) .maxLength(123) .maxProperties(123) .minimum(123) .minItems(123) .minLength(123) .minProperties(123) .multipleOf(123) .not(jsonSchema_) .oneOf(List.of(jsonSchema_)) .pattern("pattern") .patternProperties(Map.of( "patternPropertiesKey", jsonSchema_)) .properties(Map.of( "propertiesKey", jsonSchema_)) .propertyNames(jsonSchema_) .ref("ref") .required(List.of("required")) .schema(JsonSchemaVersion.DRAFT4) .title("title") .type(JsonSchemaType.NULL) .uniqueItems(false) .build()) // the properties below are optional .contentType("contentType") .description("description") .modelName("modelName") .build();
Modifier and Type | Interface and Description |
---|---|
static class |
ModelProps.Builder
A builder for
ModelProps |
static class |
ModelProps.Jsii$Proxy
An implementation for
ModelProps |
Modifier and Type | Method and Description |
---|---|
static ModelProps.Builder |
builder() |
IRestApi |
getRestApi()
The rest API that this model is part of.
|
getContentType, getDescription, getModelName, getSchema
IRestApi getRestApi()
The reason we need the RestApi object itself and not just the ID is because the model is being tracked by the top-level RestApi object for the purpose of calculating it's hash to determine the ID of the deployment. This allows us to automatically update the deployment when the model of the REST API changes.
static ModelProps.Builder builder()
builder
in interface ModelOptions
ModelProps.Builder
of ModelProps