@ThreadSafe public class Index extends Object implements QueryApi, ScanApi
Table.getIndex(String).| Modifier and Type | Method and Description | 
|---|---|
| TableDescription | deleteGSI()Deletes this global secondary index (GSI) from the DynamoDB table. | 
| String | getIndexName() | 
| Table | getTable()Returns the owning table. | 
| ItemCollection<QueryOutcome> | query(KeyAttribute hashKey)Retrieves items by the specified hash key. | 
| ItemCollection<QueryOutcome> | query(KeyAttribute hashKey,
     RangeKeyCondition rangeKeyCondition)Retrieves items by the specified hash key and a range key condition. | 
| ItemCollection<QueryOutcome> | query(KeyAttribute hashKey,
     RangeKeyCondition rangeKeyCondition,
     QueryExpressionSpec queryExpressions) | 
| ItemCollection<QueryOutcome> | query(KeyAttribute hashKey,
     RangeKeyCondition rangeKeyCondition,
     QueryFilter... queryFilters)Retrieves items by the specified hash key, a range key condition
 and a list of query filters. | 
| ItemCollection<QueryOutcome> | query(KeyAttribute hashKey,
     RangeKeyCondition rangeKeyCondition,
     String filterExpression,
     Map<String,String> nameMap,
     Map<String,Object> valueMap)Retrieves items by the specified hash key, a range key condition, and
 a filter expression string. | 
| ItemCollection<QueryOutcome> | query(KeyAttribute hashKey,
     RangeKeyCondition rangeKeyCondition,
     String projectionExpression,
     String filterExpression,
     Map<String,String> nameMap,
     Map<String,Object> valueMap)Retrieves items by the specified hash key, a range key condition,
 a filter expression and a projection expression. | 
| ItemCollection<QueryOutcome> | query(QuerySpec spec)Queries table by specifying all the details. | 
| ItemCollection<QueryOutcome> | query(String hashKeyName,
     Object hashKeyValue)Retrieves items by the specified hash key. | 
| ItemCollection<QueryOutcome> | query(String hashKeyName,
     Object hashKeyValue,
     RangeKeyCondition rangeKeyCondition) | 
| ItemCollection<QueryOutcome> | query(String hashKeyName,
     Object hashKeyValue,
     RangeKeyCondition rangeKeyCondition,
     QueryFilter... queryFilters) | 
| ItemCollection<QueryOutcome> | query(String hashKeyName,
     Object hashKeyValue,
     RangeKeyCondition rangeKeyCondition,
     String filterExpression,
     Map<String,String> nameMap,
     Map<String,Object> valueMap) | 
| ItemCollection<QueryOutcome> | query(String hashKeyName,
     Object hashKeyValue,
     RangeKeyCondition rangeKeyCondition,
     String filterExpression,
     String projectionExpression,
     Map<String,String> nameMap,
     Map<String,Object> valueMap)Retrieves items by the specified hash key, a range key condition,
 a filter expression and a projection expression. | 
| ItemCollection<ScanOutcome> | scan(ScanExpressionSpec xspec) | 
| ItemCollection<ScanOutcome> | scan(ScanFilter... scanFilters)Retrieves items by the specified list of scan filters. | 
| ItemCollection<ScanOutcome> | scan(ScanSpec params)Scans table by specifying all the details. | 
| ItemCollection<ScanOutcome> | scan(String filterExpression,
    Map<String,String> nameMap,
    Map<String,Object> valueMap)Scans table using a Filter Expression. | 
| ItemCollection<ScanOutcome> | scan(String filterExpression,
    String projectionExpression,
    Map<String,String> nameMap,
    Map<String,Object> valueMap)Scans table using a Filter Expression and a Projection Expression. | 
| TableDescription | updateGSI(ProvisionedThroughput provisionedThroughput)Updates the provisioned throughput for this global secondary index (GSI). | 
| TableDescription | waitForActive()A convenient blocking call that can be used, typically during index
 creation, to wait for the index to become active by polling the table
 every 5 seconds. | 
| TableDescription | waitForActiveOrDelete()A convenient blocking call that can be used to wait on an index until it
 has either become active or deleted (ie no longer exists) by polling the
 table every 5 seconds. | 
| TableDescription | waitForDelete()A convenient blocking call that can be used, typically during index
 deletion on an active table, to wait for the index to become deleted by
 polling the table every 5 seconds. | 
public final Table getTable()
public final String getIndexName()
public ItemCollection<QueryOutcome> query(KeyAttribute hashKey, RangeKeyCondition rangeKeyCondition)
QueryApipublic ItemCollection<QueryOutcome> query(KeyAttribute hashKey, RangeKeyCondition rangeKeyCondition, QueryFilter... queryFilters)
QueryApipublic ItemCollection<QueryOutcome> query(KeyAttribute hashKey, RangeKeyCondition rangeKeyCondition, String filterExpression, Map<String,String> nameMap, Map<String,Object> valueMap)
QueryApiquery in interface QueryApifilterExpression - filter expression
 example: "(#a > :a) AND (#c > :c OR #e < :e)"nameMap - actual values for the attribute-name place holders;
                can be null if there is no attribute-name placeholder.valueMap - actual values for the value place holders
                can be null if there is no attribute-value placeholder.public ItemCollection<QueryOutcome> query(KeyAttribute hashKey, RangeKeyCondition rangeKeyCondition, String projectionExpression, String filterExpression, Map<String,String> nameMap, Map<String,Object> valueMap)
