FirebaseDatabase

actual class FirebaseDatabase(source)
expect class FirebaseDatabase(source)

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

actual class FirebaseDatabase(source)
actual class FirebaseDatabase(source)
actual class FirebaseDatabase(source)

Types

Link copied to clipboard
object Companion
object Companion

Properties

Link copied to clipboard
val FirebaseDatabase.android: FirebaseDatabase
val FirebaseDatabase.android: FirebaseDatabase
Link copied to clipboard
val FirebaseDatabase.ios: FIRDatabase
Link copied to clipboard
val FirebaseDatabase.js: Database

Functions

Link copied to clipboard
actual fun goOffline()
expect fun goOffline()

Shuts down our connection to the Firebase Database backend until goOnline is called.

actual fun goOffline()
actual fun goOffline()
actual fun goOffline()
Link copied to clipboard
actual fun goOnline()
expect fun goOnline()

Resumes our connection to the Firebase Database backend after a previous goOffline. call.

actual fun goOnline()
actual fun goOnline()
actual fun goOnline()
Link copied to clipboard

Gets a DatabaseReference for the database root node.

Gets a DatabaseReference for the provided path.

Link copied to clipboard
actual fun setLoggingEnabled(enabled: Boolean)
expect fun setLoggingEnabled(enabled: Boolean)
actual fun setLoggingEnabled(enabled: Boolean)
actual fun setLoggingEnabled(enabled: Boolean)
actual fun setLoggingEnabled(enabled: Boolean)
Link copied to clipboard
actual fun setPersistenceCacheSizeBytes(cacheSizeInBytes: Long)
expect fun setPersistenceCacheSizeBytes(cacheSizeInBytes: Long)

By default Firebase Database will use up to 10MB of disk space to cache data. If the cache grows beyond this size, Firebase Database will start removing data that hasn't been recently used. If you find that your application caches too little or too much data, call this method to change the cache size. This method must be called before creating your first Database reference and only needs to be called once per application.

actual fun setPersistenceCacheSizeBytes(cacheSizeInBytes: Long)
actual fun setPersistenceCacheSizeBytes(cacheSizeInBytes: Long)
actual fun setPersistenceCacheSizeBytes(cacheSizeInBytes: Long)
Link copied to clipboard
actual fun setPersistenceEnabled(enabled: Boolean)
expect fun setPersistenceEnabled(enabled: Boolean)

The Firebase Database client will cache synchronized data and keep track of all writes you've initiated while your application is running. It seamlessly handles intermittent network connections and re-sends write operations when the network connection is restored.

actual fun setPersistenceEnabled(enabled: Boolean)
actual fun setPersistenceEnabled(enabled: Boolean)
actual fun setPersistenceEnabled(enabled: Boolean)
Link copied to clipboard
actual fun useEmulator(host: String, port: Int)
expect fun useEmulator(host: String, port: Int)

Modifies this FirebaseDatabase instance to communicate with the Realtime Database emulator.

actual fun useEmulator(host: String, port: Int)
actual fun useEmulator(host: String, port: Int)
actual fun useEmulator(host: String, port: Int)