public class ExceptionTools extends Object
| Constructor and Description |
|---|
ExceptionTools() |
| Modifier and Type | Method and Description |
|---|---|
static IOException |
createIOException(String message,
Throwable cause)
Deprecated.
Java 6 has suitable constructor and we don't support Java 5 anymore.
|
static <T extends Throwable> |
createWithCause(Class<T> clazz,
Throwable t) |
static void |
fail()
Simply fail with a
RuntimeException. |
static <T> T |
futureSimpleGet(Future<T> future) |
static <T extends Number> |
futureSimpleGetNumber(Future<T> future) |
static <T extends Throwable> |
getInChain(Throwable t,
Class<T> clazz) |
static Throwable |
getRoot(Throwable t)
The root cause of
t. |
static String |
getStackTraceString(Throwable t) |
static boolean |
isInChain(Throwable t,
Class<?> clazz) |
static boolean |
isKnownReason(Throwable t) |
static boolean |
isTimeout(Throwable t) |
@Deprecated public static IOException createIOException(String message, Throwable cause)
public static void fail()
RuntimeException.public static <T> T futureSimpleGet(Future<T> future)
public static Throwable getRoot(Throwable t)
t.t - A Throwable.t.public static boolean isKnownReason(Throwable t)
public static boolean isTimeout(Throwable t)
Copyright © 2013 intarsys consulting GmbH. All Rights Reserved.