QuerySnapshot
A QuerySnapshot
contains zero or more DocumentSnapshot
objects
representing the results of a query. The documents can be accessed as an
array via the docs
property or enumerated using the forEach
method. The
number of documents can be determined via the empty
and size
properties.
§Type Parameters
§Properties
An array of all the documents in the QuerySnapshot
.
Metadata about this snapshot, concerning its source and if it has local modifications.
§Methods
Returns an array of the documents changes since the last snapshot. If this is the first snapshot, all documents will be in the list as 'added' changes.
SnapshotListenOptions
that control whether metadata-only changes (i.e. onlyDocumentSnapshot.metadata
changed) should trigger snapshot events.
Enumerates all of the documents in the QuerySnapshot
.
- A callback to be called with a
QueryDocumentSnapshot
for each document in the snapshot.
- The
this
binding for the callback.
Returns a JSON-serializable representation of this QuerySnapshot
instance.
a JSON representation of this object. Throws a FirestoreError if this
QuerySnapshot
has pending writes.