Class QueryResultBatch (2.17.2)

public final class QueryResultBatch extends GeneratedMessageV3 implements QueryResultBatchOrBuilder

A batch of results produced by a query.

Protobuf type google.datastore.v1.QueryResultBatch

Static Fields

END_CURSOR_FIELD_NUMBER

public static final int END_CURSOR_FIELD_NUMBER
Field Value
TypeDescription
int

ENTITY_RESULTS_FIELD_NUMBER

public static final int ENTITY_RESULTS_FIELD_NUMBER
Field Value
TypeDescription
int

ENTITY_RESULT_TYPE_FIELD_NUMBER

public static final int ENTITY_RESULT_TYPE_FIELD_NUMBER
Field Value
TypeDescription
int

MORE_RESULTS_FIELD_NUMBER

public static final int MORE_RESULTS_FIELD_NUMBER
Field Value
TypeDescription
int

READ_TIME_FIELD_NUMBER

public static final int READ_TIME_FIELD_NUMBER
Field Value
TypeDescription
int

SKIPPED_CURSOR_FIELD_NUMBER

public static final int SKIPPED_CURSOR_FIELD_NUMBER
Field Value
TypeDescription
int

SKIPPED_RESULTS_FIELD_NUMBER

public static final int SKIPPED_RESULTS_FIELD_NUMBER
Field Value
TypeDescription
int

SNAPSHOT_VERSION_FIELD_NUMBER

public static final int SNAPSHOT_VERSION_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static QueryResultBatch getDefaultInstance()
Returns
TypeDescription
QueryResultBatch

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static QueryResultBatch.Builder newBuilder()
Returns
TypeDescription
QueryResultBatch.Builder

newBuilder(QueryResultBatch prototype)

public static QueryResultBatch.Builder newBuilder(QueryResultBatch prototype)
Parameter
NameDescription
prototypeQueryResultBatch
Returns
TypeDescription
QueryResultBatch.Builder

parseDelimitedFrom(InputStream input)

public static QueryResultBatch parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static QueryResultBatch parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static QueryResultBatch parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static QueryResultBatch parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static QueryResultBatch parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static QueryResultBatch parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static QueryResultBatch parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static QueryResultBatch parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static QueryResultBatch parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static QueryResultBatch parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static QueryResultBatch parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static QueryResultBatch parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
QueryResultBatch
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<QueryResultBatch> parser()
Returns
TypeDescription
Parser<QueryResultBatch>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public QueryResultBatch getDefaultInstanceForType()
Returns
TypeDescription
QueryResultBatch

getEndCursor()

public ByteString getEndCursor()

A cursor that points to the position after the last result in the batch.

bytes end_cursor = 4;

Returns
TypeDescription
ByteString

The endCursor.

getEntityResultType()

public EntityResult.ResultType getEntityResultType()

The result type for every entity in entity_results.

.google.datastore.v1.EntityResult.ResultType entity_result_type = 1;

Returns
TypeDescription
EntityResult.ResultType

The entityResultType.

getEntityResultTypeValue()

public int getEntityResultTypeValue()

The result type for every entity in entity_results.

.google.datastore.v1.EntityResult.ResultType entity_result_type = 1;

Returns
TypeDescription
int

The enum numeric value on the wire for entityResultType.

getEntityResults(int index)

public EntityResult getEntityResults(int index)

The results for this batch.

repeated .google.datastore.v1.EntityResult entity_results = 2;

Parameter
NameDescription
indexint
Returns
TypeDescription
EntityResult

getEntityResultsCount()

public int getEntityResultsCount()

The results for this batch.

repeated .google.datastore.v1.EntityResult entity_results = 2;

Returns
TypeDescription
int

getEntityResultsList()

public List<EntityResult> getEntityResultsList()

The results for this batch.

repeated .google.datastore.v1.EntityResult entity_results = 2;

Returns
TypeDescription
List<EntityResult>

getEntityResultsOrBuilder(int index)

public EntityResultOrBuilder getEntityResultsOrBuilder(int index)

