Class: AWSCDK::Route53::CfnRecordSet::GeoLocationProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
route53/cfn_record_set.rb

Overview

A complex type that contains information about a geographic location.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(continent_code: nil, country_code: nil, subdivision_code: nil) ⇒ GeoLocationProperty

Returns a new instance of GeoLocationProperty.

Parameters:

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

    For geolocation resource record sets, a two-letter abbreviation that identifies a continent. Route 53 supports the following continent codes:.

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

    For geolocation resource record sets, the two-letter code for a country.

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

    For geolocation resource record sets, the two-letter code for a state of the United States.



961
962
963
964
965
966
967
968
# File 'route53/cfn_record_set.rb', line 961

def initialize(continent_code: nil, country_code: nil, subdivision_code: nil)
  @continent_code = continent_code
  Jsii::Type.check_type(@continent_code, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "continentCode") unless @continent_code.nil?
  @country_code = country_code
  Jsii::Type.check_type(@country_code, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "countryCode") unless @country_code.nil?
  @subdivision_code = subdivision_code
  Jsii::Type.check_type(@subdivision_code, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "subdivisionCode") unless @subdivision_code.nil?
end

Instance Attribute Details

#continent_codeString? (readonly)

For geolocation resource record sets, a two-letter abbreviation that identifies a continent. Route 53 supports the following continent codes:.

  • AF : Africa
  • AN : Antarctica
  • AS : Asia
  • EU : Europe
  • OC : Oceania
  • NA : North America
  • SA : South America

Constraint: Specifying ContinentCode with either CountryCode or SubdivisionCode returns an InvalidInput error.



984
985
986
# File 'route53/cfn_record_set.rb', line 984

def continent_code
  @continent_code
end

#country_codeString? (readonly)

For geolocation resource record sets, the two-letter code for a country.

Route 53 uses the two-letter country codes that are specified in ISO standard 3166-1 alpha-2 .



991
992
993
# File 'route53/cfn_record_set.rb', line 991

def country_code
  @country_code
end

#subdivision_codeString? (readonly)

For geolocation resource record sets, the two-letter code for a state of the United States.

Route 53 doesn't support any other values for SubdivisionCode . For a list of state abbreviations, see Appendix B: Two–Letter State and Possession Abbreviations on the United States Postal Service website.

If you specify subdivisioncode , you must also specify US for CountryCode .



1000
1001
1002
# File 'route53/cfn_record_set.rb', line 1000

def subdivision_code
  @subdivision_code
end

Class Method Details

.jsii_propertiesObject



1002
1003
1004
1005
1006
1007
1008
# File 'route53/cfn_record_set.rb', line 1002

def self.jsii_properties
  {
    :continent_code => "continentCode",
    :country_code => "countryCode",
    :subdivision_code => "subdivisionCode",
  }
end

Instance Method Details

#to_jsiiObject



1010
1011
1012
1013
1014
1015
1016
1017
1018
# File 'route53/cfn_record_set.rb', line 1010

def to_jsii
  result = {}
  result.merge!({
    "continentCode" => @continent_code,
    "countryCode" => @country_code,
    "subdivisionCode" => @subdivision_code,
  })
  result.compact
end