Interface ISelectedSubnets
Result of selecting a subset of subnets from a VPC.
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface ISelectedSubnets
Syntax (vb)
Public Interface ISelectedSubnets
Remarks
ExampleMetadata: infused
Examples
var vpc = new Vpc(this, "TheVPC", new VpcProps {
IpAddresses = IpAddresses.Cidr("10.0.0.0/16")
});
// Iterate the private subnets
var selection = vpc.SelectSubnets(new SubnetSelection {
SubnetType = SubnetType.PRIVATE_WITH_EGRESS
});
for (var subnet in selection.Subnets)
{
}
Synopsis
Properties
AvailabilityZones | The respective AZs of each subnet. |
HasPublic | Whether any of the given subnets are from the VPC's public subnets. |
InternetConnectivityEstablished | Dependency representing internet connectivity for these subnets. |
IsPendingLookup | The subnet selection is not actually real yet. |
SubnetIds | The subnet IDs. |
Subnets | Selected subnet objects. |
Properties
AvailabilityZones
The respective AZs of each subnet.
string[] AvailabilityZones { get; }
Property Value
System.String[]
HasPublic
Whether any of the given subnets are from the VPC's public subnets.
bool HasPublic { get; }
Property Value
System.Boolean
InternetConnectivityEstablished
Dependency representing internet connectivity for these subnets.
IDependable InternetConnectivityEstablished { get; }
Property Value
Constructs.IDependable
IsPendingLookup
The subnet selection is not actually real yet.
virtual Nullable<bool> IsPendingLookup { get; }
Property Value
System.Nullable<System.Boolean>
Remarks
If this value is true, don't validate anything about the subnets. The count or identities are not known yet, and the validation will most likely fail which will prevent a successful lookup.
Default: false
SubnetIds
The subnet IDs.
string[] SubnetIds { get; }
Property Value
System.String[]