Class: AWSCDK::NetworkManager::CfnSiteProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
network_manager/cfn_site_props.rb

Overview

Properties for defining a CfnSite.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(global_network_id:, description: nil, location: nil, tags: nil) ⇒ CfnSiteProps

Returns a new instance of CfnSiteProps.

Parameters:



13
14
15
16
17
18
19
20
21
22
# File 'network_manager/cfn_site_props.rb', line 13

def initialize(global_network_id:, description: nil, location: nil, tags: nil)
  @global_network_id = global_network_id
  Jsii::Type.check_type(@global_network_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "globalNetworkId")
  @description = description
  Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil?
  @location = location.is_a?(Hash) ? ::AWSCDK::NetworkManager::CfnSite::LocationProperty.new(**location.transform_keys(&:to_sym)) : location
  Jsii::Type.check_type(@location, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19uZXR3b3JrbWFuYWdlci5DZm5TaXRlLkxvY2F0aW9uUHJvcGVydHkifV19fQ==")), "location") unless @location.nil?
  @tags = tags.is_a?(Array) ? tags.map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : tags
  Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil?
end

Instance Attribute Details

#descriptionString? (readonly)

A description of your site.

Constraints: Maximum length of 256 characters.



35
36
37
# File 'network_manager/cfn_site_props.rb', line 35

def description
  @description
end

#global_network_idString (readonly)

The ID of the global network.



28
29
30
# File 'network_manager/cfn_site_props.rb', line 28

def global_network_id
  @global_network_id
end

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

The site location.

This information is used for visualization in the Network Manager console. If you specify the address, the latitude and longitude are automatically calculated.

  • Address : The physical address of the site.
  • Latitude : The latitude of the site.
  • Longitude : The longitude of the site.


46
47
48
# File 'network_manager/cfn_site_props.rb', line 46

def location
  @location
end

#tagsArray<AWSCDK::CfnTag>? (readonly)

The tags for the site.



51
52
53
# File 'network_manager/cfn_site_props.rb', line 51

def tags
  @tags
end

Class Method Details

.jsii_propertiesObject



53
54
55
56
57
58
59
60
# File 'network_manager/cfn_site_props.rb', line 53

def self.jsii_properties
  {
    :global_network_id => "globalNetworkId",
    :description => "description",
    :location => "location",
    :tags => "tags",
  }
end

Instance Method Details

#to_jsiiObject



62
63
64
65
66
67
68
69
70
71
# File 'network_manager/cfn_site_props.rb', line 62

def to_jsii
  result = {}
  result.merge!({
    "globalNetworkId" => @global_network_id,
    "description" => @description,
    "location" => @location,
    "tags" => @tags,
  })
  result.compact
end