Interface QueryResponse.Builder
- All Superinterfaces:
AwsResponse.Builder,Buildable,CopyableBuilder<QueryResponse.Builder,,QueryResponse> DynamoDbResponse.Builder,SdkBuilder<QueryResponse.Builder,,QueryResponse> SdkPojo,SdkResponse.Builder
- Enclosing class:
QueryResponse
-
Method Summary
Modifier and TypeMethodDescriptiondefault QueryResponse.BuilderconsumedCapacity(Consumer<ConsumedCapacity.Builder> consumedCapacity) The capacity units consumed by theQueryoperation.consumedCapacity(ConsumedCapacity consumedCapacity) The capacity units consumed by theQueryoperation.The number of items in the response.items(Collection<? extends Map<String, AttributeValue>> items) An array of item attributes that match the query criteria.items(Map<String, AttributeValue>... items) An array of item attributes that match the query criteria.lastEvaluatedKey(Map<String, AttributeValue> lastEvaluatedKey) The primary key of the item where the operation stopped, inclusive of the previous result set.scannedCount(Integer scannedCount) The number of items evaluated, before anyQueryFilteris applied.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copyMethods inherited from interface software.amazon.awssdk.services.dynamodb.model.DynamoDbResponse.Builder
build, responseMetadata, responseMetadataMethods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, buildMethods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFieldsMethods inherited from interface software.amazon.awssdk.core.SdkResponse.Builder
sdkHttpResponse, sdkHttpResponse
-
Method Details
-
items
An array of item attributes that match the query criteria. Each element in this array consists of an attribute name and the value for that attribute.
- Parameters:
items- An array of item attributes that match the query criteria. Each element in this array consists of an attribute name and the value for that attribute.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
items
An array of item attributes that match the query criteria. Each element in this array consists of an attribute name and the value for that attribute.
- Parameters:
items- An array of item attributes that match the query criteria. Each element in this array consists of an attribute name and the value for that attribute.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
count
The number of items in the response.
If you used a
QueryFilterin the request, thenCountis the number of items returned after the filter was applied, andScannedCountis the number of matching items before the filter was applied.If you did not use a filter in the request, then
CountandScannedCountare the same.- Parameters:
count- The number of items in the response.If you used a
QueryFilterin the request, thenCountis the number of items returned after the filter was applied, andScannedCountis the number of matching items before the filter was applied.If you did not use a filter in the request, then
CountandScannedCountare the same.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
scannedCount
The number of items evaluated, before any
QueryFilteris applied. A highScannedCountvalue with few, or no,Countresults indicates an inefficientQueryoperation. For more information, see Count and ScannedCount in the Amazon DynamoDB Developer Guide.If you did not use a filter in the request, then
ScannedCountis the same asCount.- Parameters:
scannedCount- The number of items evaluated, before anyQueryFilteris applied. A highScannedCountvalue with few, or no,Countresults indicates an inefficientQueryoperation. For more information, see Count and ScannedCount in the Amazon DynamoDB Developer Guide.If you did not use a filter in the request, then
ScannedCountis the same asCount.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
lastEvaluatedKey
The primary key of the item where the operation stopped, inclusive of the previous result set. Use this value to start a new operation, excluding this value in the new request.
If
LastEvaluatedKeyis empty, then the "last page" of results has been processed and there is no more data to be retrieved.If
LastEvaluatedKeyis not empty, it does not necessarily mean that there is more data in the result set. The only way to know when you have reached the end of the result set is whenLastEvaluatedKeyis empty.- Parameters:
lastEvaluatedKey- The primary key of the item where the operation stopped, inclusive of the previous result set. Use this value to start a new operation, excluding this value in the new request.If
LastEvaluatedKeyis empty, then the "last page" of results has been processed and there is no more data to be retrieved.If
LastEvaluatedKeyis not empty, it does not necessarily mean that there is more data in the result set. The only way to know when you have reached the end of the result set is whenLastEvaluatedKeyis empty.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
consumedCapacity
The capacity units consumed by the
Queryoperation. The data returned includes the total provisioned throughput consumed, along with statistics for the table and any indexes involved in the operation.ConsumedCapacityis only returned if theReturnConsumedCapacityparameter was specified. For more information, see Capacity unit consumption for read operations in the Amazon DynamoDB Developer Guide.- Parameters:
consumedCapacity- The capacity units consumed by theQueryoperation. The data returned includes the total provisioned throughput consumed, along with statistics for the table and any indexes involved in the operation.ConsumedCapacityis only returned if theReturnConsumedCapacityparameter was specified. For more information, see Capacity unit consumption for read operations in the Amazon DynamoDB Developer Guide.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
consumedCapacity
The capacity units consumed by the
This is a convenience method that creates an instance of theQueryoperation. The data returned includes the total provisioned throughput consumed, along with statistics for the table and any indexes involved in the operation.ConsumedCapacityis only returned if theReturnConsumedCapacityparameter was specified. For more information, see Capacity unit consumption for read operations in the Amazon DynamoDB Developer Guide.ConsumedCapacity.Builderavoiding the need to create one manually viaConsumedCapacity.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed toconsumedCapacity(ConsumedCapacity).- Parameters:
consumedCapacity- a consumer that will call methods onConsumedCapacity.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-