public abstract class Exceptions extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
Exceptions.Action |
Constructor and Description |
---|
Exceptions() |
Modifier and Type | Method and Description |
---|---|
static <E extends Throwable> |
rethrow(Exceptions.Action action,
Function<Throwable,E> mapper) |
static <T> T |
safe(Callable<T> supplier,
Callable<T> otherwise) |
static boolean |
safe(Exceptions.Action action) |
static <T> T |
silent(Callable<T> supplier,
Callable<T> otherwise) |
static <T> T |
sneakyThrows(Callable<T> supplier) |
public static <T> T sneakyThrows(Callable<T> supplier)
public static boolean safe(Exceptions.Action action)
public static <E extends Throwable> void rethrow(Exceptions.Action action, Function<Throwable,E> mapper) throws E extends Throwable
E extends Throwable
Copyright © 2023 Suncode. All rights reserved.