//Extensions for Jetpack Lifecycle/it.czerwinski.android.lifecycle.livedata/intervalLiveData
intervalLiveData
[androidJvm]
Content
fun intervalLiveData(timeInMillis: Long, context: CoroutineContext = EmptyCoroutineContext): LiveData<Int>
More info
Returns a LiveData emitting a sequence of integer values, spaced by a given timeInMillis.
Delay between subsequent emissions will be applied on a thread determined by the given context.
Example:
val intervalLiveData: LiveData
Since
1.2.0
[androidJvm]
Content
fun intervalLiveData(context: CoroutineContext = EmptyCoroutineContext, timeInMillis: (Int) -> Long): LiveData<Int>
More info
Returns a LiveData emitting a sequence of integer values, spaced by a result of a given timeInMillis function invoked on the next value.
Delay between subsequent emissions will be applied on a thread determined by the given context.
Example:
val intervalLiveData: LiveData
Since
1.2.0