Ir a la consola

FirebaseDatabase

public class FirebaseDatabase extends Object

The entry point for accessing a Firebase Database. You can get an instance by calling getInstance(). To access a location in the database and read or write data, use getReference().

Public Method Summary

FirebaseApp
getApp()
Returns the FirebaseApp instance to which this FirebaseDatabase belongs.
static FirebaseDatabase
getInstance(String url)
Gets a FirebaseDatabase instance for the specified URL.
static FirebaseDatabase
getInstance()
Gets the default FirebaseDatabase instance.
static FirebaseDatabase
getInstance(FirebaseApp app)
Gets an instance of FirebaseDatabase for a specific FirebaseApp.
synchronized static FirebaseDatabase
getInstance(FirebaseApp app, String url)
Gets a FirebaseDatabase instance for the specified URL, using the specified FirebaseApp.
DatabaseReference
getReference()
Gets a DatabaseReference for the database root node.
DatabaseReference
getReference(String path)
Gets a DatabaseReference for the provided path.
DatabaseReference
getReferenceFromUrl(String url)
Gets a DatabaseReference for the provided URL.
static String
void
goOffline()
Shuts down our connection to the Firebase Database backend until goOnline() is called.
void
goOnline()
Resumes our connection to the Firebase Database backend after a previous goOffline() call.
void
purgeOutstandingWrites()
The Firebase Database client automatically queues writes and sends them to the server at the earliest opportunity, depending on network connectivity.
synchronized void
setLogLevel(Logger.Level logLevel)
By default, this is set to INFO.
synchronized void
setPersistenceCacheSizeBytes(long cacheSizeInBytes)
By default Firebase Database will use up to 10MB of disk space to cache data.
synchronized void
setPersistenceEnabled(boolean isEnabled)
The Firebase Database client will cache synchronized data and keep track of all writes you've initiated while your application is running.

Inherited Method Summary