public final class MathFlux
extends java.lang.Object
Comparable
values or using custom @link Comparator
.Constructor and Description |
---|
MathFlux() |
Modifier and Type | Method and Description |
---|---|
static reactor.core.publisher.Mono<java.lang.Double> |
averageDouble(Publisher<? extends java.lang.Number> source)
Computes the double average of items in the source.
|
static <T> reactor.core.publisher.Mono<java.lang.Double> |
averageDouble(Publisher<T> source,
java.util.function.Function<? super T,? extends java.lang.Number> mapping)
Computes the double average of items in the source, which are mapped to numerical values
using the provided mapping.
|
static reactor.core.publisher.Mono<java.lang.Float> |
averageFloat(Publisher<? extends java.lang.Number> source)
Computes the float average of items in the source.
|
static <T> reactor.core.publisher.Mono<java.lang.Float> |
averageFloat(Publisher<T> source,
java.util.function.Function<? super T,? extends java.lang.Number> mapping)
Computes the float average of items in the source, which are mapped to numerical values
using the provided mapping.
|
static <T extends java.lang.Comparable<? super T>> |
max(Publisher<T> source)
Computes the maximum value of items in the source.
|
static <T> reactor.core.publisher.Mono<T> |
max(Publisher<T> source,
java.util.Comparator<? super T> comparator)
Computes the maximum value of items in the source.
|
static <T extends java.lang.Comparable<? super T>> |
min(Publisher<T> source)
Computes the minimum value of items in the source.
|
static <T> reactor.core.publisher.Mono<T> |
min(Publisher<T> source,
java.util.Comparator<? super T> comparator)
Computes the minimum value of items in the source.
|
static reactor.core.publisher.Mono<java.lang.Double> |
sumDouble(Publisher<? extends java.lang.Number> source)
Computes the double sum of items in the source.
|
static <T> reactor.core.publisher.Mono<java.lang.Double> |
sumDouble(Publisher<T> source,
java.util.function.Function<? super T,? extends java.lang.Number> mapping)
Computes the double sum of items in the source, which are mapped to numerical values
using the provided mapping.
|
static reactor.core.publisher.Mono<java.lang.Float> |
sumFloat(Publisher<? extends java.lang.Number> source)
Computes the float sum of items in the source.
|
static <T> reactor.core.publisher.Mono<java.lang.Float> |
sumFloat(Publisher<T> source,
java.util.function.Function<? super T,? extends java.lang.Number> mapping)
Computes the float sum of items in the source, which are mapped to numerical values
using the provided mapping.
|
static reactor.core.publisher.Mono<java.lang.Integer> |
sumInt(Publisher<? extends java.lang.Number> source)
Computes the integer sum of items in the source.
|
static <T> reactor.core.publisher.Mono<java.lang.Integer> |
sumInt(Publisher<T> source,
java.util.function.Function<? super T,? extends java.lang.Number> mapping)
Computes the integer sum of items in the source, which are mapped to numerical values
using the provided mapping.
|
static reactor.core.publisher.Mono<java.lang.Long> |
sumLong(Publisher<? extends java.lang.Number> source)
Computes the long sum of items in the source.
|
static <T> reactor.core.publisher.Mono<java.lang.Long> |
sumLong(Publisher<T> source,
java.util.function.Function<? super T,? extends java.lang.Number> mapping)
Computes the long sum of items in the source, which are mapped to numerical values
using the provided mapping.
|
public static reactor.core.publisher.Mono<java.lang.Integer> sumInt(Publisher<? extends java.lang.Number> source)
source
- the numerical sourceMono
of the sum of items in sourcepublic static final <T> reactor.core.publisher.Mono<java.lang.Integer> sumInt(Publisher<T> source, java.util.function.Function<? super T,? extends java.lang.Number> mapping)
source
- the source itemsmapping
- a function to map source items to numerical valuesMono
of the sum of items in sourcepublic static reactor.core.publisher.Mono<java.lang.Long> sumLong(Publisher<? extends java.lang.Number> source)
source
- the numerical sourceMono
of the sum of items in sourcepublic static final <T> reactor.core.publisher.Mono<java.lang.Long> sumLong(Publisher<T> source, java.util.function.Function<? super T,? extends java.lang.Number> mapping)
source
- the source itemsmapping
- a function to map source items to numerical valuesMono
of the sum of items in sourcepublic static reactor.core.publisher.Mono<java.lang.Float> sumFloat(Publisher<? extends java.lang.Number> source)
source
- the numerical sourceMono
of the sum of items in sourcepublic static final <T> reactor.core.publisher.Mono<java.lang.Float> sumFloat(Publisher<T> source, java.util.function.Function<? super T,? extends java.lang.Number> mapping)
source
- the source itemsmapping
- a function to map source items to numerical valuesMono
of the sum of items in sourcepublic static reactor.core.publisher.Mono<java.lang.Double> sumDouble(Publisher<? extends java.lang.Number> source)
source
- the numerical sourceMono
of the sum of items in sourcepublic static final <T> reactor.core.publisher.Mono<java.lang.Double> sumDouble(Publisher<T> source, java.util.function.Function<? super T,? extends java.lang.Number> mapping)
source
- the source itemsmapping
- a function to map source items to numerical valuesMono
of the sum of items in sourcepublic static reactor.core.publisher.Mono<java.lang.Float> averageFloat(Publisher<? extends java.lang.Number> source)
source
- the numerical sourceMono
of the average of items in sourcepublic static final <T> reactor.core.publisher.Mono<java.lang.Float> averageFloat(Publisher<T> source, java.util.function.Function<? super T,? extends java.lang.Number> mapping)
source
- the source itemsmapping
- a function to map source items to numerical valuesMono
of the average of items in sourcepublic static reactor.core.publisher.Mono<java.lang.Double> averageDouble(Publisher<? extends java.lang.Number> source)
source
- the numerical sourceMono
of the average of items in sourcepublic static final <T> reactor.core.publisher.Mono<java.lang.Double> averageDouble(Publisher<T> source, java.util.function.Function<? super T,? extends java.lang.Number> mapping)
source
- the source itemsmapping
- a function to map source items to numerical valuesMono
of the average of items in sourcepublic static final <T extends java.lang.Comparable<? super T>> reactor.core.publisher.Mono<T> max(Publisher<T> source)
source
- the source containing comparable itemsMono
of the maximum value in sourcepublic static <T> reactor.core.publisher.Mono<T> max(Publisher<T> source, java.util.Comparator<? super T> comparator)
source
- the source containing items to comparecomparator
- the comparator used to compare the items in sourceMono
of the maximum value in sourcepublic static final <T extends java.lang.Comparable<? super T>> reactor.core.publisher.Mono<T> min(Publisher<T> source)
source
- the source containing comparable itemsMono
of the minimum value in sourcepublic static <T> reactor.core.publisher.Mono<T> min(Publisher<T> source, java.util.Comparator<? super T> comparator)
source
- the source containing items to comparecomparator
- the comparator used to compare the items in sourceMono
of the minimum value in source