max

fun <T : Comparable<T>> Flux<T>.max(): Mono<T>

Extension to find the highest value in a Flux of Comparable values and return it as a Mono of T.

Author

Simon Baslé

Since

1.0.0


fun <T> Flux<T>.max(comp: Comparator<T>): Mono<T>

Extension to find the highest value in a Flux and return it as a Mono. The highest value is defined by comparisons made using a provided Comparator.

Author

Simon Baslé

Since

1.0.0

Parameters

comp

The Comparator to use


fun <T> Flux<T>.max(comp: (T, T) -> Int): Mono<T>

Extension to find the highest value in a Flux and return it as a Mono. The highest value is defined by comparisons made using a provided function that behaves like a Comparator.

Author

Simon Baslé

Since

1.0.0

Parameters

comp

The comparison function to use (similar to a Comparator)