Class: AWSCDK::EC2::GatewayVPCEndpointOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::EC2::GatewayVPCEndpointOptions
- Defined in:
- ec2/gateway_vpc_endpoint_options.rb
Overview
Options to add a gateway endpoint to a VPC.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#service ⇒ AWSCDK::EC2::IGatewayVPCEndpointService
readonly
The service to use for this gateway VPC endpoint.
-
#subnets ⇒ Array<AWSCDK::EC2::SubnetSelection>?
readonly
Where to add endpoint routing.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(service:, subnets: nil) ⇒ GatewayVPCEndpointOptions
constructor
A new instance of GatewayVPCEndpointOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(service:, subnets: nil) ⇒ GatewayVPCEndpointOptions
Returns a new instance of GatewayVPCEndpointOptions.
9 10 11 12 13 14 |
# File 'ec2/gateway_vpc_endpoint_options.rb', line 9 def initialize(service:, subnets: nil) @service = service Jsii::Type.check_type(@service, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWMyLklHYXRld2F5VnBjRW5kcG9pbnRTZXJ2aWNlIn0=")), "service") @subnets = subnets.is_a?(Array) ? subnets.map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::EC2::SubnetSelection.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : subnets Jsii::Type.check_type(@subnets, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLmF3c19lYzIuU3VibmV0U2VsZWN0aW9uIn0sImtpbmQiOiJhcnJheSJ9fQ==")), "subnets") unless @subnets.nil? end |
Instance Attribute Details
#service ⇒ AWSCDK::EC2::IGatewayVPCEndpointService (readonly)
The service to use for this gateway VPC endpoint.
19 20 21 |
# File 'ec2/gateway_vpc_endpoint_options.rb', line 19 def service @service end |
#subnets ⇒ Array<AWSCDK::EC2::SubnetSelection>? (readonly)
Note:
Default: - All subnets in the VPC
Where to add endpoint routing.
By default, this endpoint will be routable from all subnets in the VPC. Specify a list of subnet selection objects here to be more specific.
38 39 40 |
# File 'ec2/gateway_vpc_endpoint_options.rb', line 38 def subnets @subnets end |
Class Method Details
.jsii_properties ⇒ Object
40 41 42 43 44 45 |
# File 'ec2/gateway_vpc_endpoint_options.rb', line 40 def self.jsii_properties { :service => "service", :subnets => "subnets", } end |
Instance Method Details
#to_jsii ⇒ Object
47 48 49 50 51 52 53 54 |
# File 'ec2/gateway_vpc_endpoint_options.rb', line 47 def to_jsii result = {} result.merge!({ "service" => @service, "subnets" => @subnets, }) result.compact end |