Class: AWSCDK::EC2::CfnTransitGatewayPeeringAttachmentProps

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

Overview

Properties for defining a CfnTransitGatewayPeeringAttachment.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(peer_account_id:, peer_region:, peer_transit_gateway_id:, transit_gateway_id:, tags: nil) ⇒ CfnTransitGatewayPeeringAttachmentProps

Returns a new instance of CfnTransitGatewayPeeringAttachmentProps.

Parameters:

  • peer_account_id (String)

    The ID of the AWS account that owns the transit gateway.

  • peer_region (String)

    The Region where the transit gateway that you want to create the peer for is located.

  • peer_transit_gateway_id (String)

    The ID of the transit gateway in the PeerRegion.

  • transit_gateway_id (String, AWSCDK::Interfaces::AWSEC2::ITransitGatewayRef)

    The ID of the transit gateway peering attachment.

  • tags (Array<AWSCDK::CfnTag>, nil) (defaults to: nil)

    The tags for the transit gateway peering attachment.



14
15
16
17
18
19
20
21
22
23
24
25
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 14

def initialize(peer_account_id:, peer_region:, peer_transit_gateway_id:, transit_gateway_id:, tags: nil)
  @peer_account_id = 
  Jsii::Type.check_type(@peer_account_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "peerAccountId")
  @peer_region = peer_region
  Jsii::Type.check_type(@peer_region, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "peerRegion")
  @peer_transit_gateway_id = peer_transit_gateway_id
  Jsii::Type.check_type(@peer_transit_gateway_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "peerTransitGatewayId")
  @transit_gateway_id = transit_gateway_id
  Jsii::Type.check_type(@transit_gateway_id, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19lYzIuSVRyYW5zaXRHYXRld2F5UmVmIn1dfX0=")), "transitGatewayId")
  @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

#peer_account_idString (readonly)

The ID of the AWS account that owns the transit gateway.



31
32
33
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 31

def 
  @peer_account_id
end

#peer_regionString (readonly)

The Region where the transit gateway that you want to create the peer for is located.



36
37
38
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 36

def peer_region
  @peer_region
end

#peer_transit_gateway_idString (readonly)

The ID of the transit gateway in the PeerRegion.



41
42
43
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 41

def peer_transit_gateway_id
  @peer_transit_gateway_id
end

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

The tags for the transit gateway peering attachment.



51
52
53
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 51

def tags
  @tags
end

#transit_gateway_idString, AWSCDK::Interfaces::AWSEC2::ITransitGatewayRef (readonly)

The ID of the transit gateway peering attachment.



46
47
48
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 46

def transit_gateway_id
  @transit_gateway_id
end

Class Method Details

.jsii_propertiesObject



53
54
55
56
57
58
59
60
61
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 53

def self.jsii_properties
  {
    :peer_account_id => "peerAccountId",
    :peer_region => "peerRegion",
    :peer_transit_gateway_id => "peerTransitGatewayId",
    :transit_gateway_id => "transitGatewayId",
    :tags => "tags",
  }
end

Instance Method Details

#to_jsiiObject



63
64
65
66
67
68
69
70
71
72
73
# File 'ec2/cfn_transit_gateway_peering_attachment_props.rb', line 63

def to_jsii
  result = {}
  result.merge!({
    "peerAccountId" => @peer_account_id,
    "peerRegion" => @peer_region,
    "peerTransitGatewayId" => @peer_transit_gateway_id,
    "transitGatewayId" => @transit_gateway_id,
    "tags" => @tags,
  })
  result.compact
end