public class ModelException
extends java.lang.Exception
Constructor and Description |
---|
ModelException()
Creates new
ModelException without detail message. |
ModelException(java.lang.String message)
Constructs a
ModelException with the specified detail
message. |
ModelException(java.lang.String message,
java.lang.Throwable cause)
Constructs a new
ModelException with the specified
detail message and cause. |
Modifier and Type | Method and Description |
---|---|
java.lang.Throwable |
getCause()
Returns the cause of this throwable or null if the cause is
nonexistent or unknown.
|
java.lang.String |
getMessage()
Returns the error message string of this throwable object.
|
java.lang.Throwable |
initCause(java.lang.Throwable cause)
Initializes the cause of this throwable to the specified value.
|
void |
printStackTrace()
Prints this
ModelException and its backtrace to the
standard error output. |
void |
printStackTrace(java.io.PrintStream s)
Prints this
ModelException and its backtrace to the
specified print stream. |
void |
printStackTrace(java.io.PrintWriter s)
Prints this
ModelException and its backtrace to the specified
print writer. |
java.lang.String |
toString()
The
String representation includes the name of the class,
the descriptive comment (if any),
and the String representation of the cause (if any). |
public ModelException()
ModelException
without detail message.public ModelException(java.lang.String message)
ModelException
with the specified detail
message.message
- the detail message.public ModelException(java.lang.String message, java.lang.Throwable cause)
ModelException
with the specified
detail message and cause.message
- the detail message.cause
- the cause (which is saved for later retrieval by the
getCause()
method). (A null value is permitted, and
indicates that the cause is nonexistent or unknown.)public java.lang.Throwable getCause()
getCause
in class java.lang.Throwable
public java.lang.Throwable initCause(java.lang.Throwable cause)
initCause
in class java.lang.Throwable
cause
- the cause (which is saved for later retrieval by the
getCause()
method). (A null value is permitted, and
indicates that the cause is nonexistent or unknown.)ModelException
instance.public java.lang.String getMessage()
getMessage
in class java.lang.Throwable
ModelException
object if it was created with an error message string, the error
message of the cause if it was not created a message but the cause
has a message, or null
if neither has an error message.public java.lang.String toString()
String
representation includes the name of the class,
the descriptive comment (if any),
and the String
representation of the cause (if any).toString
in class java.lang.Throwable
String
.public void printStackTrace()
ModelException
and its backtrace to the
standard error output.
Print cause Throwable's stack trace as well.printStackTrace
in class java.lang.Throwable
public void printStackTrace(java.io.PrintStream s)
ModelException
and its backtrace to the
specified print stream.
Print cause Throwable's stack trace as well.printStackTrace
in class java.lang.Throwable
s
- PrintStream
to use for outputpublic void printStackTrace(java.io.PrintWriter s)
ModelException
and its backtrace to the specified
print writer.
Print cause Throwable' stack trace as well.printStackTrace
in class java.lang.Throwable
s
- PrintWriter
to use for outputCopyright © 2005-2012 Apache Software Foundation. All Rights Reserved.