Class: AWSCDK::AppMesh::CfnVirtualGateway::VirtualGatewayPortMappingProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
app_mesh/cfn_virtual_gateway.rb

Overview

An object that represents a port mapping.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(port:, protocol:) ⇒ VirtualGatewayPortMappingProperty

Returns a new instance of VirtualGatewayPortMappingProperty.

Parameters:

  • port (Numeric)

    The port used for the port mapping.

  • protocol (String)

    The protocol used for the port mapping.



1703
1704
1705
1706
1707
1708
# File 'app_mesh/cfn_virtual_gateway.rb', line 1703

def initialize(port:, protocol:)
  @port = port
  Jsii::Type.check_type(@port, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "port")
  @protocol = protocol
  Jsii::Type.check_type(@protocol, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "protocol")
end

Instance Attribute Details

#portNumeric (readonly)

The port used for the port mapping.

Specify one protocol.



1716
1717
1718
# File 'app_mesh/cfn_virtual_gateway.rb', line 1716

def port
  @port
end

#protocolString (readonly)

The protocol used for the port mapping.



1721
1722
1723
# File 'app_mesh/cfn_virtual_gateway.rb', line 1721

def protocol
  @protocol
end

Class Method Details

.jsii_propertiesObject



1723
1724
1725
1726
1727
1728
# File 'app_mesh/cfn_virtual_gateway.rb', line 1723

def self.jsii_properties
  {
    :port => "port",
    :protocol => "protocol",
  }
end

Instance Method Details

#to_jsiiObject



1730
1731
1732
1733
1734
1735
1736
1737
# File 'app_mesh/cfn_virtual_gateway.rb', line 1730

def to_jsii
  result = {}
  result.merge!({
    "port" => @port,
    "protocol" => @protocol,
  })
  result.compact
end