DistinctFlow

interface DistinctFlow<out TResult : Any> : Flow<TResult>

Flow for distinct.

Since

3.0

Parameters

The type of the result.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
abstract fun batchSize(batchSize: Int): DistinctFlow<TResult>

Sets the number of documents to return per batch.

Link copied to clipboard
abstract fun collation(collation: Collation?): DistinctFlow<TResult>

Sets the collation options

Link copied to clipboard
abstract suspend fun collect(collector: FlowCollector<TResult>)
Link copied to clipboard
abstract fun filter(filter: Bson?): DistinctFlow<TResult>

Sets the query filter to apply to the query.

Link copied to clipboard
abstract suspend fun firstOrNull(): TResult?

Helper to return first result.

Link copied to clipboard
abstract fun maxTime(maxTime: Long, timeUnit: TimeUnit): DistinctFlow<TResult>

Sets the maximum execution time on the server for this operation.