The results for this batch.

repeated .google.datastore.v1.EntityResult entity_results = 2;

Parameter
NameDescription
indexint
Returns
TypeDescription
EntityResultOrBuilder

getEntityResultsOrBuilderList()

public List<? extends EntityResultOrBuilder> getEntityResultsOrBuilderList()

The results for this batch.

repeated .google.datastore.v1.EntityResult entity_results = 2;

Returns
TypeDescription
List<? extends com.google.datastore.v1.EntityResultOrBuilder>

getMoreResults()

public QueryResultBatch.MoreResultsType getMoreResults()

The state of the query after the current batch.

.google.datastore.v1.QueryResultBatch.MoreResultsType more_results = 5;

Returns
TypeDescription
QueryResultBatch.MoreResultsType

The moreResults.

getMoreResultsValue()

public int getMoreResultsValue()

The state of the query after the current batch.

.google.datastore.v1.QueryResultBatch.MoreResultsType more_results = 5;

Returns
TypeDescription
int

The enum numeric value on the wire for moreResults.

getParserForType()

public Parser<QueryResultBatch> getParserForType()
Returns
TypeDescription
Parser<QueryResultBatch>
Overrides

getReadTime()

public Timestamp getReadTime()

Read timestamp this batch was returned from. This applies to the range of results from the query's start_cursor (or the beginning of the query if no cursor was given) to this batch's end_cursor (not the query's end_cursor).

In a single transaction, subsequent query result batches for the same query can have a greater timestamp. Each batch's read timestamp is valid for all preceding batches. This value will not be set for eventually consistent queries in Cloud Datastore.

.google.protobuf.Timestamp read_time = 8;

Returns
TypeDescription
Timestamp

The readTime.

getReadTimeOrBuilder()

public TimestampOrBuilder getReadTimeOrBuilder()

Read timestamp this batch was returned from. This applies to the range of results from the query's start_cursor (or the beginning of the query if no cursor was given) to this batch's end_cursor (not the query's end_cursor).

In a single transaction, subsequent query result batches for the same query can have a greater timestamp. Each batch's read timestamp is valid for all preceding batches. This value will not be set for eventually consistent queries in Cloud Datastore.

.google.protobuf.Timestamp read_time = 8;

Returns
TypeDescription
TimestampOrBuilder

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getSkippedCursor()

public ByteString getSkippedCursor()

A cursor that points to the position after the last skipped result. Will be set when skipped_results != 0.

bytes skipped_cursor = 3;

Returns
TypeDescription
ByteString

The skippedCursor.

getSkippedResults()

public int getSkippedResults()

The number of results skipped, typically because of an offset.

int32 skipped_results = 6;

Returns
TypeDescription
int

The skippedResults.

getSnapshotVersion()

public long getSnapshotVersion()

The version number of the snapshot this batch was returned from. This applies to the range of results from the query's start_cursor (or the beginning of the query if no cursor was given) to this batch's end_cursor (not the query's end_cursor).

In a single transaction, subsequent query result batches for the same query can have a greater snapshot version number. Each batch's snapshot version is valid for all preceding batches. The value will be zero for eventually consistent queries.

int64 snapshot_version = 7;

Returns
TypeDescription
long

The snapshotVersion.

hasReadTime()

public boolean hasReadTime()

Read timestamp this batch was returned from. This applies to the range of results from the query's start_cursor (or the beginning of the query if no cursor was given) to this batch's end_cursor (not the query's end_cursor).

In a single transaction, subsequent query result batches for the same query can have a greater timestamp. Each batch's read timestamp is valid for all preceding batches. This value will not be set for eventually consistent queries in Cloud Datastore.

.google.protobuf.Timestamp read_time = 8;

Returns
TypeDescription
boolean

Whether the readTime field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public QueryResultBatch.Builder newBuilderForType()
Returns
TypeDescription
QueryResultBatch.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected QueryResultBatch.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
QueryResultBatch.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public QueryResultBatch.Builder toBuilder()
Returns
TypeDescription
QueryResultBatch.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException