reactor-core / reactor.core.publisher / org.reactivestreams.Publisher / toMono

toMono

fun <T> Publisher<T>.toMono(): Mono<T>

Extension to convert any Publisher of T to a Mono that only emits its first element.

Note this extension doesn't make much sense on a Mono but it won't be converted so it doesn't hurt.

Author
Simon Baslé

Since
3.1.1