Class CfnTransitGatewayAttachment
Attaches a VPC to a transit gateway.
Inherited Members
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnTransitGatewayAttachment : CfnResource, IInspectable, ITaggable
Syntax (vb)
Public Class CfnTransitGatewayAttachment
Inherits CfnResource
Implements IInspectable, ITaggable
Remarks
If you attach a VPC with a CIDR range that overlaps the CIDR range of a VPC that is already attached, the new VPC CIDR range is not propagated to the default propagation route table.
To send VPC traffic to an attached transit gateway, add a route to the VPC route table using AWS::EC2::Route .
To update tags for a VPC attachment after creation without replacing the attachment, use AWS::EC2::TransitGatewayVpcAttachment instead.
CloudformationResource: AWS::EC2::TransitGatewayAttachment
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.EC2;
var options;
var cfnTransitGatewayAttachment = new CfnTransitGatewayAttachment(this, "MyCfnTransitGatewayAttachment", new CfnTransitGatewayAttachmentProps {
SubnetIds = new [] { "subnetIds" },
TransitGatewayId = "transitGatewayId",
VpcId = "vpcId",
// the properties below are optional
Options = options,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
});
Synopsis
Constructors
CfnTransitGatewayAttachment(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CfnTransitGatewayAttachment(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
CfnTransitGatewayAttachment(Construct, String, ICfnTransitGatewayAttachmentProps) |
Properties
AttrId | The ID of the attachment. |
CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
CfnProperties | |
Options | The VPC attachment options. |
SubnetIds | The IDs of one or more subnets. |
Tags | Tag Manager which manages the tags for this resource. |
TagsRaw | The tags for the attachment. |
TransitGatewayId | The ID of the transit gateway. |
VpcId | The ID of the VPC. |
Methods
Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
RenderProperties(IDictionary<String, Object>) |
Constructors
CfnTransitGatewayAttachment(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CfnTransitGatewayAttachment(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CfnTransitGatewayAttachment(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CfnTransitGatewayAttachment(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
CfnTransitGatewayAttachment(Construct, String, ICfnTransitGatewayAttachmentProps)
public CfnTransitGatewayAttachment(Construct scope, string id, ICfnTransitGatewayAttachmentProps props)
Parameters
- scope Constructs.Construct
Scope in which this resource is defined.
- id System.String
Construct identifier for this resource (unique in its scope).
- props ICfnTransitGatewayAttachmentProps
Resource properties.
Properties
AttrId
The ID of the attachment.
public virtual string AttrId { get; }
Property Value
System.String
Remarks
CloudformationAttribute: Id
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
public static string CFN_RESOURCE_TYPE_NAME { get; }
Property Value
System.String
CfnProperties
protected override IDictionary<string, object> CfnProperties { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.Object>
Overrides
Options
The VPC attachment options.
public virtual object Options { get; set; }
Property Value
System.Object
SubnetIds
The IDs of one or more subnets.
public virtual string[] SubnetIds { get; set; }
Property Value
System.String[]
Tags
Tag Manager which manages the tags for this resource.
public virtual TagManager Tags { get; }
Property Value
TagsRaw
The tags for the attachment.
public virtual ICfnTag[] TagsRaw { get; set; }
Property Value
ICfnTag[]
TransitGatewayId
The ID of the transit gateway.
public virtual string TransitGatewayId { get; set; }
Property Value
System.String
VpcId
The ID of the VPC.
public virtual string VpcId { get; set; }
Property Value
System.String
Methods
Inspect(TreeInspector)
Examines the CloudFormation resource and discloses attributes.
public virtual void Inspect(TreeInspector inspector)
Parameters
- inspector TreeInspector
tree inspector to collect and process attributes.
RenderProperties(IDictionary<String, Object>)
protected override IDictionary<string, object> RenderProperties(IDictionary<string, object> props)
Parameters
- props System.Collections.Generic.IDictionary<System.String, System.Object>
Returns
System.Collections.Generic.IDictionary<System.String, System.Object>