public PutItemRequest addExpectedEntry(String key, ExpectedAttributeValue value) {
        if (null == this.expected) {
            this.expected = new java.util.HashMap<String, ExpectedAttributeValue>();
        }
        if (this.expected.containsKey(key))
            throw new IllegalArgumentException("Duplicated keys (" + key.toString() + ") are provided.");
        this.expected.put(key, value);
        return this;
    }
Add a single Expected entry

@see PutItemRequest#withExpected
@returns a reference to this object so that method calls can be chained together.
aws-java-sdk-dynamodb/src/main/java/com/amazonaws/services/dynamodbv2/model/PutItemRequest.java