|
|||||||||
| 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.pf.util.WrappingRuntimeException
public class WrappingRuntimeException
This runtime exception can be used to wrap a "normal" exception. This allows to catch a "normal" exception, but it into a WrappingRuntimeException and throw the WrappingRuntimeException instead. The benefit is to avoid the annoying an quite often useless throws clauses in the method signature. As consequnce no try/catch blocks must be put around the callers of such a method. FIGHT CODE POLLUTION!
| Constructor Summary | |
|---|---|
WrappingRuntimeException(java.lang.Exception ex)
Initialize the new instance with default values. |
|
| Method Summary | |
|---|---|
void |
printStackTrace()
Print the stack trace of the wrapped exception to stdout |
void |
printStackTrace(java.io.PrintStream stream)
Print the stack trace of the wrapped exception to the given stream |
void |
printStackTrace(java.io.PrintWriter writer)
Print the stack trace of the wrapped exception to the given writer |
java.lang.String |
toString()
Returns the string representation of the wrapped exception |
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, setStackTrace |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public WrappingRuntimeException(java.lang.Exception ex)
| Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Throwablepublic void printStackTrace()
printStackTrace in class java.lang.Throwablepublic void printStackTrace(java.io.PrintStream stream)
printStackTrace in class java.lang.Throwablepublic void printStackTrace(java.io.PrintWriter writer)
printStackTrace in class java.lang.Throwable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||