Class DynamoDBSaveExpression
java.lang.Object
com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBSaveExpression
Enables adding options to a save operation.
For example, you may want to save only if an attribute has a particular value.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the logical operator on the expected value conditions of this save operation.Gets the map of attribute names to expected attribute values to check on save.void
setConditionalOperator
(ConditionalOperator conditionalOperator) Sets the logical operator on the expected value conditions of this save operation.void
setConditionalOperator
(String conditionalOperator) Sets the logical operator on the expected value conditions of this save operation.void
setExpected
(Map<String, ExpectedAttributeValue> expectedAttributes) Sets the expected condition to the map of attribute names to expected attribute values given.withConditionalOperator
(ConditionalOperator conditionalOperator) Sets the logical operator on the expected value conditions of this save operation and returns a pointer to this object for method-chaining.withConditionalOperator
(String conditionalOperator) Sets the logical operator on the expected value conditions of this save operation and returns a pointer to this object for method-chaining.withExpected
(Map<String, ExpectedAttributeValue> expectedAttributes) Sets the expected condition to the map of attribute names to expected attribute values given and returns a pointer to this object for method-chaining.withExpectedEntry
(String attributeName, ExpectedAttributeValue expected) Adds one entry to the expected conditions and returns a pointer to this object for method-chaining.
-
Constructor Details
-
DynamoDBSaveExpression
public DynamoDBSaveExpression()
-
-
Method Details
-
getExpected
Gets the map of attribute names to expected attribute values to check on save.- Returns:
- The map of attribute names to expected attribute value conditions to check on save
-
setExpected
Sets the expected condition to the map of attribute names to expected attribute values given.- Parameters:
expectedAttributes
- The map of attribute names to expected attribute value conditions to check on save
-
withExpected
Sets the expected condition to the map of attribute names to expected attribute values given and returns a pointer to this object for method-chaining.- Parameters:
expectedAttributes
- The map of attribute names to expected attribute value conditions to check on save
-
withExpectedEntry
public DynamoDBSaveExpression withExpectedEntry(String attributeName, ExpectedAttributeValue expected) Adds one entry to the expected conditions and returns a pointer to this object for method-chaining.- Parameters:
attributeName
- The name of the attribute.expected
- The expected attribute value.
-
getConditionalOperator
Returns the logical operator on the expected value conditions of this save operation. -
setConditionalOperator
Sets the logical operator on the expected value conditions of this save operation. -
withConditionalOperator
Sets the logical operator on the expected value conditions of this save operation and returns a pointer to this object for method-chaining. -
setConditionalOperator
Sets the logical operator on the expected value conditions of this save operation. -
withConditionalOperator
Sets the logical operator on the expected value conditions of this save operation and returns a pointer to this object for method-chaining.
-