Class: AWSCDK::EC2::ClientVpnRouteOptions

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
ec2/client_vpn_route_options.rb

Overview

Options for a ClientVpnRoute.

Direct Known Subclasses

ClientVpnRouteProps

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cidr:, target:, description: nil) ⇒ ClientVpnRouteOptions

Returns a new instance of ClientVpnRouteOptions.

Parameters:

  • cidr (String)

    The IPv4 address range, in CIDR notation, of the route destination.

  • target (AWSCDK::EC2::ClientVpnRouteTarget)

    The target for the route.

  • description (String, nil) (defaults to: nil)

    A brief description of the authorization rule.



10
11
12
13
14
15
16
17
# File 'ec2/client_vpn_route_options.rb', line 10

def initialize(cidr:, target:, description: nil)
  @cidr = cidr
  Jsii::Type.check_type(@cidr, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "cidr")
  @target = target
  Jsii::Type.check_type(@target, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWMyLkNsaWVudFZwblJvdXRlVGFyZ2V0In0=")), "target")
  @description = description
  Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil?
end

Instance Attribute Details

#cidrString (readonly)

The IPv4 address range, in CIDR notation, of the route destination.

For example:

  • To add a route for Internet access, enter 0.0.0.0/0
  • To add a route for a peered VPC, enter the peered VPC's IPv4 CIDR range
  • To add a route for an on-premises network, enter the AWS Site-to-Site VPN connection's IPv4 CIDR range
  • To add a route for the local network, enter the client CIDR range

Returns:

  • (String)


30
31
32
# File 'ec2/client_vpn_route_options.rb', line 30

def cidr
  @cidr
end

#descriptionString? (readonly)

Note:

Default: - no description

A brief description of the authorization rule.

Returns:

  • (String, nil)


39
40
41
# File 'ec2/client_vpn_route_options.rb', line 39

def description
  @description
end

#targetAWSCDK::EC2::ClientVpnRouteTarget (readonly)

The target for the route.



34
35
36
# File 'ec2/client_vpn_route_options.rb', line 34

def target
  @target
end

Class Method Details

.jsii_propertiesObject



41
42
43
44
45
46
47
# File 'ec2/client_vpn_route_options.rb', line 41

def self.jsii_properties
  {
    :cidr => "cidr",
    :target => "target",
    :description => "description",
  }
end

Instance Method Details

#to_jsiiObject



49
50
51
52
53
54
55
56
57
# File 'ec2/client_vpn_route_options.rb', line 49

def to_jsii
  result = {}
  result.merge!({
    "cidr" => @cidr,
    "target" => @target,
    "description" => @description,
  })
  result.compact
end