MutableAccessibleLiveData

Mutable LiveData with the current (possible not yet published) value. You can observe changes like with regular MutableLiveData, just not inherited. You can write from any thread the value it will be posted on the main thread and published there when called from a background thread.

Please be aware that an RuntimeException will be thrown when you access value without setting a value ether with the setter or the constructor.

You can directly compare the value with the LiveData's value directly as syntactic sugar.

Constructors

Link copied to clipboard
constructor()
constructor(initialValue: T)

Properties

Link copied to clipboard
@get:JvmName(name = "getLatestValue")
@set:JvmName(name = "setLatestValue")
open override var value: T

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun getValue(): T
Link copied to clipboard
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open fun hasObservers(): Boolean
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun setValue(value: T)