google_cloud_firestore library

Classes

AggregateField
AggregateQuery
AggregateQuerySnapshot
The results of executing an aggregation query.
average
Create an object that can be used to compute the average of a specified field over a range of documents in the result set of a query.
BulkWriter
A Firestore BulkWriter that can be used to perform a large number of writes in parallel.
BulkWriterOptions
Options to configure BulkWriter behavior.
BulkWriterThrottling
Base class for throttling configuration.
BundleBuilder
Builds a Firestore data bundle with results from the given document and query snapshots.
CollectionGroup<T>
CollectionReference<T>
count
Create a CountAggregateField object that can be used to compute the count of documents in the result set of a query.
Credential
Base class for Firestore credentials.
DisabledThrottling
Throttling is completely disabled (unlimited ops/sec).
DocumentChange<T>
A DocumentChange represents a change to the documents matching a query. It contains the document affected and the type of change that occurred.
DocumentReference<T>
DocumentReferencePage<T>
A page of document references returned by CollectionReference.listDocumentsPages.
DocumentSnapshot<T>
A DocumentSnapshot is an immutable representation for a document in a Firestore database. The data can be extracted with data.
EnabledThrottling
Throttling is enabled with configurable rate limits.
ExecutionStats
ExecutionStats contains information about the execution of a query.
ExplainMetrics
ExplainMetrics contains information about planning and execution of a query.
ExplainOptions
Options to use when explaining a query.
ExplainResults<T>
ExplainResults contains information about planning, execution, and results of a query.
ExplainStats
Statistics about how the backend planned and executed a Pipeline.
Expression
FlutterFire-style entry points for building Pipeline expressions.
FieldMask
FieldPath
FieldValue
Filter
A Filter represents a restriction on one or more field values and can be used to refine the results of a Query. Filterss are created by invoking Filter.where, Filter.or, or Filter.and and can then be passed to Query.where. to create a new Query instance that also contains this Filter.
Firestore
The Cloud Firestore service interface.
GeoPoint
An immutable object representing a geographic location in Firestore. The location is represented as a latitude/longitude pair.
Pipeline
A Firestore Pipeline operation.
PipelineAliasedExpression
A Pipeline expression with an alias.
PipelineBooleanExpression
A Pipeline boolean expression.
PipelineExplainOptions
Asks the backend for statistics about how it plans and runs a Pipeline.
PipelineExpression
Base class for Firestore Pipeline expressions.
PipelineField
A Pipeline field reference.
PipelineFunctions
Convenience wrappers for the Firestore Pipeline function catalog.
PipelineOrdering
A Pipeline ordering.
PipelineResult
A Pipeline execution result.
PipelineSnapshot
A snapshot returned by executing a Firestore Pipeline operation.
PipelineSource
The starting point for constructing Firestore Pipeline operations.
PlanSummary
PlanSummary contains information about the planning stage of a query.
Precondition
A condition to check before performing an operation.
Query<T>
QueryDocumentSnapshot<T>
QueryPartition<T extends Object?>
A split point that can be used in a query as a starting and/or end point for the query results.
QuerySnapshot<T>
ReadOnlyTransactionOptions
Options for read-only transactions.
ReadOptions
ReadWriteTransactionOptions
Options for read-write transactions.
SetOptions
Options to configure WriteBatch.set, Transaction.set, and BulkWriter.set behavior.
Settings
Settings used to configure a Firestore instance.
sum
Create an object that can be used to compute the sum of a specified field over a range of documents in the result set of a query.
Timestamp
A Timestamp represents a point in time independent of any time zone or calendar, represented as seconds and fractions of seconds at nanosecond resolution in UTC Epoch time. It is encoded using the Proleptic Gregorian Calendar which extends the Gregorian calendar backwards to year one. It is encoded assuming all minutes are 60 seconds long, i.e. leap seconds are "smeared" so that no leap second table is needed for interpretation. Range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By restricting to that range, we ensure that we can convert to and from RFC 3339 date strings.
Transaction
A reference to a transaction.
TransactionOptions
Options for configuring transactions.
VectorQuery<T>
A query that finds the documents whose vector fields are closest to a certain query vector.
VectorQueryOptions
Options that configure the behavior of a vector query created by Query.findNearest.
VectorQuerySnapshot<T>
A VectorQuerySnapshot contains zero or more QueryDocumentSnapshot objects representing the results of a vector query. The documents can be accessed as a list via the docs property. The number of documents can be determined via the empty and size properties.
VectorValue
Represents a vector value in Firestore.
WriteBatch
A Firestore WriteBatch that can be used to atomically commit multiple write operations at once.
WriteResult
A WriteResult wraps the write time set by the Firestore servers on sets(), updates(), and creates().

