You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// TODO Coroutines variant of [RowsFetchSpec.all], depends on [kotlinx.coroutines#254](https://github.com/Kotlin/kotlinx.coroutines/issues/254).
54
-
// suspend fun <T> RowsFetchSpec<T>.awaitAll() = all()...
56
+
/**
57
+
* Coroutines [Flow] variant of [RowsFetchSpec.all].
58
+
*
59
+
* Backpressure is controlled by [batchSize] parameter that controls the size of in-flight elements
60
+
* and [org.reactivestreams.Subscription.request] size.
61
+
*
62
+
* @author Sebastien Deleuze
63
+
*/
64
+
@FlowPreview
65
+
fun <T:Any> RowsFetchSpec<T>.flow(batchSize:Int = 1): Flow<T> = all().asFlow(batchSize)
0 commit comments