Class: AWSCDK::Lightsail::CfnInstance::NetworkingProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
lightsail/cfn_instance.rb

Overview

Networking is a property of the AWS::Lightsail::Instance resource. It describes the public ports and the monthly amount of data transfer allocated for the instance.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(ports:, monthly_transfer: nil) ⇒ NetworkingProperty

Returns a new instance of NetworkingProperty.

Parameters:



1113
1114
1115
1116
1117
1118
# File 'lightsail/cfn_instance.rb', line 1113

def initialize(ports:, monthly_transfer: nil)
  @ports = ports
  Jsii::Type.check_type(@ports, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfbGlnaHRzYWlsLkNmbkluc3RhbmNlLlBvcnRQcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "ports")
  @monthly_transfer = monthly_transfer.is_a?(Hash) ? ::AWSCDK::Lightsail::CfnInstance::MonthlyTransferProperty.new(**monthly_transfer.transform_keys(&:to_sym)) : monthly_transfer
  Jsii::Type.check_type(@monthly_transfer, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19saWdodHNhaWwuQ2ZuSW5zdGFuY2UuTW9udGhseVRyYW5zZmVyUHJvcGVydHkifV19fQ==")), "monthlyTransfer") unless @monthly_transfer.nil?
end

Instance Attribute Details

#monthly_transferAWSCDK::IResolvable, ... (readonly)

The monthly amount of data transfer, in GB, allocated for the instance.



1129
1130
1131
# File 'lightsail/cfn_instance.rb', line 1129

def monthly_transfer
  @monthly_transfer
end

Class Method Details

.jsii_propertiesObject



1131
1132
1133
1134
1135
1136
# File 'lightsail/cfn_instance.rb', line 1131

def self.jsii_properties
  {
    :ports => "ports",
    :monthly_transfer => "monthlyTransfer",
  }
end

Instance Method Details

#to_jsiiObject



1138
1139
1140
1141
1142
1143
1144
1145
# File 'lightsail/cfn_instance.rb', line 1138

def to_jsii
  result = {}
  result.merge!({
    "ports" => @ports,
    "monthlyTransfer" => @monthly_transfer,
  })
  result.compact
end