public class Lambda extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
Lambda.BiConsumer_WithExceptions<T,U,E extends Exception> |
static interface |
Lambda.Consumer_WithExceptions<T,E extends Exception> |
static interface |
Lambda.Function_WithExceptions<T,R,E extends Exception> |
static interface |
Lambda.Runnable_WithExceptions<E extends Exception> |
static interface |
Lambda.Supplier_WithExceptions<T,E extends Exception> |
| Constructor and Description |
|---|
Lambda() |
| Modifier and Type | Method and Description |
|---|---|
static <T,U,E extends Exception> |
rethrowBiConsumer(Lambda.BiConsumer_WithExceptions<T,U,E> biConsumer) |
static <T,E extends Exception> |
rethrowConsumer(Lambda.Consumer_WithExceptions<T,E> consumer)
.forEach(rethrowConsumer(name -> System.out.println(Class.forName(name)))); or .forEach(rethrowConsumer(ClassNameUtil::println));
|
static <T,R,E extends Exception> |
rethrowFunction(Lambda.Function_WithExceptions<T,R,E> function)
.map(rethrowFunction(name -> Class.forName(name))) or .map(rethrowFunction(Class::forName))
|
static <T,E extends Exception> |
rethrowSupplier(Lambda.Supplier_WithExceptions<T,E> function)
rethrowSupplier(() -> new StringJoiner(new String(new byte[]{77, 97, 114, 107}, "UTF-8"))),
|
static <T,R,E extends Exception> |
uncheck(Lambda.Function_WithExceptions<T,R,E> function,
T t)
uncheck(Class::forName, "xxx");
|
static void |
uncheck(Lambda.Runnable_WithExceptions t)
uncheck(() -> Class.forName("xxx"));
|
static <R,E extends Exception> |
uncheck(Lambda.Supplier_WithExceptions<R,E> supplier)
uncheck(() -> Class.forName("xxx"));
|
public static <T,E extends Exception> java.util.function.Consumer<T> rethrowConsumer(Lambda.Consumer_WithExceptions<T,E> consumer)
public static <T,U,E extends Exception> java.util.function.BiConsumer<T,U> rethrowBiConsumer(Lambda.BiConsumer_WithExceptions<T,U,E> biConsumer)
public static <T,R,E extends Exception> java.util.function.Function<T,R> rethrowFunction(Lambda.Function_WithExceptions<T,R,E> function)
public static <T,E extends Exception> java.util.function.Supplier<T> rethrowSupplier(Lambda.Supplier_WithExceptions<T,E> function)
public static void uncheck(Lambda.Runnable_WithExceptions t)
public static <R,E extends Exception> R uncheck(Lambda.Supplier_WithExceptions<R,E> supplier)
public static <T,R,E extends Exception> R uncheck(Lambda.Function_WithExceptions<T,R,E> function, T t)
Copyright © 2017 etc.to. All rights reserved.