public class GeneralException
extends java.lang.Exception
Constructor and Description |
---|
GeneralException()
Creates new
GeneralException without detail message. |
GeneralException(java.util.List<java.lang.String> messages) |
GeneralException(java.util.List<java.lang.String> messages,
java.lang.Throwable nested)
Constructs an
GeneralException with the specified detail message list and nested Exception. |
GeneralException(java.lang.String msg)
Constructs an
GeneralException with the specified detail message. |
GeneralException(java.lang.String msg,
java.util.List<java.lang.String> messages)
Constructs an
GeneralException with the specified detail message, list and nested Exception. |
GeneralException(java.lang.String msg,
java.util.List<java.lang.String> messages,
java.lang.Throwable nested)
Constructs an
GeneralException with the specified detail message, list and nested Exception. |
GeneralException(java.lang.String msg,
java.lang.Throwable nested)
Constructs an
GeneralException with the specified detail message and nested Exception. |
GeneralException(java.lang.Throwable nested)
Constructs an
GeneralException with the specified detail message and nested Exception. |
Modifier and Type | Method and Description |
---|---|
static <T> T |
checkException(java.lang.String message,
java.lang.Throwable t) |
static <T> T |
checkException(java.lang.Throwable t) |
java.lang.String |
getMessage()
Returns the detail message, including the message from the nested exception if there is one.
|
java.util.List<java.lang.String> |
getMessageList() |
java.lang.Throwable |
getNested()
Returns the nested exception if there is one, null if there is not.
|
java.lang.String |
getNonNestedMessage()
Returns the detail message, NOT including the message from the nested exception.
|
void |
printStackTrace()
Prints the composite message to System.err.
|
void |
printStackTrace(java.io.PrintStream ps)
Prints the composite message and the embedded stack trace to the specified stream ps.
|
void |
printStackTrace(java.io.PrintWriter pw)
Prints the composite message and the embedded stack trace to the specified print writer pw.
|
public GeneralException()
GeneralException
without detail message.public GeneralException(java.lang.String msg)
GeneralException
with the specified detail message.msg
- the detail message.public GeneralException(java.lang.String msg, java.lang.Throwable nested)
GeneralException
with the specified detail message and nested Exception.msg
- the detail message.nested
- the nested exception.public GeneralException(java.lang.Throwable nested)
GeneralException
with the specified detail message and nested Exception.nested
- the nested exception.public GeneralException(java.lang.String msg, java.util.List<java.lang.String> messages)
GeneralException
with the specified detail message, list and nested Exception.msg
- the detail message.messages
- error message list.public GeneralException(java.lang.String msg, java.util.List<java.lang.String> messages, java.lang.Throwable nested)
GeneralException
with the specified detail message, list and nested Exception.msg
- the detail message.messages
- error message list.nested
- the nexted exceptionpublic GeneralException(java.util.List<java.lang.String> messages, java.lang.Throwable nested)
GeneralException
with the specified detail message list and nested Exception.messages
- error message list.nested
- the nested exception.public GeneralException(java.util.List<java.lang.String> messages)
public static <T> T checkException(java.lang.Throwable t) throws GeneralException
GeneralException
public static <T> T checkException(java.lang.String message, java.lang.Throwable t) throws GeneralException
GeneralException
public java.lang.String getMessage()
getMessage
in class java.lang.Throwable
public java.util.List<java.lang.String> getMessageList()
public java.lang.String getNonNestedMessage()
public java.lang.Throwable getNested()
public void printStackTrace()
printStackTrace
in class java.lang.Throwable
public void printStackTrace(java.io.PrintStream ps)
printStackTrace
in class java.lang.Throwable
public void printStackTrace(java.io.PrintWriter pw)
printStackTrace
in class java.lang.Throwable