Package | Description |
---|---|
com.google.cloud.firestore |
Modifier and Type | Class and Description |
---|---|
class |
CollectionGroup
A Collection Group query matches all documents that are contained in a collection or
subcollection with a specific collection ID.
|
class |
CollectionReference
A CollectionReference can be used for adding documents, getting document references, and querying
for documents (using the methods inherited from Query).
|
Modifier and Type | Method and Description |
---|---|
Query |
QueryPartition.createQuery()
Returns a query that only returns the documents for this partition.
|
Query |
Query.endAt(DocumentSnapshot snapshot)
Creates and returns a new Query that ends at the provided document (inclusive).
|
Query |
Query.endAt(Object... fieldValues)
Creates and returns a new Query that ends at the provided fields relative to the order of the
query.
|
Query |
Query.endBefore(DocumentSnapshot snapshot)
Creates and returns a new Query that ends before the provided document (exclusive).
|
Query |
Query.endBefore(Object... fieldValues)
Creates and returns a new Query that ends before the provided fields relative to the order of
the query.
|
static Query |
Query.fromProto(Firestore firestore,
RunQueryRequest proto)
Returns a Query instance that can be used to execute the provided
RunQueryRequest . |
Query |
AggregateQuery.getQuery()
Returns the query whose aggregations will be calculated by this object.
|
Query |
QuerySnapshot.getQuery()
Returns the query for the snapshot.
|
Query |
Query.limit(int limit)
Creates and returns a new Query that only returns the first matching documents.
|
Query |
Query.limitToLast(int limit)
Creates and returns a new Query that only returns the last matching documents.
|
Query |
Query.offset(int offset)
Creates and returns a new Query that skips the first n results.
|
Query |
Query.orderBy(FieldPath fieldPath)
Creates and returns a new Query that's additionally sorted by the specified field.
|
Query |
Query.orderBy(FieldPath fieldPath,
Query.Direction direction)
Creates and returns a new Query that's additionally sorted by the specified field, optionally
in descending order instead of ascending.
|
Query |
Query.orderBy(String field)
Creates and returns a new Query that's additionally sorted by the specified field.
|
Query |
Query.orderBy(String field,
Query.Direction direction)
Creates and returns a new Query that's additionally sorted by the specified field, optionally
in descending order instead of ascending.
|
Query |
Query.select(FieldPath... fieldPaths)
Creates and returns a new Query instance that applies a field mask to the result and returns
the specified subset of fields.
|
Query |
Query.select(String... fields)
Creates and returns a new Query instance that applies a field mask to the result and returns
the specified subset of fields.
|
Query |
Query.startAfter(DocumentSnapshot snapshot)
Creates and returns a new Query that starts after the provided document (exclusive).
|
Query |
Query.startAfter(Object... fieldValues)
Creates and returns a new Query that starts after the provided fields relative to the order of
the query.
|
Query |
Query.startAt(DocumentSnapshot snapshot)
Creates and returns a new Query that starts at the provided document (inclusive).
|
Query |
Query.startAt(Object... fieldValues)
Creates and returns a new Query that starts at the provided fields relative to the order of the
query.
|
Query |
Query.where(Filter filter)
Creates and returns a new Query with the additional filter.
|
Query |
Query.whereArrayContains(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field, the value must be an array, and that the array must contain the provided
value.
|
Query |
Query.whereArrayContains(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field, the value must be an array, and that the array must contain the provided
value.
|
Query |
Query.whereArrayContainsAny(FieldPath fieldPath,
List<? extends Object> values)
Creates and returns a new Query with the additional filter that documents must contain the
specified field, the value must be an array, and that the array must contain at least one value
from the provided list.
|
Query |
Query.whereArrayContainsAny(String field,
List<? extends Object> values)
Creates and returns a new Query with the additional filter that documents must contain the
specified field, the value must be an array, and that the array must contain at least one value
from the provided list.
|
Query |
Query.whereEqualTo(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be equal to the specified value.
|
Query |
Query.whereEqualTo(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be equal to the specified value.
|
Query |
Query.whereGreaterThan(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be greater than the specified value.
|
Query |
Query.whereGreaterThan(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be greater than the specified value.
|
Query |
Query.whereGreaterThanOrEqualTo(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be greater than or equal to the specified value.
|
Query |
Query.whereGreaterThanOrEqualTo(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be greater than or equal to the specified value.
|
Query |
Query.whereIn(FieldPath fieldPath,
List<? extends Object> values)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value must equal one of the values from the provided list.
|
Query |
Query.whereIn(String field,
List<? extends Object> values)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value must equal one of the values from the provided list.
|
Query |
Query.whereLessThan(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be less than the specified value.
|
Query |
Query.whereLessThan(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be less than the specified value.
|
Query |
Query.whereLessThanOrEqualTo(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be less or equal to the specified value.
|
Query |
Query.whereLessThanOrEqualTo(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value should be less or equal to the specified value.
|
Query |
Query.whereNotEqualTo(FieldPath fieldPath,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value does not equal the specified value.
|
Query |
Query.whereNotEqualTo(String field,
Object value)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and its value does not equal the specified value.
|
Query |
Query.whereNotIn(FieldPath fieldPath,
List<? extends Object> values)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value does not equal any of the values from the provided list.
|
Query |
Query.whereNotIn(String field,
List<? extends Object> values)
Creates and returns a new Query with the additional filter that documents must contain the
specified field and the value does not equal any of the values from the provided list.
|
Modifier and Type | Method and Description |
---|---|
com.google.api.core.ApiFuture<QuerySnapshot> |
Transaction.get(Query query)
Returns the result set from the provided query.
|
static QuerySnapshot |
QuerySnapshot.withChanges(Query query,
com.google.cloud.Timestamp readTime,
com.google.cloud.firestore.DocumentSet documentSet,
List<DocumentChange> documentChanges)
Creates a new QuerySnapshot representing a snapshot of a Query with changed documents.
|
static QuerySnapshot |
QuerySnapshot.withDocuments(Query query,
com.google.cloud.Timestamp readTime,
List<QueryDocumentSnapshot> documents)
Creates a new QuerySnapshot representing the results of a Query with added documents.
|
Constructor and Description |
---|
QueryPartition(Query query,
Object[] startAt,
Object[] endBefore) |
QuerySnapshot(Query query,
com.google.cloud.Timestamp readTime) |
Copyright © 2023 Google LLC. All rights reserved.