Enums

DistanceMeasure
Distance measures for vector queries.
DocumentChangeType
FirestoreClientErrorCode
Firestore client error codes and their default messages.
PipelineExplainMode
Whether the backend should return planning stats alongside the results.
PipelineExplainOutputFormat
The format the backend encodes explain stats in.
PipelineIndexMode
How the backend should choose indexes when executing a Pipeline.
PipelineValueType
Firestore Pipeline backend value types used with PipelineExpression.isType.
StatusCode
Status codes for Firestore operations.
WhereFilter

Functions

and(Iterable<PipelineBooleanExpression> expressions) → PipelineBooleanExpression
Creates a logical AND expression; same as PipelineFunctions.and.
ascending(Object expression) → PipelineOrdering
Creates an ascending Pipeline ordering.
constant(Object? value) → PipelineExpression
Creates a constant expression for Firestore Pipeline operations.
currentDocument() → PipelineExpression
Returns the current document as a Pipeline expression.
descending(Object expression) → PipelineOrdering
Creates a descending Pipeline ordering.
documentMatches(Object? rquery) → PipelineBooleanExpression
Creates an expression matching documents against the query string rquery.
equal(Object? left, Object? right) → PipelineBooleanExpression
Creates an equality expression; same as PipelineFunctions.equal.
field(Object fieldPath) → PipelineField
Creates a field reference expression for Firestore Pipeline operations.
greaterThan(Object? left, Object? right) → PipelineBooleanExpression
Creates a greater-than expression; same as PipelineFunctions.greaterThan.
greaterThanOrEqual(Object? left, Object? right) → PipelineBooleanExpression
Creates a greater-than-or-equal expression; same as PipelineFunctions.greaterThanOrEqual.
lessThan(Object? left, Object? right) → PipelineBooleanExpression
Creates a less-than expression; same as PipelineFunctions.lessThan.
lessThanOrEqual(Object? left, Object? right) → PipelineBooleanExpression
Creates a less-than-or-equal expression; same as PipelineFunctions.lessThanOrEqual.
not(PipelineBooleanExpression expression) → PipelineBooleanExpression
Creates a logical NOT expression; same as PipelineFunctions.not.
notEqual(Object? left, Object? right) → PipelineBooleanExpression
Creates a not-equal expression; same as PipelineFunctions.notEqual.
or(Iterable<PipelineBooleanExpression> expressions) → PipelineBooleanExpression
Creates a logical OR expression; same as PipelineFunctions.or.
pipelineFunction(String name, Iterable<Object?> args, {Map<String, Object?> options = const {}}) → PipelineExpression
Creates a raw Pipeline function expression.
score() → PipelineExpression
Returns the relevance score assigned by a preceding search stage.
variable(String name) → PipelineExpression
Creates a variable reference expression for Firestore Pipeline operations.

Typedefs

AliasedExpression = PipelineAliasedExpression
FlutterFire-style alias for PipelineAliasedExpression.
BooleanExpression = PipelineBooleanExpression
FlutterFire-style alias for PipelineBooleanExpression.
DocumentData = Map<String, Object?>
A map of string keys to dynamic values representing Firestore document data.
Ordering = PipelineOrdering
FlutterFire-style alias for PipelineOrdering.
PipelineAggregateFunction = PipelineExpression
FlutterFire-style alias for aggregate function expressions.
Selectable = PipelineExpression
FlutterFire-style alias for expressions that can be selected.
TransactionHandler<T> = Future<T> Function(Transaction transaction)
The TransactionHandler may be executed multiple times; it should be able to handle multiple executions.

Exceptions / Errors

BulkWriterError
The error thrown when a BulkWriter operation fails.
FirestoreException
Exception thrown by Firestore operations.