cloud_firestore library
Classes
- AggregateField
- AggregateOptions
- Options for aggregate operations
- AggregateQuery
- AggregateQuery represents the data at a particular location for retrieving metadata without retrieving the actual documents.
- AggregateQuerySnapshot
- AggregateQuerySnapshot represents a response to an AggregateQuery request.
- AggregateStageOptions
- Represents an aggregate stage with functions and optional grouping
- AliasedAggregateFunction
- Represents an aggregate function with an alias
- AliasedExpression
- Represents an aliased expression wrapper
- ArrayAgg
- Aggregate that collects all values of expression into an array.
- ArrayAggDistinct
- Aggregate that collects distinct values of expression into an array.
- Average
- Calculates average of numeric values of the specified expression
- 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.
- Blob
- Represents binary data stored in Uint8List.
- BooleanExpression
- Base class for boolean expressions used in filtering
-
CollectionReference<
T extends Object?> - Concat
- Represents a concatenation function expression
- Constant
- Represents a constant value in a pipeline expression
- Count
- Counts non-null values of the specified expression
- count
- Create a CountAggregateField object that can be used to compute the count of documents in the result set of a query.
- CountAll
- Counts all documents in the pipeline result
- CountDistinct
- Counts distinct values of the specified expression
-
DocumentChange<
T extends Object?> - A DocumentChange represents a change to the documents matching a query.
-
DocumentReference<
T extends Object?> - A DocumentReference refers to a document location in a FirebaseFirestore database and can be used to write, read, or listen to the location.
-
DocumentSnapshot<
T extends Object?> - A DocumentSnapshot contains data read from a document in your FirebaseFirestore database.
- ExecuteOptions
- Options for executing a pipeline
- Expression
- Base class for all pipeline expressions
- Field
- Represents a field reference in a pipeline expression
- FieldOverrideIndex
- FieldOverrides
- The FieldOverrides class follows the FieldOverrides definition.
- FieldPath
- A FieldPath refers to a field in a document.
- FieldValue
- Sentinel values that can be used when writing document fields with set() or update().
- Filter
- A Filter represents a restriction on one or more field values and can be used to refine the results of a Query.
- FirebaseFirestore
- The entry point for accessing a FirebaseFirestore.
- First
- Aggregate that picks the first value of expression across pipeline inputs.
- FunctionExpression
- Base class for function expressions
- GeoPoint
- Represents a geographical point by its longitude and latitude
- GetOptions
- An options class that configures the behavior of get() calls on DocumentReference and Query.
- Index
- The Index class follows the Index definition.
- IndexField
- Last
- Aggregate that picks the last value of expression across pipeline inputs.
-
ListEquality<
E> - Equality on lists.
- LoadBundleTask
- LoadBundleTaskSnapshot
- A LoadBundleTaskSnapshot is returned as the result or on-going process of a LoadBundleTask.
- Maximum
- Finds maximum value of the specified expression
- Minimum
- Finds minimum value of the specified expression
- Ordering
- Represents an ordering specification for pipeline sorting
- PersistenceSettings
- A settings class that can be passed to Firestore.enablePersistence() to configure Firestore persistence. Only supported for Web.
- PersistentCacheIndexManager
- Pipeline
- A pipeline for querying and transforming Firestore data.
- PipelineAggregateFunction
- Base class for aggregate functions used in pipelines
- PipelineResult
- Represents the results of a Pipeline query, including the data and metadata.
- PipelineSample
- Base class for pipeline sampling strategies
- PipelineSnapshot
- A PipelineSnapshot contains the results of a pipeline execution. It can be iterated to retrieve the individual PipelineResult objects.
- PipelineSource
- Provides methods to create pipelines from different sources
- PipelineStage
- Base sealed class for all pipeline stages
-
Query<
T extends Object?> - Represents a Query over the data at a particular location.
-
QueryDocumentSnapshot<
T extends Object?> - A QueryDocumentSnapshot contains data read from a document in your FirebaseFirestore database as part of a query.
-
QuerySnapshot<
T extends Object?> - Contains the results of a query. It can contain zero or more DocumentSnapshot objects.
- SearchStage
- Specifies how a pipeline search stage is performed.
- Selectable
- Base class for selectable expressions (can be used in select stage)
- SetOptions
- An options class that configures the behavior of set() calls in DocumentReference, WriteBatch and Transaction.
- Settings
- Specifies custom configurations for your Cloud Firestore instance.
- SnapshotMetadata
- Metadata about a snapshot, describing the state of the snapshot.
- SnapshotOptions
- Options that configure how data is retrieved from a DocumentSnapshot (e.g. the desired behavior for server timestamps that have not yet been set to their final value).
- Sum
- Sums numeric values of the specified expression
- 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
-
Transaction class which is created from a call to
runTransaction(). - VectorValue
- Represents a vector value by an array of doubles.
- WebExperimentalLongPollingOptions
- Options that configure the SDK’s underlying network transport (WebChannel) when long-polling is used.
- WebPersistentMultipleTabManager
- Enables multi-tab synchronization for Firestore’s persistent cache.
- WebPersistentSingleTabManager
- Configures the Firestore SDK to operate in single-tab mode.
- WebPersistentTabManager
- Configures how multiple browser tabs are managed by the Firestore SDK when using persistent cache on web.
- WriteBatch
- A WriteBatch is a series of write operations to be performed as one unit.
Enums
- AggregateSource
-
AggregateSource represents the source of data for an
AggregateQuery. - ArrayConfig
- DistanceMeasure
- Distance measure algorithms for vector similarity search
- DocumentChangeType
- An enumeration of document change types.
- IndexMode
- Index mode for pipeline execution
- ListenSource
- The listener retrieves data and listens to updates from the local Firestore cache only. If the cache is empty, an empty snapshot will be returned. Snapshot events will be triggered on cache updates, like local mutations or load bundles.
- LoadBundleTaskState
- Represents the state of an on-going LoadBundleTask.
- Order
- OrderDirection
- Direction for ordering results
- QueryScope
- ServerTimestampBehavior
- Source
- An enumeration of firestore source types.
- Type
- Value types for Expression.isType and Expression.isTypeStatic.
Mixins
- PipelineSerializable
- Base interface for pipeline serialization
Functions
-
convertNum(
num input) → num
Typedefs
-
FromFirestore<
T> = T Function(DocumentSnapshot< Map< snapshot, SnapshotOptions? options)String, dynamic> > -
ToFirestore<
T> = Map< String, Object?> Function(T value, SetOptions? options) -
TransactionHandler<
T> = Future< T> Function(Transaction transaction) - The TransactionHandler may be executed multiple times; it should be able to handle multiple executions.
Exceptions / Errors
- FirebaseException
- A generic class which provides exceptions in a Firebase-friendly format to users.