Class: AWSCDK::APIGateway::DeploymentProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::APIGateway::DeploymentProps
- Defined in:
- api_gateway/deployment_props.rb
Instance Attribute Summary collapse
-
#api ⇒ AWSCDK::APIGateway::IRestAPI
readonly
The Rest API to deploy.
-
#description ⇒ String?
readonly
A description of the purpose of the API Gateway deployment.
-
#retain_deployments ⇒ Boolean?
readonly
When an API Gateway model is updated, a new deployment will automatically be created.
-
#stage_name ⇒ String?
readonly
The name of the stage the API Gateway deployment deploys to.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(api:, description: nil, retain_deployments: nil, stage_name: nil) ⇒ DeploymentProps
constructor
A new instance of DeploymentProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(api:, description: nil, retain_deployments: nil, stage_name: nil) ⇒ DeploymentProps
Returns a new instance of DeploymentProps.
10 11 12 13 14 15 16 17 18 19 |
# File 'api_gateway/deployment_props.rb', line 10 def initialize(api:, description: nil, retain_deployments: nil, stage_name: nil) @api = api Jsii::Type.check_type(@api, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheS5JUmVzdEFwaSJ9")), "api") @description = description Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil? @retain_deployments = retain_deployments Jsii::Type.check_type(@retain_deployments, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "retainDeployments") unless @retain_deployments.nil? @stage_name = stage_name Jsii::Type.check_type(@stage_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "stageName") unless @stage_name.nil? end |
Instance Attribute Details
#api ⇒ AWSCDK::APIGateway::IRestAPI (readonly)
The Rest API to deploy.
24 25 26 |
# File 'api_gateway/deployment_props.rb', line 24 def api @api end |
#description ⇒ String? (readonly)
Default: - No description.
A description of the purpose of the API Gateway deployment.
29 30 31 |
# File 'api_gateway/deployment_props.rb', line 29 def description @description end |
#retain_deployments ⇒ Boolean? (readonly)
Default: false
When an API Gateway model is updated, a new deployment will automatically be created.
If this is true, the old API Gateway Deployment resource will not be deleted. This will allow manually reverting back to a previous deployment in case for example
37 38 39 |
# File 'api_gateway/deployment_props.rb', line 37 def retain_deployments @retain_deployments end |
#stage_name ⇒ String? (readonly)
Default: - No stage name. If the stageName property is set but a stage with the corresponding name does not exist, a new stage resource will be created with the provided stage name.
The name of the stage the API Gateway deployment deploys to.
42 43 44 |
# File 'api_gateway/deployment_props.rb', line 42 def stage_name @stage_name end |
Class Method Details
.jsii_properties ⇒ Object
44 45 46 47 48 49 50 51 |
# File 'api_gateway/deployment_props.rb', line 44 def self.jsii_properties { :api => "api", :description => "description", :retain_deployments => "retainDeployments", :stage_name => "stageName", } end |
Instance Method Details
#to_jsii ⇒ Object
53 54 55 56 57 58 59 60 61 62 |
# File 'api_gateway/deployment_props.rb', line 53 def to_jsii result = {} result.merge!({ "api" => @api, "description" => @description, "retainDeployments" => @retain_deployments, "stageName" => @stage_name, }) result.compact end |