Class RdsDataSourceProps.Builder
java.lang.Object
software.amazon.awscdk.services.appsync.RdsDataSourceProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<RdsDataSourceProps>
- Enclosing interface:
RdsDataSourceProps
@Stability(Stable)
public static final class RdsDataSourceProps.Builder
extends Object
implements software.amazon.jsii.Builder<RdsDataSourceProps>
A builder for
RdsDataSourceProps
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionapi
(IGraphqlApi api) Sets the value ofBaseDataSourceProps.getApi()
build()
Builds the configured instance.databaseName
(String databaseName) Sets the value ofRdsDataSourceProps.getDatabaseName()
description
(String description) Sets the value ofBaseDataSourceProps.getDescription()
Sets the value ofBaseDataSourceProps.getName()
secretStore
(ISecret secretStore) Sets the value ofRdsDataSourceProps.getSecretStore()
serverlessCluster
(IServerlessCluster serverlessCluster) Sets the value ofRdsDataSourceProps.getServerlessCluster()
serviceRole
(IRole serviceRole) Sets the value ofBackedDataSourceProps.getServiceRole()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
secretStore
Sets the value ofRdsDataSourceProps.getSecretStore()
- Parameters:
secretStore
- The secret containing the credentials for the database. This parameter is required.- Returns:
this
-
serverlessCluster
@Stability(Stable) public RdsDataSourceProps.Builder serverlessCluster(IServerlessCluster serverlessCluster) Sets the value ofRdsDataSourceProps.getServerlessCluster()
- Parameters:
serverlessCluster
- The serverless cluster to call to interact with this data source. This parameter is required.- Returns:
this
-
databaseName
Sets the value ofRdsDataSourceProps.getDatabaseName()
- Parameters:
databaseName
- The name of the database to use within the cluster.- Returns:
this
-
serviceRole
Sets the value ofBackedDataSourceProps.getServiceRole()
- Parameters:
serviceRole
- The IAM service role to be assumed by AppSync to interact with the data source.- Returns:
this
-
api
Sets the value ofBaseDataSourceProps.getApi()
- Parameters:
api
- The API to attach this data source to. This parameter is required.- Returns:
this
-
description
Sets the value ofBaseDataSourceProps.getDescription()
- Parameters:
description
- the description of the data source.- Returns:
this
-
name
Sets the value ofBaseDataSourceProps.getName()
- Parameters:
name
- The name of the data source.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<RdsDataSourceProps>
- Returns:
- a new instance of
RdsDataSourceProps
- Throws:
NullPointerException
- if any required attribute was not provided
-