Package | com.myflashlab.air.extensions.firebase.firestore |
Class | public class Firestore |
Inheritance | Firestore Object |
Property | Defined By | ||
---|---|---|---|
firestoreSettings : FirestoreSettings [static] [read-only]
Returns the settings used by this FirebaseFirestore object. | Firestore |
Method | Defined By | ||
---|---|---|---|
[static]
Creates a write batch, used for performing multiple writes as a single atomic operation. | Firestore | ||
cleanAllReferences():void [static]
Use this method to empty cache on query and document references. | Firestore | ||
clearPersistence($callback:Function):void [static]
Clears the persistent storage, including pending writes and cached documents. | Firestore | ||
collection($collectionPath:String):CollectionReference [static]
Gets a CollectionReference instance that refers to the collection at the specified path within the database. | Firestore | ||
collectionGroup(collectionId:String):Query [static]
Creates and returns a new { | Firestore | ||
[static]
Created a new Transaction instance. | Firestore | ||
disableNetwork($callback:Function):void [static]
Disables network access for this instance. | Firestore | ||
document($documentPath:String):DocumentReference [static]
Gets a 'DocumentReference' instance that refers to the document at the specified path within the database. | Firestore | ||
enableNetwork($callback:Function):void [static]
Re-enables network usage for this instance after a prior call to disableNetwork(). | Firestore | ||
init():void [static] Call this method prior to any other Firestore methods. | Firestore | ||
setServerTimestampBehavior($behavior:int):void [static] | Firestore |
Constant | Defined By | ||
---|---|---|---|
EXTENSION_ID : String = com.myflashlab.air.extensions.firebase.firestore [static] | Firestore | ||
VERSION : String = 9.9.0 [static] | Firestore |
firestoreSettings | property |
firestoreSettings:FirestoreSettings
[read-only] Returns the settings used by this FirebaseFirestore object.
public static function get firestoreSettings():FirestoreSettings
batch | () | method |
public static function batch():WriteBatch
Creates a write batch, used for performing multiple writes as a single atomic operation.
ReturnsWriteBatch — The created WriteBatch object.
|
cleanAllReferences | () | method |
public static function cleanAllReferences():void
Use this method to empty cache on query and document references. You must do this only when you do not have any listeners watching documents, collections or queries. After calling this method, you need to create new instances of collections, documents or queries and make sure you are no longer using the old instance.
clearPersistence | () | method |
public static function clearPersistence($callback:Function):void
Clears the persistent storage, including pending writes and cached documents.
Parameters
$callback:Function — Expects one param $error:Error
|
collection | () | method |
public static function collection($collectionPath:String):CollectionReference
Gets a CollectionReference instance that refers to the collection at the specified path within the database.
Parameters
$collectionPath:String — A slash-separated path to a collection.
|
CollectionReference — The CollectionReference instance.
|
collectionGroup | () | method |
public static function collectionGroup(collectionId:String):Query
Creates and returns a new {
Parameters
collectionId:String — Identifies the collections to query over. Every collection or subcollection
with this ID as the last segment of its path will be included. Cannot contain a slash.
|
Query — The created Query.
|
createTransaction | () | method |
public static function createTransaction():Transaction
Created a new Transaction instance. To start the transaction, you must call execute()
method on
the returned Transaction
instance.
Transaction — the newly created Transaction instance. If it returns null , it means that an older
transaction is already in process. Every transaction must be finished by calling abort or
keep
|
See also
disableNetwork | () | method |
public static function disableNetwork($callback:Function):void
Disables network access for this instance. While the network is disabled, any snapshot listeners or get() calls will return results from cache, and any write operations will be queued until network usage is re-enabled via a call to enableNetwork().
Parameters
$callback:Function — Expects one param $error:Error
|
document | () | method |
public static function document($documentPath:String):DocumentReference
Gets a 'DocumentReference' instance that refers to the document at the specified path within the database.
Parameters
$documentPath:String — A slash-separated path to a document.
|
DocumentReference — The DocumentReference instance.
|
enableNetwork | () | method |
public static function enableNetwork($callback:Function):void
Re-enables network usage for this instance after a prior call to disableNetwork().
Parameters
$callback:Function — Expects one param $error:Error
|
init | () | method |
public static function init():void
Call this method prior to any other Firestore methods.
setServerTimestampBehavior | () | method |
public static function setServerTimestampBehavior($behavior:int):void
Parameters
$behavior:int |
EXTENSION_ID | Constant |
public static const EXTENSION_ID:String = com.myflashlab.air.extensions.firebase.firestore
VERSION | Constant |
public static const VERSION:String = 9.9.0