Class DynamoDBAction
- All Implemented Interfaces:
Serializable
,Cloneable
Describes an action to write to a DynamoDB table.
The tableName
, hashKeyField
, and
rangeKeyField
values must match the values used when you created
the table.
The hashKeyValue
and rangeKeyvalue
fields use a
substitution template syntax. These templates provide data at runtime. The
syntax is as follows: ${sql-expression}.
You can specify any valid expression in a WHERE or SELECT clause, including JSON properties, comparisons, calculations, and functions. For example, the following field uses the third level of the topic:
"hashKeyValue": "${topic(3)}"
The following field uses the timestamp:
"rangeKeyValue": "${timestamp()}"
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()
boolean
The hash key name.The hash key value.The action payload.The range key name.The range key value.The ARN of the IAM role that grants access to the DynamoDB table.The name of the DynamoDB table.int
hashCode()
void
setHashKeyField
(String hashKeyField) The hash key name.void
setHashKeyValue
(String hashKeyValue) The hash key value.void
setPayloadField
(String payloadField) The action payload.void
setRangeKeyField
(String rangeKeyField) The range key name.void
setRangeKeyValue
(String rangeKeyValue) The range key value.void
setRoleArn
(String roleArn) The ARN of the IAM role that grants access to the DynamoDB table.void
setTableName
(String tableName) The name of the DynamoDB table.toString()
Returns a string representation of this object; useful for testing and debugging.withHashKeyField
(String hashKeyField) The hash key name.withHashKeyValue
(String hashKeyValue) The hash key value.withPayloadField
(String payloadField) The action payload.withRangeKeyField
(String rangeKeyField) The range key name.withRangeKeyValue
(String rangeKeyValue) The range key value.withRoleArn
(String roleArn) The ARN of the IAM role that grants access to the DynamoDB table.withTableName
(String tableName) The name of the DynamoDB table.
-
Constructor Details
-
DynamoDBAction
public DynamoDBAction()
-
-
Method Details
-
setTableName
The name of the DynamoDB table.
- Parameters:
tableName
- The name of the DynamoDB table.
-
getTableName
The name of the DynamoDB table.
- Returns:
- The name of the DynamoDB table.
-
withTableName
The name of the DynamoDB table.
- Parameters:
tableName
- The name of the DynamoDB table.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setRoleArn
The ARN of the IAM role that grants access to the DynamoDB table.
- Parameters:
roleArn
- The ARN of the IAM role that grants access to the DynamoDB table.
-
getRoleArn
The ARN of the IAM role that grants access to the DynamoDB table.
- Returns:
- The ARN of the IAM role that grants access to the DynamoDB table.
-
withRoleArn
The ARN of the IAM role that grants access to the DynamoDB table.
- Parameters:
roleArn
- The ARN of the IAM role that grants access to the DynamoDB table.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setHashKeyField
The hash key name.
- Parameters:
hashKeyField
- The hash key name.
-
getHashKeyField
The hash key name.
- Returns:
- The hash key name.
-
withHashKeyField
The hash key name.
- Parameters:
hashKeyField
- The hash key name.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setHashKeyValue
The hash key value.
- Parameters:
hashKeyValue
- The hash key value.
-
getHashKeyValue
The hash key value.
- Returns:
- The hash key value.
-
withHashKeyValue
The hash key value.
- Parameters:
hashKeyValue
- The hash key value.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setRangeKeyField
The range key name.
- Parameters:
rangeKeyField
- The range key name.
-
getRangeKeyField
The range key name.
- Returns:
- The range key name.
-
withRangeKeyField
The range key name.
- Parameters:
rangeKeyField
- The range key name.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setRangeKeyValue
The range key value.
- Parameters:
rangeKeyValue
- The range key value.
-
getRangeKeyValue
The range key value.
- Returns:
- The range key value.
-
withRangeKeyValue
The range key value.
- Parameters:
rangeKeyValue
- The range key value.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setPayloadField
The action payload. This name can be customized.
- Parameters:
payloadField
- The action payload. This name can be customized.
-
getPayloadField
The action payload. This name can be customized.
- Returns:
- The action payload. This name can be customized.
-
withPayloadField
The action payload. This name can be customized.
- Parameters:
payloadField
- The action payload. This name can be customized.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
Returns a string representation of this object; useful for testing and debugging. -
equals
-
hashCode
public int hashCode() -
clone
-