startWith

fun <T> Flow<T>.startWith(item: T): Flow<T>(source)

Returns a Flow that emits a specified item before it begins to emit items emitted by the current Flow.


fun <T> Flow<T>.startWith(itemFactory: suspend () -> T): Flow<T>(source)

Returns a Flow that emits a specified item before it begins to emit items emitted by the current Flow. itemFactory will be called on the collection for each new FlowCollector.


fun <T> Flow<T>.startWith(item1: T, item2: T): Flow<T>(source)
fun <T> Flow<T>.startWith(item1: T, item2: T, item3: T): Flow<T>(source)
fun <T> Flow<T>.startWith(item1: T, item2: T, item3: T, item4: T): Flow<T>(source)
fun <T> Flow<T>.startWith(item1: T, item2: T, item3: T, item4: T, item5: T): Flow<T>(source)
fun <T> Flow<T>.startWith(item: T, vararg items: T): Flow<T>(source)
fun <T> Flow<T>.startWith(others: Iterable<T>): Flow<T>(source)
fun <T> Flow<T>.startWith(others: Sequence<T>): Flow<T>(source)

Returns a Flow that emits the specified items before it begins to emit items emitted by the current Flow.


fun <T> Flow<T>.startWith(other: Flow<T>): Flow<T>(source)

Returns a Flow that emits the items in a specified Flow before it begins to emit items emitted by the current Flow.