public class Java9BackportUtils
extends java.lang.Object
Constructor and Description |
---|
Java9BackportUtils() |
Modifier and Type | Method and Description |
---|---|
static <T,U,A,R> java.util.stream.Collector<T,?,R> |
flatMapping(java.util.function.Function<? super T,? extends java.util.stream.Stream<? extends U>> mapper,
java.util.stream.Collector<? super U,A,R> downstream) |
static <T> void |
ifPresentOrElse(java.util.Optional<T> optional,
java.util.function.Consumer<? super T> action,
java.lang.Runnable emptyAction) |
public static <T,U,A,R> java.util.stream.Collector<T,?,R> flatMapping(java.util.function.Function<? super T,? extends java.util.stream.Stream<? extends U>> mapper, java.util.stream.Collector<? super U,A,R> downstream)
public static <T> void ifPresentOrElse(java.util.Optional<T> optional, java.util.function.Consumer<? super T> action, java.lang.Runnable emptyAction)