static <T> Multi<T> |
Multi.concat(Multi<T> firstMulti,
Multi<T> secondMulti) |
Concat streams to one.
|
default Multi<T> |
Multi.defaultIfEmpty(T defaultItem) |
Signals the default item if the upstream is empty.
|
static <T> Multi<T> |
Multi.defer(Supplier<? extends Flow.Publisher<? extends T>> supplier) |
Call the given supplier function for each individual downstream Subscriber
to return a Flow.Publisher to subscribe to.
|
default Multi<T> |
Multi.distinct() |
Filter out all duplicates.
|
default Multi<T> |
Multi.dropWhile(Predicate<? super T> predicate) |
Drop the longest prefix of elements from this stream that satisfy the given predicate.
|
static <T> Multi<T> |
Multi.empty() |
Get a Multi instance that completes immediately.
|
static <T> Multi<T> |
Multi.error(Throwable error) |
Create a Multi instance that reports the given exception to its subscriber(s).
|
default Multi<T> |
Multi.filter(Predicate<T> predicate) |
Filter stream items with provided predicate.
|
default <U> Multi<U> |
Multi.flatMap(Function<T,Flow.Publisher<U>> publisherMapper) |
Transform item with supplied function and flatten resulting Flow.Publisher to downstream.
|
default <U> Multi<U> |
Multi.flatMap(Function<T,Flow.Publisher<U>> mapper,
long maxConcurrency,
boolean delayErrors,
long prefetch) |
Transform item with supplied function and flatten resulting Flow.Publisher to downstream
while limiting the maximum number of concurrent inner Flow.Publishers and their in-flight
item count, optionally aggregating and delaying all errors until all sources terminate.
|
default <U> Multi<U> |
Single.flatMap(Function<? super T,? extends Flow.Publisher<? extends U>> mapper) |
Map this Single instance to a publisher using the given Mapper.
|
default <U> Multi<U> |
Multi.flatMapIterable(Function<? super T,? extends Iterable<? extends U>> iterableMapper) |
Transform item with supplied function and flatten resulting Iterable to downstream.
|
default <U> Multi<U> |
Multi.flatMapIterable(Function<? super T,? extends Iterable<? extends U>> iterableMapper,
int prefetch) |
Transform item with supplied function and flatten resulting Iterable to downstream.
|
default <U> Multi<U> |
Single.flatMapIterable(Function<? super T,? extends Iterable<? extends U>> mapper) |
Maps the single upstream value into an Iterable and relays its
items to the downstream.
|
static <T> Multi<T> |
Multi.from(Iterable<T> iterable) |
Create a Multi instance that publishes the given iterable.
|
static <T> Multi<T> |
Multi.from(Flow.Publisher<T> source) |
Create a Multi instance wrapped around the given publisher.
|
static <T> Multi<T> |
Multi.from(Stream<T> stream) |
Create a Multi instance that publishes the given Stream.
|
static Multi<Long> |
Multi.interval(long initialDelay,
long period,
TimeUnit unit,
ScheduledExecutorService executor) |
Signal 0L after an initial delay, then 1L, 2L and so on periodically to the downstream.
|
static Multi<Long> |
Multi.interval(long period,
TimeUnit unit,
ScheduledExecutorService executor) |
Signal 0L, 1L and so on periodically to the downstream.
|
static <T> Multi<T> |
Multi.just(Collection<T> items) |
Create a Multi instance that publishes the given items to a single subscriber.
|
static <T> Multi<T> |
Multi.just(T... items) |
Create a Multi instance that publishes the given items to a single subscriber.
|
default Multi<T> |
Multi.limit(long limit) |
Limit stream to allow only specified number of items to pass.
|
default <U> Multi<U> |
Multi.map(Mapper<T,U> mapper) |
|
default <U> Multi<U> |
Single.mapMany(Mapper<T,Flow.Publisher<U>> mapper) |
Deprecated.
|
static <T> Multi<T> |
Multi.never() |
Get a Multi instance that never completes.
|
default Multi<T> |
Multi.onComplete(Runnable onTerminate) |
Executes given Runnable when onComplete signal is received.
|
default Multi<T> |
Multi.onError(Consumer<Throwable> onErrorConsumer) |
Executes given Runnable when onError signal is received.
|
default Multi<T> |
Multi.onErrorResume(Function<? super Throwable,? extends T> onError) |
Function providing one item to be submitted as onNext in case of onError signal is received.
|
default Multi<T> |
Multi.onErrorResumeWith(Function<? super Throwable,? extends Flow.Publisher<? extends T>> onError) |
Resume stream from supplied publisher if onError signal is intercepted.
|
default Multi<T> |
Multi.onTerminate(Runnable onTerminate) |
Executes given Runnable when any of signals onComplete, onCancel or onError is received.
|
default Multi<T> |
Multi.peek(Consumer<T> consumer) |
Invoke provided consumer for every item in stream.
|
static Multi<Integer> |
Multi.range(int start,
int count) |
Emits a range of ever increasing integers.
|
static Multi<Long> |
Multi.rangeLong(long start,
long count) |
Emits a range of ever increasing longs.
|
static <T> Multi<T> |
Multi.singleton(T item) |
Create a Multi that emits a pre-existing item and then completes.
|
default Multi<T> |
Multi.skip(long skip) |
Skip first n items, all the others are emitted.
|
default Multi<T> |
Multi.switchIfEmpty(Flow.Publisher<T> other) |
Switch to the other publisher if the upstream is empty.
|
default <U> Multi<T> |
Multi.takeUntil(Flow.Publisher<U> other) |
Relay upstream items until the other source signals an item or completes.
|
default Multi<T> |
Multi.takeWhile(Predicate<T> predicate) |
Take the longest prefix of elements from this stream that satisfy the given predicate.
|
static Multi<Long> |
Multi.timer(long time,
TimeUnit unit,
ScheduledExecutorService executor) |
Signal 0L and complete the sequence after the given time elapsed.
|