Packagecom.myflashlab.air.extensions.firebase.firestore
Classpublic class DocumentSnapshot
InheritanceDocumentSnapshot Inheritance Object

A DocumentSnapshot contains data read from a document in your Firestore database. The data can be extracted with the data property.



Public Properties
 PropertyDefined By
  data : Object
[read-only] Returns the fields of the document as an Object which is Json validated.
DocumentSnapshot
  metadata : SnapshotMetadata
[read-only] The metadata for this document snapshot.
DocumentSnapshot
  reference : DocumentReference
[read-only] Gets the reference to the document.
DocumentSnapshot
  snapshotId : String
[read-only] The id of the document.
DocumentSnapshot
Public Constants
 ConstantDefined By
  ServerTimestampBehavior_ESTIMATE : int = 1
[static] Return local estimates for ServerTimestamps that have not yet been set to their final value.
DocumentSnapshot
  ServerTimestampBehavior_NONE : int = 0
[static] Return 'null' for ServerTimestamps that have not yet been set to their final value.
DocumentSnapshot
  ServerTimestampBehavior_PREVIOUS : int = 2
[static] Return the previous value for ServerTimestamps that have not yet been set to their final value.
DocumentSnapshot
Property Detail
dataproperty
data:Object  [read-only]

Returns the fields of the document as an Object which is Json validated.


Implementation
    public function get data():Object
metadataproperty 
metadata:SnapshotMetadata  [read-only]

The metadata for this document snapshot.


Implementation
    public function get metadata():SnapshotMetadata
referenceproperty 
reference:DocumentReference  [read-only]

Gets the reference to the document.


Implementation
    public function get reference():DocumentReference
snapshotIdproperty 
snapshotId:String  [read-only]

The id of the document.


Implementation
    public function get snapshotId():String
Constant Detail
ServerTimestampBehavior_ESTIMATEConstant
public static const ServerTimestampBehavior_ESTIMATE:int = 1

Return local estimates for ServerTimestamps that have not yet been set to their final value. This estimate will likely differ from the final value and may cause these pending values to change once the server result becomes available.

ServerTimestampBehavior_NONEConstant 
public static const ServerTimestampBehavior_NONE:int = 0

Return 'null' for ServerTimestamps that have not yet been set to their final value.

ServerTimestampBehavior_PREVIOUSConstant 
public static const ServerTimestampBehavior_PREVIOUS:int = 2

Return the previous value for ServerTimestamps that have not yet been set to their final value.