//Extensions for Jetpack Lifecycle/it.czerwinski.android.lifecycle.livedata/ConstantLiveData

ConstantLiveData

[androidJvm] class ConstantLiveData<T>(value: T) : LiveData<T>

LiveData that always emits a single constant value.

Constructors

   
ConstantLiveData [androidJvm] fun <T> ConstantLiveData(value: T)

Functions

Name Summary
changeActiveCounter [androidJvm]
Content
@MainThread()

open fun changeActiveCounter(p0: Int)


dispatchingValue [androidJvm]
Content
open fun dispatchingValue(@Nullable()p0: LiveData.ObserverWrapper<T>?)


getValue [androidJvm]
Content
@Nullable()

open fun getValue(): T?


getVersion [androidJvm]
Content
open fun getVersion(): Int


hasActiveObservers [androidJvm]
Content
open fun hasActiveObservers(): Boolean


hasObservers [androidJvm]
Content
open fun hasObservers(): Boolean


observe [androidJvm]
Content
@MainThread()

open fun observe(@NonNull()p0: LifecycleOwner, @NonNull()p1: Observer<in T>)


observeForever [androidJvm]
Content
@MainThread()

open fun observeForever(@NonNull()p0: Observer<in T>)


onActive [androidJvm]
Content
open fun onActive()


onInactive [androidJvm]
Content
open fun onInactive()


postValue [androidJvm]
Content
open fun postValue(p0: T)


removeObserver [androidJvm]
Content
@MainThread()

open fun removeObserver(@NonNull()p0: Observer<in T>)


removeObservers [androidJvm]
Content
@MainThread()

open fun removeObservers(@NonNull()p0: LifecycleOwner)


setValue [androidJvm]
Content
@MainThread()

open fun setValue(p0: T)


Properties

Name Summary
mActiveCount [androidJvm] val mActiveCount: Int
mDataLock [androidJvm] val mDataLock: Any
mPendingData [androidJvm] val mPendingData: Any