public class UnexpectedException extends FatalException
Wraps an unexpected exception as a fatal exception.
Modifier | Constructor and Description |
---|---|
|
UnexpectedException()
Default constructor.
|
protected |
UnexpectedException(java.lang.String message,
java.lang.Throwable cause) |
Modifier and Type | Method and Description |
---|---|
static UnexpectedException |
withCause(java.lang.RuntimeException cause)
Return a new exception with the specified root cause.
|
static UnexpectedException |
withMessage(java.lang.String message)
Return a new exception with the specified message text.
|
getCause, getMessage, setCause, setMessage, toString
protected UnexpectedException(java.lang.String message, java.lang.Throwable cause)
public UnexpectedException()
Default constructor.
public static UnexpectedException withCause(java.lang.RuntimeException cause)
Return a new exception with the specified root cause.
cause
- Root cause.public static UnexpectedException withMessage(java.lang.String message)
Return a new exception with the specified message text.
message
- Message text.