Class PutItemEnhancedRequest.Builder<T>
- java.lang.Object
-
- software.amazon.awssdk.enhanced.dynamodb.model.PutItemEnhancedRequest.Builder<T>
-
- Enclosing class:
- PutItemEnhancedRequest<T>
@NotThreadSafe public static final class PutItemEnhancedRequest.Builder<T> extends Object
A builder that is used to create a request with the desired parameters.Note: A valid request builder must define an item.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PutItemEnhancedRequest<T>
build()
PutItemEnhancedRequest.Builder<T>
conditionExpression(Expression conditionExpression)
Defines a logical expression on an item's attribute values which, if evaluating to true, will allow the put operation to succeed.PutItemEnhancedRequest.Builder<T>
item(T item)
Sets the item to write to DynamoDb.PutItemEnhancedRequest.Builder<T>
returnConsumedCapacity(String returnConsumedCapacity)
Whether to return the capacity consumed by this operation.PutItemEnhancedRequest.Builder<T>
returnConsumedCapacity(ReturnConsumedCapacity returnConsumedCapacity)
Whether to return the capacity consumed by this operation.PutItemEnhancedRequest.Builder<T>
returnItemCollectionMetrics(String returnItemCollectionMetrics)
Whether to return the item collection metrics.PutItemEnhancedRequest.Builder<T>
returnItemCollectionMetrics(ReturnItemCollectionMetrics returnItemCollectionMetrics)
Whether to return the item collection metrics.PutItemEnhancedRequest.Builder<T>
returnValues(String returnValues)
Whether to return the values of the item before this request.PutItemEnhancedRequest.Builder<T>
returnValues(ReturnValue returnValues)
Whether to return the values of the item before this request.PutItemEnhancedRequest.Builder<T>
returnValuesOnConditionCheckFailure(String returnValuesOnConditionCheckFailure)
Whether to return the item on condition check failure.PutItemEnhancedRequest.Builder<T>
returnValuesOnConditionCheckFailure(ReturnValuesOnConditionCheckFailure returnValuesOnConditionCheckFailure)
Whether to return the item on condition check failure.
-
-
-
Method Detail
-
item
public PutItemEnhancedRequest.Builder<T> item(T item)
Sets the item to write to DynamoDb. Required.- Parameters:
item
- the item to write- Returns:
- a builder of this type
-
conditionExpression
public PutItemEnhancedRequest.Builder<T> conditionExpression(Expression conditionExpression)
Defines a logical expression on an item's attribute values which, if evaluating to true, will allow the put operation to succeed. If evaluating to false, the operation will not succeed.See
Expression
for condition syntax and examples.- Parameters:
conditionExpression
- a condition written as anExpression
- Returns:
- a builder of this type
-
returnValues
public PutItemEnhancedRequest.Builder<T> returnValues(ReturnValue returnValues)
Whether to return the values of the item before this request.
-
returnValues
public PutItemEnhancedRequest.Builder<T> returnValues(String returnValues)
Whether to return the values of the item before this request.
-
returnConsumedCapacity
public PutItemEnhancedRequest.Builder<T> returnConsumedCapacity(ReturnConsumedCapacity returnConsumedCapacity)
Whether to return the capacity consumed by this operation.
-
returnConsumedCapacity
public PutItemEnhancedRequest.Builder<T> returnConsumedCapacity(String returnConsumedCapacity)
Whether to return the capacity consumed by this operation.
-
returnItemCollectionMetrics
public PutItemEnhancedRequest.Builder<T> returnItemCollectionMetrics(ReturnItemCollectionMetrics returnItemCollectionMetrics)
Whether to return the item collection metrics.
-
returnItemCollectionMetrics
public PutItemEnhancedRequest.Builder<T> returnItemCollectionMetrics(String returnItemCollectionMetrics)
Whether to return the item collection metrics.
-
returnValuesOnConditionCheckFailure
public PutItemEnhancedRequest.Builder<T> returnValuesOnConditionCheckFailure(ReturnValuesOnConditionCheckFailure returnValuesOnConditionCheckFailure)
Whether to return the item on condition check failure.
-
returnValuesOnConditionCheckFailure
public PutItemEnhancedRequest.Builder<T> returnValuesOnConditionCheckFailure(String returnValuesOnConditionCheckFailure)
Whether to return the item on condition check failure.
-
build
public PutItemEnhancedRequest<T> build()
-
-