public class Table
extends java.lang.Object
| Constructor and Description |
|---|
Table(com.amazonaws.services.dynamodbv2.AmazonDynamoDB client,
java.lang.String tableName)
Constructor.
|
Table(com.amazonaws.services.dynamodbv2.AmazonDynamoDB client,
java.lang.String tableName,
com.amazonaws.services.dynamodbv2.model.TableDescription tableDescription)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected static <X extends com.amazonaws.AmazonWebServiceRequest> |
appendDynamoDBDocumentUserAgentString(X request) |
Document |
deleteItem(Primitive hashKey)
Delete a document in DynamoDB.
|
Document |
deleteItem(Primitive hashKey,
DeleteItemOperationConfig config)
Delete a document in DynamoDB.
|
Document |
deleteItem(Primitive hashKey,
Primitive rangeKey)
Delete a document in DynamoDB.
|
Document |
deleteItem(Primitive hashKey,
Primitive rangeKey,
DeleteItemOperationConfig config)
Delete a document in DynamoDB.
|
java.util.List<com.amazonaws.services.dynamodbv2.model.AttributeDefinition> |
getAttributes() |
protected com.amazonaws.services.dynamodbv2.AmazonDynamoDB |
getClient() |
java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.GlobalSecondaryIndexDescription> |
getGlobalSecondaryIndexes() |
java.util.List<java.lang.String> |
getGlobalSecondaryIndexNames() |
java.util.List<java.lang.String> |
getHashKeys() |
Document |
getItem(Primitive hashKey)
Gets a document from DynamoDB by hash primary key.
|
Document |
getItem(Primitive hashKey,
GetItemOperationConfig config)
Gets a document from DynamoDB by hash primary key, using specified
configs.
|
Document |
getItem(Primitive hashKey,
Primitive rangeKey)
Gets a document from DynamoDB by hash-and-range primary key.
|
Document |
getItem(Primitive hashKey,
Primitive rangeKey,
GetItemOperationConfig config)
Gets a document from DynamoDB by hash-and-range primary key, using
specified configs.
|
java.util.Map<java.lang.String,KeyDescription> |
getKeys() |
java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.LocalSecondaryIndexDescription> |
getLocalSecondaryIndexes() |
java.util.List<java.lang.String> |
getLocalSecondaryIndexNames() |
java.util.List<java.lang.String> |
getRangeKeys() |
com.amazonaws.services.dynamodbv2.model.TableDescription |
getTableDescription() |
java.lang.String |
getTableName() |
static Table |
loadTable(com.amazonaws.services.dynamodbv2.AmazonDynamoDB client,
java.lang.String tableName)
Load table configuration.
|
void |
loadTableDescription()
Load table description.
|
Document |
putItem(Document document)
Puts a document into DynamoDB.
|
Document |
putItem(Document document,
PutItemOperationConfig config)
Puts a document into DynamoDB.
|
Search |
query(Primitive hashKey)
Initiates a Search object to Query a DynamoDB table, with the specified
hash primary key.
|
Search |
query(Primitive hashKey,
Expression filterExpression)
Initiates a Search object to Query a DynamoDB table, with the specified
hash primary key and filterExpression.
|
Search |
query(Primitive hashKey,
QueryFilter filter)
Initiates a Search object to Query a DynamoDB table, with the specified
hash primary key and filter.
|
Search |
query(QueryFilter filter)
Initiates a Search object to Query a DynamoDB table, with the specified
query filter.
|
Search |
query(QueryOperationConfig config)
Initiates a Search object to Query a DynamoDB table, with the specified
query operation config.
|
Search |
scan(Expression filterExpression)
Initiates a Search object to Scan a DynamoDB table, with the specified
expression.
|
Search |
scan(ScanFilter filter)
Initiates a Search object to Scan a DynamoDB table, with the specified
filter.
|
Search |
scan(ScanOperationConfig config)
Initiates a Search object to Query a DynamoDB table, with the specified
config.
|
protected void |
setAttributes(java.util.List<com.amazonaws.services.dynamodbv2.model.AttributeDefinition> attributes) |
protected void |
setGlobalSecondaryIndexes(java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.GlobalSecondaryIndexDescription> globalSecondaryIndexes) |
protected void |
setGlobalSecondaryIndexNames(java.util.List<java.lang.String> globalSecondaryIndexNames) |
protected void |
setHashKeys(java.util.List<java.lang.String> hashKeys) |
protected void |
setKeys(java.util.Map<java.lang.String,KeyDescription> keys) |
protected void |
setLocalSecondaryIndexes(java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.LocalSecondaryIndexDescription> localSecondaryIndexes) |
protected void |
setLocalSecondaryIndexNames(java.util.List<java.lang.String> localSecondaryIndexNames) |
protected void |
setRangeKeys(java.util.List<java.lang.String> rangeKeys) |
protected void |
setTableDescription(com.amazonaws.services.dynamodbv2.model.TableDescription tableDescription) |
Document |
updateItem(Document doc,
Primitive hashKey,
Primitive rangeKey,
UpdateItemOperationConfig config)
Update a document in DynamoDB.
|
Document |
updateItem(Document doc,
Primitive hashKey,
UpdateItemOperationConfig config)
Update a document in DynamoDB.
|
Document |
updateItem(Document doc,
UpdateItemOperationConfig config)
Update a document in DynamoDB.
|
public Table(com.amazonaws.services.dynamodbv2.AmazonDynamoDB client,
java.lang.String tableName)
client - the dynamodb client.tableName - the table name.public Table(com.amazonaws.services.dynamodbv2.AmazonDynamoDB client,
java.lang.String tableName,
com.amazonaws.services.dynamodbv2.model.TableDescription tableDescription)
client - the dynamodb client.tableName - the table name.tableDescription - the table description.protected static <X extends com.amazonaws.AmazonWebServiceRequest> X appendDynamoDBDocumentUserAgentString(X request)
public static Table loadTable(com.amazonaws.services.dynamodbv2.AmazonDynamoDB client, java.lang.String tableName)
client - the dynamodb client.tableName - the tablename.public void loadTableDescription()
public java.lang.String getTableName()
public com.amazonaws.services.dynamodbv2.model.TableDescription getTableDescription()
public java.util.Map<java.lang.String,KeyDescription> getKeys()
public java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.GlobalSecondaryIndexDescription> getGlobalSecondaryIndexes()
public java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.LocalSecondaryIndexDescription> getLocalSecondaryIndexes()
public java.util.List<java.lang.String> getLocalSecondaryIndexNames()
public java.util.List<java.lang.String> getGlobalSecondaryIndexNames()
public java.util.List<java.lang.String> getHashKeys()
public java.util.List<java.lang.String> getRangeKeys()
public java.util.List<com.amazonaws.services.dynamodbv2.model.AttributeDefinition> getAttributes()
protected void setKeys(java.util.Map<java.lang.String,KeyDescription> keys)
protected void setGlobalSecondaryIndexes(java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.GlobalSecondaryIndexDescription> globalSecondaryIndexes)
protected void setLocalSecondaryIndexes(java.util.Map<java.lang.String,com.amazonaws.services.dynamodbv2.model.LocalSecondaryIndexDescription> localSecondaryIndexes)
protected void setLocalSecondaryIndexNames(java.util.List<java.lang.String> localSecondaryIndexNames)
protected void setGlobalSecondaryIndexNames(java.util.List<java.lang.String> globalSecondaryIndexNames)
protected void setHashKeys(java.util.List<java.lang.String> hashKeys)
protected void setRangeKeys(java.util.List<java.lang.String> rangeKeys)
protected void setAttributes(java.util.List<com.amazonaws.services.dynamodbv2.model.AttributeDefinition> attributes)
public Document putItem(Document document)
document - the Document.public Document putItem(Document document, PutItemOperationConfig config)
document - the Document.config - PutItemOperationConfig.Document.public Document getItem(Primitive hashKey)
hashKey - the hash key.Document.public Document getItem(Primitive hashKey, Primitive rangeKey)
hashKey - the hash key.rangeKey - the range key.Document.public Document getItem(Primitive hashKey, GetItemOperationConfig config)
hashKey - the hash key.config - the GetItemOperationConfig.Document.public Document getItem(Primitive hashKey, Primitive rangeKey, GetItemOperationConfig config)
hashKey - the hash key.rangeKey - the range keyconfig - the GetItemOperationConfig.Document.public Document deleteItem(Primitive hashKey)
hashKey - the hash key.public Document deleteItem(Primitive hashKey, Primitive rangeKey)
hashKey - the hash key.rangeKey - the range key.public Document deleteItem(Primitive hashKey, DeleteItemOperationConfig config)
hashKey - the hash key.config - the DeleteItemOperationConfig.public Document deleteItem(Primitive hashKey, Primitive rangeKey, DeleteItemOperationConfig config)
hashKey - the hash key.rangeKey - the range key.config - the DeleteItemOperationConfig.public Document updateItem(Document doc, UpdateItemOperationConfig config)
doc - Document to update.config - the UpdateItemOperationConfig.Document.public Document updateItem(Document doc, Primitive hashKey, UpdateItemOperationConfig config)
doc - Document to update.hashKey - the hash key.config - the UpdateItemOperationConfig.Document.public Document updateItem(Document doc, Primitive hashKey, Primitive rangeKey, UpdateItemOperationConfig config)
doc - Document to update.hashKey - the hash key.rangeKey - the range key.config - the UpdateItemOperationConfig.Document.public Search query(Primitive hashKey, QueryFilter filter)
hashKey - the hash key to query against.filter - the QueryFilter.Search object.public Search query(Primitive hashKey, Expression filterExpression)
hashKey - the hash KeyfilterExpression - the filter Expression.public Search query(Primitive hashKey)
hashKey - the hash key to query against.Search object.public Search query(QueryFilter filter)
filter - the QueryFilter.Search object.public Search query(QueryOperationConfig config)
config - the QueryOperationConfig.Search object.public Search scan(ScanFilter filter)
filter - Filter to apply to the scan.public Search scan(Expression filterExpression)
filterExpression - Expression to apply to the scan.public Search scan(ScanOperationConfig config)
config - Configuration to use.protected com.amazonaws.services.dynamodbv2.AmazonDynamoDB getClient()
protected void setTableDescription(com.amazonaws.services.dynamodbv2.model.TableDescription tableDescription)