Class: FirebaseDatabaseClient

FirebaseDatabaseClient(databasenon-null)

The client of a Firebase Realtime database.

Constructor

new FirebaseDatabaseClient(databasenon-null)

Creates a new FirebaseDatabaseClient.
Parameters:
Name Type Description
database firebase.database.Database a database of the initialized Firebase application
Source:

Classes

FirebaseDatabaseClient

Methods

getValues(pathnon-null, dataCallbacknon-null)

Gets an array of values from Firebase at the provided path.
Parameters:
Name Type Description
path string the path to the node to get value from
dataCallback consumerCallback.<Array.<Object>> a callback which is invoked with an array of entities at path
Source:

onChildAdded(pathnon-null, dataSubjectnon-null) → {Subscription}

Subscribes to the `child_added` events of the node under the given path. Each child's value is parsed as a JSON and dispatched to the given callback
Parameters:
Name Type Description
path string the path to the watched node
dataSubject Subject.<Object> the subject receiving child values
Source:
Returns:
a Subscription that can be unsubscribed
Type
Subscription

onChildChanged(pathnon-null, dataSubjectnon-null) → {Subscription}

Subscribes to the `child_changed` events of the node under the given path. Each child's value is parsed as a JSON and dispatched to the given callback
Parameters:
Name Type Description
path string the path to the watched node
dataSubject Subject.<Object> the subject receiving child values
Source:
Returns:
a Subscription that can be unsubscribed
Type
Subscription

onChildRemoved(pathnon-null, dataSubjectnon-null) → {Subscription}

Subscribes to the `child_removed` events of the node under the given path. Each child's value is parsed as a JSON and dispatched to the given callback
Parameters:
Name Type Description
path string the path to the watched node
dataSubject Subject.<Object> the subject receiving child values
Source:
Returns:
a Subscription that can be unsubscribed
Type
Subscription