public final class RemoteExceptionCause
extends java.lang.Throwable
| Constructor and Description |
|---|
RemoteExceptionCause(java.lang.String msg,
RemoteExceptionCause cause,
java.lang.String exceptionClassName)
Constructs a new
RemoteExceptionCause instance with an initial message and cause. |
RemoteExceptionCause(java.lang.String msg,
RemoteExceptionCause cause,
java.lang.String exceptionClassName,
java.util.Map<java.lang.String,java.lang.String> fields)
Constructs a new
RemoteExceptionCause instance with an initial message and cause. |
RemoteExceptionCause(java.lang.String msg,
java.lang.String exceptionClassName)
Constructs a new
RemoteExceptionCause instance with an initial message. |
RemoteExceptionCause(java.lang.String msg,
java.lang.String exceptionClassName,
java.util.Map<java.lang.String,java.lang.String> fields)
Constructs a new
RemoteExceptionCause instance with an initial message. |
| Modifier and Type | Method and Description |
|---|---|
RemoteExceptionCause |
getCause() |
java.lang.String |
getExceptionClassName()
Get the original exception class name.
|
java.util.Set<java.lang.String> |
getFieldNames()
Get the field names of the remote exception.
|
java.lang.String |
getFieldValue(java.lang.String fieldName)
Get the string value of the given field name.
|
static RemoteExceptionCause |
of(java.lang.Throwable t)
Get a remote exception cause for the given
Throwable. |
static RemoteExceptionCause |
readFromStream(java.io.DataInput input) |
java.lang.Throwable |
toPlainThrowable()
Convert this remote exception cause to a plain throwable for sending to peers which use serialization and do not
have this class present.
|
java.lang.String |
toString()
Get a string representation of this exception.
|
void |
writeToStream(java.io.DataOutput output)
Write this remote exception cause to the given stream, without using serialization.
|
public RemoteExceptionCause(java.lang.String msg,
java.lang.String exceptionClassName)
RemoteExceptionCause instance with an initial message. No
cause is specified.msg - the messageexceptionClassName - the name of the exception's class (must not be null)public RemoteExceptionCause(java.lang.String msg,
RemoteExceptionCause cause,
java.lang.String exceptionClassName)
RemoteExceptionCause instance with an initial message and cause.msg - the messagecause - the causeexceptionClassName - the name of the exception's class (must not be null)public RemoteExceptionCause(java.lang.String msg,
java.lang.String exceptionClassName,
java.util.Map<java.lang.String,java.lang.String> fields)
RemoteExceptionCause instance with an initial message. No
cause is specified.msg - the messageexceptionClassName - the name of the exception's class (must not be null)fields - the public fields of the remote exception (must not be null)public RemoteExceptionCause(java.lang.String msg,
RemoteExceptionCause cause,
java.lang.String exceptionClassName,
java.util.Map<java.lang.String,java.lang.String> fields)
RemoteExceptionCause instance with an initial message and cause.msg - the messagecause - the causeexceptionClassName - the name of the exception's class (must not be null)fields - the public fields of the remote exception (must not be null)public static RemoteExceptionCause of(java.lang.Throwable t)
Throwable. All of the cause and suppressed exceptions will
also be converted.t - the throwable, or nullnull if null was passed inpublic java.lang.Throwable toPlainThrowable()
null)public java.lang.String getExceptionClassName()
null)public java.util.Set<java.lang.String> getFieldNames()
public java.lang.String getFieldValue(java.lang.String fieldName)
fieldName - the name of the field (must not be null)public java.lang.String toString()
toString in class java.lang.Throwablepublic void writeToStream(java.io.DataOutput output)
throws java.io.IOException
output - the output stream (must not be null)java.io.IOException - if an error occurs writing the datapublic static RemoteExceptionCause readFromStream(java.io.DataInput input) throws java.io.IOException
java.io.IOExceptionpublic RemoteExceptionCause getCause()
getCause in class java.lang.ThrowableCopyright © 2015 JBoss, a division of Red Hat, Inc.