QueryApiquery in interface QueryApiprojectionExpression - filter expression
 example: "(#a > :a) AND (#c > :c OR #e < :e)"filterExpression - projection expression
 example: "a.b, c[0].e"nameMap - actual values for the attribute-name place holders;
                can be null if there is no attribute-name placeholder.valueMap - actual values for the value place holders
                can be null if there is no attribute-value placeholder.@Beta public ItemCollection<QueryOutcome> query(KeyAttribute hashKey, RangeKeyCondition rangeKeyCondition, QueryExpressionSpec queryExpressions)
public ItemCollection<QueryOutcome> query(QuerySpec spec)
QueryApipublic ItemCollection<QueryOutcome> query(String hashKeyName, Object hashKeyValue)
QueryApipublic ItemCollection<QueryOutcome> query(String hashKeyName, Object hashKeyValue, RangeKeyCondition rangeKeyCondition)
public ItemCollection<QueryOutcome> query(String hashKeyName, Object hashKeyValue, RangeKeyCondition rangeKeyCondition, QueryFilter... queryFilters)
public ItemCollection<QueryOutcome> query(String hashKeyName, Object hashKeyValue, RangeKeyCondition rangeKeyCondition, String filterExpression, Map<String,String> nameMap, Map<String,Object> valueMap)
public ItemCollection<QueryOutcome> query(String hashKeyName, Object hashKeyValue, RangeKeyCondition rangeKeyCondition, String filterExpression, String projectionExpression, Map<String,String> nameMap, Map<String,Object> valueMap)
QueryApiquery in interface QueryApifilterExpression - filter expression
 example: "(#a > :a) AND (#c > :c OR #e < :e)"projectionExpression - projection expression
 example: "a.b, c[0].e"nameMap - actual values for the attribute-name place holders;
                can be null if there is no attribute-name placeholder.valueMap - actual values for the value place holders
                can be null if there is no attribute-value placeholder.public ItemCollection<QueryOutcome> query(KeyAttribute hashKey)
QueryApipublic TableDescription updateGSI(ProvisionedThroughput provisionedThroughput)
The provisioned throughput values can be upgraded or downgraded based on the maximums and minimums listed in the Limits section in the Amazon DynamoDB Developer Guide.
 This index must be a global secondary index and in the
 ACTIVE state for this operation to succeed. Updating a GSI
 is an asynchronous operation; while executing the operation, the index is
 in the UPDATING state. While the index is in the
 UPDATING state, the index still has the provisioned
 throughput from before the call. The new provisioned throughput setting
 is in effect only when the index returns to the ACTIVE state
 after the update is complete.
provisionedThroughput - target provisioned throughputpublic TableDescription deleteGSI()
 This index must be a global secondary index and in the
 ACTIVE state for this operation to succeed. Deleting a GSI
 is an asynchronous operation; while executing the operation, the index is
 in the DELETING state.
public TableDescription waitForActive() throws InterruptedException
 Currently online index creation is only supported for Global Secondary
 Index (GSI). Calling this method on a Local Secondary Index (LSI) would
 result in IllegalArgumentException.
IllegalArgumentException - if the table is being deleted, or if
 the GSI is not being created or updated, or if the GSI doesn't existResourceNotFoundException - if the table doesn't existInterruptedExceptionpublic TableDescription waitForDelete() throws InterruptedException
Currently online index deletion is only supported for Global Secondary Index (GSI). The behavior of calling this method on a Local Secondary Index (LSI) would result in returning the latest table description.
IllegalArgumentException - if the table is being deleted, or if the
 GSI is not being deleted.ResourceNotFoundException - if the table doesn't existInterruptedExceptionpublic TableDescription waitForActiveOrDelete() throws InterruptedException
Currently online index creation/deletion is only supported for Global Secondary Index (GSI). The behavior of calling this method on a Local Secondary Index (LSI) would result in returning the latest table description.
IllegalArgumentException - if the table is being deletedResourceNotFoundException - if the table doesn't existInterruptedExceptionpublic ItemCollection<ScanOutcome> scan(ScanFilter... scanFilters)
ScanApipublic ItemCollection<ScanOutcome> scan(String filterExpression, Map<String,String> nameMap, Map<String,Object> valueMap)
ScanApiscan in interface ScanApifilterExpression - condition expression example:
            "(#a > :a) AND (#c > :c OR #e < :e)"nameMap - actual values for the attribute-name place holders; can be
            null if there is no attribute-name placeholder.valueMap - actual values for the value place holders can be null if there
            is no attribute-value placeholder.public ItemCollection<ScanOutcome> scan(String filterExpression, String projectionExpression, Map<String,String> nameMap, Map<String,Object> valueMap)
ScanApiscan in interface ScanApifilterExpression - condition expression example:
            "(#a > :a) AND (#c > :c OR #e < :e)"projectionExpression - projection expression example: "a.b , c[0].e"nameMap - actual values for the attribute-name place holders;
                can be null if there is no attribute-name placeholder.valueMap - actual values for the value place holders
                can be null if there is no attribute-value placeholder.@Beta public ItemCollection<ScanOutcome> scan(ScanExpressionSpec xspec)
public ItemCollection<ScanOutcome> scan(ScanSpec params)
ScanApiCopyright © 2015. All rights reserved.