|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.logging.log4j.core.util.Throwables
public final class Throwables
Helps with Throwable objects.
Method Summary | |
---|---|
static void |
addSuppressed(Throwable throwable,
Throwable suppressedThrowable)
Deprecated. If compiling on Java 7 and above use Throwable#addSuppressed(Throwable) . Marked as deprecated because Java 6 is
deprecated. |
static Throwable[] |
getSuppressed(Throwable throwable)
Deprecated. If compiling on Java 7 and above use Throwable#getSuppressed() . Marked as deprecated because Java 6 is
deprecated. |
static boolean |
isGetSuppressedAvailable()
Returns true if the getSuppressed method is available. |
static void |
rethrow(Throwable t)
Rethrows a Throwable , wrapping checked exceptions into an UndeclaredThrowableException . |
static List<String> |
toStringList(Throwable throwable)
Converts a Throwable stack trace into a List of Strings |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
@Deprecated public static void addSuppressed(Throwable throwable, Throwable suppressedThrowable)
Throwable#addSuppressed(Throwable)
. Marked as deprecated because Java 6 is
deprecated.
throwable
- a ThrowablesuppressedThrowable
- a suppressed ThrowableThrowable#addSuppressed(Throwable)
@Deprecated public static Throwable[] getSuppressed(Throwable throwable)
Throwable#getSuppressed()
. Marked as deprecated because Java 6 is
deprecated.
throwable
- a Throwable
Throwable#getSuppressed()
Throwable#getSuppressed()
public static boolean isGetSuppressedAvailable()
public static List<String> toStringList(Throwable throwable)
throwable
- the Throwable
public static void rethrow(Throwable t)
Throwable
, wrapping checked exceptions into an UndeclaredThrowableException
.
t
- the Throwable to throw.
RuntimeException
- if t
is a RuntimeException
Error
- if t
is an Error
UndeclaredThrowableException
- if t
is a checked Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 1999-2015 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.