Class ScanSpec
- java.lang.Object
-
- com.amazonaws.services.dynamodbv2.document.spec.ScanSpec
-
public class ScanSpec extends Object
API for fully specifying all the parameters of a Table-centric Scan API.
-
-
Constructor Summary
Constructors Constructor Description ScanSpec()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<String>
getAttributesToGet()
String
getConditionalOperator()
AND|OR that applies to all the conditions in the ScanFilters.Collection<KeyAttribute>
getExclusiveStartKey()
String
getFilterExpression()
Any query filters will be ignored if a filter expression has been specified.Integer
getMaxPageSize()
The maximum number of resources to be retrieved in a single page; used for pagination purposes.Integer
getMaxResultSize()
The maximum number of resources to be retrieved in this query, including all the resources in all pages to be retrieved.Map<String,String>
getNameMap()
ProgressListener
getProgressListener()
String
getProjectionExpression()
T
getRequest()
Internal method.RequestMetricCollector
getRequestMetricCollector()
String
getReturnConsumedCapacity()
Collection<ScanFilter>
getScanFilters()
Integer
getSegment()
String
getSelect()
Specifies the attributes to be returned.Integer
getTotalSegments()
Map<String,Object>
getValueMap()
Boolean
isConsistentRead()
void
setMaxPageSize(Integer value)
void
setMaxResultSize(int maxResultSize)
void
setMaxResultSize(Integer maxResultSize)
void
setProgressListener(ProgressListener progressListener)
void
setRequestMetricCollector(RequestMetricCollector requestMetricCollector)
ScanSpec
withAttributesToGet(String... attributes)
ScanSpec
withConditionalOperator(ConditionalOperator op)
ScanSpec
withConsistentRead(Boolean consistentRead)
ScanSpec
withExclusiveStartKey(KeyAttribute... exclusiveStartKey)
ScanSpec
withExclusiveStartKey(PrimaryKey exclusiveStartKey)
ScanSpec
withExclusiveStartKey(String hashKeyName, Object hashKeyValue)
ScanSpec
withExclusiveStartKey(String hashKeyName, Object hashKeyValue, String rangeKeyName, Object rangeKeyValue)
ScanSpec
withExpressionSpec(ScanExpressionSpec xspec)
Convenient method to specify expressions (and the associated name map and value map) viaScanExpressionSpec
.ScanSpec
withFilterExpression(String filterExpression)
ScanSpec
withMaxPageSize(int maxPageSize)
ScanSpec
withMaxPageSize(Integer maxPageSize)
ScanSpec
withMaxResultSize(int maxResultSize)
ScanSpec
withMaxResultSize(Integer maxResultSize)
ScanSpec
withNameMap(Map<String,String> nameMap)
Applicable only when an expression has been specified.ScanSpec
withProgressListener(ProgressListener progressListener)
ScanSpec
withProjectionExpression(String projectionExpression)
ScanSpec
withRequestMetricCollector(RequestMetricCollector requestMetricCollector)
ScanSpec
withReturnConsumedCapacity(ReturnConsumedCapacity capacity)
ScanSpec
withScanFilters(ScanFilter... scanFilters)
ScanSpec
withSegment(Integer segment)
ScanSpec
withSelect(Select select)
ScanSpec
withTotalSegments(Integer totalSegments)
ScanSpec
withValueMap(Map<String,Object> valueMap)
Applicable only when an expression has been specified.
-
-
-
Method Detail
-
getScanFilters
public Collection<ScanFilter> getScanFilters()
- See Also:
ScanRequest.getScanFilter()
-
withScanFilters
public ScanSpec withScanFilters(ScanFilter... scanFilters)
- See Also:
ScanRequest.withScanFilter(Map)
-
getConditionalOperator
public String getConditionalOperator()
AND|OR that applies to all the conditions in the ScanFilters.- See Also:
ScanRequest.getConditionalOperator()
-
withConditionalOperator
public ScanSpec withConditionalOperator(ConditionalOperator op)
-
getAttributesToGet
public List<String> getAttributesToGet()
- See Also:
ScanRequest.getAttributesToGet()
-
getFilterExpression
public String getFilterExpression()
Any query filters will be ignored if a filter expression has been specified. When a filter expression is specified, the corresponding name-map and value-map can also be specified viawithNameMap(Map)
andwithValueMap(Map)
.- See Also:
ScanRequest.getFilterExpression()
-
withFilterExpression
public ScanSpec withFilterExpression(String filterExpression)
- See Also:
ScanRequest.withFilterExpression(String)
-
getProjectionExpression
public String getProjectionExpression()
- See Also:
ScanRequest.getProjectionExpression()
-
withNameMap
public ScanSpec withNameMap(Map<String,String> nameMap)
Applicable only when an expression has been specified. Used to specify the actual values for the attribute-name placeholders, where the value in the map can either be string for simple attribute name, or a JSON path expression.
-
withValueMap
public ScanSpec withValueMap(Map<String,Object> valueMap)
Applicable only when an expression has been specified. Used to specify the actual values for the attribute-value placeholders.
-
getReturnConsumedCapacity
public String getReturnConsumedCapacity()
- See Also:
ScanRequest.getReturnConsumedCapacity()
-
withReturnConsumedCapacity
public ScanSpec withReturnConsumedCapacity(ReturnConsumedCapacity capacity)
-
getSelect
public String getSelect()
Specifies the attributes to be returned.- See Also:
ScanRequest.getSelect()
-
withSelect
public ScanSpec withSelect(Select select)
- See Also:
ScanRequest.withSelect(Select)
-
getSegment
public Integer getSegment()
- See Also:
ScanRequest.getSegment()
-
withSegment
public ScanSpec withSegment(Integer segment)
- See Also:
ScanRequest.withSegment(Integer)
-
getTotalSegments
public Integer getTotalSegments()
- See Also:
ScanRequest.getTotalSegments()
-
withTotalSegments
public ScanSpec withTotalSegments(Integer totalSegments)
- See Also:
ScanRequest.withTotalSegments(Integer)
-
isConsistentRead
public Boolean isConsistentRead()
- See Also:
ScanRequest.isConsistentRead()
-
withConsistentRead
public ScanSpec withConsistentRead(Boolean consistentRead)
- See Also:
ScanRequest.withConsistentRead(Boolean)
-
getExclusiveStartKey
public Collection<KeyAttribute> getExclusiveStartKey()
- See Also:
ScanRequest.getExclusiveStartKey()
-
withExclusiveStartKey
public ScanSpec withExclusiveStartKey(KeyAttribute... exclusiveStartKey)
- See Also:
ScanRequest.withExclusiveStartKey(Map)
-
withExclusiveStartKey
public ScanSpec withExclusiveStartKey(PrimaryKey exclusiveStartKey)
- See Also:
ScanRequest.withExclusiveStartKey(Map)
-
withExclusiveStartKey
public ScanSpec withExclusiveStartKey(String hashKeyName, Object hashKeyValue)
- See Also:
ScanRequest.withExclusiveStartKey(Map)
-
withExclusiveStartKey
public ScanSpec withExclusiveStartKey(String hashKeyName, Object hashKeyValue, String rangeKeyName, Object rangeKeyValue)
- See Also:
ScanRequest.withExclusiveStartKey(Map)
-
withMaxResultSize
public ScanSpec withMaxResultSize(int maxResultSize)
-
withMaxPageSize
public ScanSpec withMaxPageSize(int maxPageSize)
-
withProgressListener
public ScanSpec withProgressListener(ProgressListener progressListener)
-
withRequestMetricCollector
public ScanSpec withRequestMetricCollector(RequestMetricCollector requestMetricCollector)
-
withExpressionSpec
@Beta public ScanSpec withExpressionSpec(ScanExpressionSpec xspec)
Convenient method to specify expressions (and the associated name map and value map) viaScanExpressionSpec
.
-
getMaxResultSize
public Integer getMaxResultSize()
The maximum number of resources to be retrieved in this query, including all the resources in all pages to be retrieved.
-
setMaxResultSize
public void setMaxResultSize(Integer maxResultSize)
-
setMaxResultSize
public void setMaxResultSize(int maxResultSize)
-
getMaxPageSize
public Integer getMaxPageSize()
The maximum number of resources to be retrieved in a single page; used for pagination purposes.
-
setMaxPageSize
public void setMaxPageSize(Integer value)
-
getRequest
public T getRequest()
Internal method. Not meant to be called directly. May change without notice.
-
getProgressListener
public ProgressListener getProgressListener()
-
setProgressListener
public void setProgressListener(ProgressListener progressListener)
-
getRequestMetricCollector
public RequestMetricCollector getRequestMetricCollector()
-
setRequestMetricCollector
public void setRequestMetricCollector(RequestMetricCollector requestMetricCollector)
-
-