Class DatabaseClusterAttributes.Builder
java.lang.Object
software.amazon.awscdk.services.rds.DatabaseClusterAttributes.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<DatabaseClusterAttributes>
- Enclosing interface:
DatabaseClusterAttributes
@Stability(Stable)
public static final class DatabaseClusterAttributes.Builder
extends Object
implements software.amazon.jsii.Builder<DatabaseClusterAttributes>
A builder for
DatabaseClusterAttributes-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.clusterEndpointAddress(String clusterEndpointAddress) Sets the value ofDatabaseClusterAttributes.getClusterEndpointAddress()clusterIdentifier(String clusterIdentifier) Sets the value ofDatabaseClusterAttributes.getClusterIdentifier()clusterResourceIdentifier(String clusterResourceIdentifier) Sets the value ofDatabaseClusterAttributes.getClusterResourceIdentifier()dataApiEnabled(Boolean dataApiEnabled) Sets the value ofDatabaseClusterAttributes.getDataApiEnabled()engine(IClusterEngine engine) Sets the value ofDatabaseClusterAttributes.getEngine()instanceEndpointAddresses(List<String> instanceEndpointAddresses) Sets the value ofDatabaseClusterAttributes.getInstanceEndpointAddresses()instanceIdentifiers(List<String> instanceIdentifiers) Sets the value ofDatabaseClusterAttributes.getInstanceIdentifiers()Sets the value ofDatabaseClusterAttributes.getPort()readerEndpointAddress(String readerEndpointAddress) Sets the value ofDatabaseClusterAttributes.getReaderEndpointAddress()Sets the value ofDatabaseClusterAttributes.getSecret()securityGroups(List<? extends ISecurityGroup> securityGroups) Sets the value ofDatabaseClusterAttributes.getSecurityGroups()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
clusterIdentifier
@Stability(Stable) public DatabaseClusterAttributes.Builder clusterIdentifier(String clusterIdentifier) Sets the value ofDatabaseClusterAttributes.getClusterIdentifier()- Parameters:
clusterIdentifier- Identifier for the cluster. This parameter is required.- Returns:
this
-
clusterEndpointAddress
@Stability(Stable) public DatabaseClusterAttributes.Builder clusterEndpointAddress(String clusterEndpointAddress) Sets the value ofDatabaseClusterAttributes.getClusterEndpointAddress()- Parameters:
clusterEndpointAddress- Cluster endpoint address.- Returns:
this
-
clusterResourceIdentifier
@Stability(Stable) public DatabaseClusterAttributes.Builder clusterResourceIdentifier(String clusterResourceIdentifier) Sets the value ofDatabaseClusterAttributes.getClusterResourceIdentifier()- Parameters:
clusterResourceIdentifier- The immutable identifier for the cluster; for example: cluster-ABCD1234EFGH5678IJKL90MNOP. This AWS Region-unique identifier is used to grant access to the cluster.- Returns:
this
-
dataApiEnabled
Sets the value ofDatabaseClusterAttributes.getDataApiEnabled()- Parameters:
dataApiEnabled- Whether the Data API for the cluster is enabled.- Returns:
this
-
engine
Sets the value ofDatabaseClusterAttributes.getEngine()- Parameters:
engine- The engine of the existing Cluster.- Returns:
this
-
instanceEndpointAddresses
@Stability(Stable) public DatabaseClusterAttributes.Builder instanceEndpointAddresses(List<String> instanceEndpointAddresses) Sets the value ofDatabaseClusterAttributes.getInstanceEndpointAddresses()- Parameters:
instanceEndpointAddresses- Endpoint addresses of individual instances.- Returns:
this
-
instanceIdentifiers
@Stability(Stable) public DatabaseClusterAttributes.Builder instanceIdentifiers(List<String> instanceIdentifiers) Sets the value ofDatabaseClusterAttributes.getInstanceIdentifiers()- Parameters:
instanceIdentifiers- Identifier for the instances.- Returns:
this
-
port
Sets the value ofDatabaseClusterAttributes.getPort()- Parameters:
port- The database port.- Returns:
this
-
readerEndpointAddress
@Stability(Stable) public DatabaseClusterAttributes.Builder readerEndpointAddress(String readerEndpointAddress) Sets the value ofDatabaseClusterAttributes.getReaderEndpointAddress()- Parameters:
readerEndpointAddress- Reader endpoint address.- Returns:
this
-
secret
Sets the value ofDatabaseClusterAttributes.getSecret()- Parameters:
secret- The secret attached to the database cluster.- Returns:
this
-
securityGroups
@Stability(Stable) public DatabaseClusterAttributes.Builder securityGroups(List<? extends ISecurityGroup> securityGroups) Sets the value ofDatabaseClusterAttributes.getSecurityGroups()- Parameters:
securityGroups- The security groups of the database cluster.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<DatabaseClusterAttributes>- Returns:
- a new instance of
DatabaseClusterAttributes - Throws:
NullPointerException- if any required attribute was not provided
-