|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.apache.cactus.util.ChainedRuntimeException
public class ChainedRuntimeException
Represent an exception that should stop the running test. It is a runtime exception but it will be caught by JUnit so the application will not stop. The test will be reported as failed. It implements chaining.
Field Summary | |
---|---|
protected java.lang.Throwable |
originalException
Original exception which caused this exception. |
Constructor Summary | |
---|---|
ChainedRuntimeException(java.lang.String theMessage)
Create a ChainedRuntimeException and set the exception
error message. |
|
ChainedRuntimeException(java.lang.String theMessage,
java.lang.Throwable theException)
Create a ChainedRuntimeException , set the exception error
message along with the exception object that caused this exception. |
|
ChainedRuntimeException(java.lang.Throwable theException)
Create a ChainedRuntimeException , and set exception object
that caused this exception. |
Method Summary | |
---|---|
void |
printStackTrace()
Print the full stack trace, including the original exception. |
void |
printStackTrace(java.io.PrintStream thePs)
Print the full stack trace, including the original exception. |
void |
printStackTrace(java.io.PrintWriter thePw)
Print the full stack trace, including the original exception. |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, setStackTrace, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.lang.Throwable originalException
Constructor Detail |
---|
public ChainedRuntimeException(java.lang.String theMessage)
ChainedRuntimeException
and set the exception
error message.
theMessage
- the message of the exceptionpublic ChainedRuntimeException(java.lang.String theMessage, java.lang.Throwable theException)
ChainedRuntimeException
, set the exception error
message along with the exception object that caused this exception.
theMessage
- the detail of the error messagetheException
- the original exceptionpublic ChainedRuntimeException(java.lang.Throwable theException)
ChainedRuntimeException
, and set exception object
that caused this exception. The message is set by default to be the one
from the original exception.
theException
- the original exceptionMethod Detail |
---|
public void printStackTrace()
printStackTrace
in class java.lang.Throwable
public void printStackTrace(java.io.PrintStream thePs)
printStackTrace
in class java.lang.Throwable
thePs
- the byte stream in which to print the stack tracepublic void printStackTrace(java.io.PrintWriter thePw)
printStackTrace
in class java.lang.Throwable
thePw
- the character stream in which to print the stack trace
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |