JavaFlow

object JavaFlow

Compatibility class to use Kotlin Coroutine Flow in Java files.

Types

Link copied to clipboard
fun interface CompletionCallback
Link copied to clipboard
class FlowJob(job: Job)
Link copied to clipboard
fun interface ResultCallback<T>
Link copied to clipboard
fun interface StartCallback

Functions

Link copied to clipboard
fun <T> collect(flow: Flow<T>, startCallback: JavaFlow.StartCallback? = null, resultCallback: JavaFlow.ResultCallback<T>, completeCallback: JavaFlow.CompletionCallback? = null, coroutineScope: CoroutineScope = CoroutineScope(Dispatchers.Default)): JavaFlow.FlowJob

Collect all entries in a given Flow.