public class SerializedThrowable extends Exception implements Serializable
This exception mimics the original exception with respect to message and stack trace, and contains the original exception in serialized form. The original exception can be re-obtained by supplying the appropriate class loader.
Constructor and Description |
---|
SerializedThrowable(Throwable exception)
Create a new SerializedThrowable.
|
Modifier and Type | Method and Description |
---|---|
Throwable |
deserializeError(ClassLoader classloader) |
static Throwable |
get(Throwable serThrowable,
ClassLoader loader) |
String |
getFullStringifiedStackTrace() |
String |
getOriginalErrorClassName() |
byte[] |
getSerializedException() |
void |
printStackTrace(PrintStream s) |
void |
printStackTrace(PrintWriter s) |
String |
toString() |
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, setStackTrace
public SerializedThrowable(Throwable exception)
exception
- The exception to serialize.public Throwable deserializeError(ClassLoader classloader)
public String getOriginalErrorClassName()
public byte[] getSerializedException()
public String getFullStringifiedStackTrace()
public void printStackTrace(PrintStream s)
printStackTrace
in class Throwable
public void printStackTrace(PrintWriter s)
printStackTrace
in class Throwable
public static Throwable get(Throwable serThrowable, ClassLoader loader)
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.