public final class CheckedThrowing extends Object
| 限定符和类型 | 类和说明 |
|---|---|
static interface |
CheckedThrowing.ThrowingCallable<R,T extends Throwable>
Lambda function checked exception
|
static interface |
CheckedThrowing.ThrowingComparator<E,T extends Throwable> |
static interface |
CheckedThrowing.ThrowingConsumer<E,T extends Throwable>
Lambda function checked exception
|
static interface |
CheckedThrowing.ThrowingFunction<E,R,T extends Throwable>
Lambda function checked exception
|
static interface |
CheckedThrowing.ThrowingRunnable<T extends Throwable> |
static interface |
CheckedThrowing.ThrowingSupplier<R,T extends Throwable>
Lambda function checked exception
|
| 构造器和说明 |
|---|
CheckedThrowing() |
| 限定符和类型 | 方法和说明 |
|---|---|
static <R,T extends Throwable> |
callable(CheckedThrowing.ThrowingCallable<R,T> callable) |
static <E,T extends Throwable> |
comparator(CheckedThrowing.ThrowingComparator<E,T> comparator) |
static <E,T extends Throwable> |
consumer(CheckedThrowing.ThrowingConsumer<E,T> consumer) |
static <E,R,T extends Throwable> |
function(CheckedThrowing.ThrowingFunction<E,R,T> function) |
static <T extends Throwable> |
runnable(CheckedThrowing.ThrowingRunnable<T> runnable)
eg: new Thread(CheckedThrowing.runnable(printer::print))
|
static <R,T extends Throwable> |
supplier(CheckedThrowing.ThrowingSupplier<R,T> supplier) |
public static <T extends Throwable> Runnable runnable(CheckedThrowing.ThrowingRunnable<T> runnable)
T - the type of Throwablerunnable - the ThrowingRunnablepublic static <R,T extends Throwable> Callable<R> callable(CheckedThrowing.ThrowingCallable<R,T> callable)
public static <E,T extends Throwable> Consumer<E> consumer(CheckedThrowing.ThrowingConsumer<E,T> consumer)
public static <E,R,T extends Throwable> Function<E,R> function(CheckedThrowing.ThrowingFunction<E,R,T> function)
public static <R,T extends Throwable> Supplier<R> supplier(CheckedThrowing.ThrowingSupplier<R,T> supplier)
public static <E,T extends Throwable> Comparator<? super E> comparator(CheckedThrowing.ThrowingComparator<E,T> comparator)
Copyright © 2023. All rights reserved.