@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:41.424Z") @Stability(value=Stable) public class CfnDBSubnetGroup extends CfnResource implements IInspectable
The AWS::RDS::DBSubnetGroup resource creates a database subnet group. Subnet groups must contain at least two subnets in two different Availability Zones in the same region.
For more information, see Working with DB subnet groups in the Amazon RDS User Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.rds.*;
CfnDBSubnetGroup cfnDBSubnetGroup = CfnDBSubnetGroup.Builder.create(this, "MyCfnDBSubnetGroup")
.dbSubnetGroupDescription("dbSubnetGroupDescription")
.subnetIds(List.of("subnetIds"))
// the properties below are optional
.dbSubnetGroupName("dbSubnetGroupName")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
| Modifier and Type | Class and Description |
|---|---|
static class |
CfnDBSubnetGroup.Builder
A fluent builder for
CfnDBSubnetGroup. |
software.amazon.jsii.JsiiObject.InitializationModeIInspectable.Jsii$Default, IInspectable.Jsii$Proxy| Modifier and Type | Field and Description |
|---|---|
static String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
| Modifier | Constructor and Description |
|---|---|
|
CfnDBSubnetGroup(software.constructs.Construct scope,
String id,
CfnDBSubnetGroupProps props)
Create a new `AWS::RDS::DBSubnetGroup`.
|
protected |
CfnDBSubnetGroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnDBSubnetGroup(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
protected Map<String,Object> |
getCfnProperties() |
String |
getDbSubnetGroupDescription()
The description for the DB subnet group.
|
String |
getDbSubnetGroupName()
The name for the DB subnet group.
|
List<String> |
getSubnetIds()
The EC2 Subnet IDs for the DB subnet group.
|
TagManager |
getTags()
Tags to assign to the DB subnet group.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected Map<String,Object> |
renderProperties(Map<String,Object> props) |
void |
setDbSubnetGroupDescription(String value)
The description for the DB subnet group.
|
void |
setDbSubnetGroupName(String value)
The name for the DB subnet group.
|
void |
setSubnetIds(List<String> value)
The EC2 Subnet IDs for the DB subnet group.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, shouldSynthesize, toString, validatePropertiesgetRefgetCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdjsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String CFN_RESOURCE_TYPE_NAME
protected CfnDBSubnetGroup(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnDBSubnetGroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public CfnDBSubnetGroup(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@NotNull
CfnDBSubnetGroupProps props)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.props - - resource properties. This parameter is required.@Stability(value=Stable)
public void inspect(@NotNull
TreeInspector inspector)
inspect in interface IInspectableinspector - - tree inspector to collect and process attributes. This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
renderProperties in class CfnResourceprops - This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> getCfnProperties()
getCfnProperties in class CfnResource@Stability(value=Stable) @NotNull public TagManager getTags()
@Stability(value=Stable) @NotNull public String getDbSubnetGroupDescription()
@Stability(value=Stable)
public void setDbSubnetGroupDescription(@NotNull
String value)
@Stability(value=Stable) @NotNull public List<String> getSubnetIds()
@Stability(value=Stable)
public void setSubnetIds(@NotNull
List<String> value)
@Stability(value=Stable) @Nullable public String getDbSubnetGroupName()
Constraints: Must contain no more than 255 lowercase alphanumeric characters or hyphens. Must not be "Default".
Example: mysubnetgroup
@Stability(value=Stable)
public void setDbSubnetGroupName(@Nullable
String value)
Constraints: Must contain no more than 255 lowercase alphanumeric characters or hyphens. Must not be "Default".
Example: mysubnetgroup
Copyright © 2022. All rights reserved.