QueryDocumentSnapshot<T extends dynamic> class
A QueryDocumentSnapshot contains the data of a document that exists: one read by a query, or handed to a converter. Its data is never null.
- Inheritance
-
- Object
- DocumentSnapshot<
T> - QueryDocumentSnapshot
Properties
- exists → bool
-
Whether the document exists.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
The ID of the document.
no setterinherited
-
reference
→ DocumentReference<
T> -
The reference of the document.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
contains(
Object field) → bool -
Whether the document has
field, also when its value is null.fieldis a String (dots separate nested fields) or a FieldPath.inherited -
data(
) → T -
The data of the document (converted with the converter of the reference
or query it was read through, if any), or null if the document does not
exist.
override
-
get(
Object field) → Object? -
The value of
field, or null if there is no such field or document. Never converted.inherited -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
-
operator [](
Object field) → Object? -
The value of
field, or null if there is no such field or document. Never converted. Same as get.inherited