Class DynamoDbDataSourceProps.Builder
java.lang.Object
software.amazon.awscdk.services.appsync.DynamoDbDataSourceProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<DynamoDbDataSourceProps>
- Enclosing interface:
DynamoDbDataSourceProps
@Stability(Stable)
public static final class DynamoDbDataSourceProps.Builder
extends Object
implements software.amazon.jsii.Builder<DynamoDbDataSourceProps>
A builder for
DynamoDbDataSourceProps
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionapi
(IGraphqlApi api) Sets the value ofBaseDataSourceProps.getApi()
build()
Builds the configured instance.description
(String description) Sets the value ofBaseDataSourceProps.getDescription()
Sets the value ofBaseDataSourceProps.getName()
readOnlyAccess
(Boolean readOnlyAccess) Sets the value ofDynamoDbDataSourceProps.getReadOnlyAccess()
serviceRole
(IRole serviceRole) Sets the value ofBackedDataSourceProps.getServiceRole()
Sets the value ofDynamoDbDataSourceProps.getTable()
useCallerCredentials
(Boolean useCallerCredentials) Sets the value ofDynamoDbDataSourceProps.getUseCallerCredentials()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
table
Sets the value ofDynamoDbDataSourceProps.getTable()
- Parameters:
table
- The DynamoDB table backing this data source. This parameter is required.- Returns:
this
-
readOnlyAccess
Sets the value ofDynamoDbDataSourceProps.getReadOnlyAccess()
- Parameters:
readOnlyAccess
- Specify whether this DS is read only or has read and write permissions to the DynamoDB table.- Returns:
this
-
useCallerCredentials
@Stability(Stable) public DynamoDbDataSourceProps.Builder useCallerCredentials(Boolean useCallerCredentials) Sets the value ofDynamoDbDataSourceProps.getUseCallerCredentials()
- Parameters:
useCallerCredentials
- use credentials of caller to access DynamoDB.- 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<DynamoDbDataSourceProps>
- Returns:
- a new instance of
DynamoDbDataSourceProps
- Throws:
NullPointerException
- if any required attribute was not provided
-