|
WebObjects 5.2.3 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Throwable java.lang.Exception java.lang.RuntimeException com.webobjects.foundation.NSForwardException
NSForwardException objects (or forwarded exceptions) are wrappers for Throwable objects which are not RuntimeExceptions. Since NSForwardException is a subclass of RuntimeException, forwarded exceptions are usually omitted from the throws clause of a method even if the original exception would have had to be declared.
NSForwardException is used within WebObjects to keep the API congruent with the WebObjects 4.5 API (which uses the Java Bridge). Apple doesn't anticipate the need for you to create NSForwardException objects. You may need to catch them, however.
originalException()
,
Serialized FormConstructor Summary | |
NSForwardException(Throwable wrapped)
Creates an NSForwardException from wrapped . |
|
NSForwardException(Throwable wrapped,
String extraMessage)
Creates an NSForwardException from wrapped . |
Method Summary | |
Throwable |
originalException()
|
void |
printStackTrace()
Prints the original exception and its stack trace to the standard error stream. |
void |
printStackTrace(PrintStream stream)
Prints the original exception and its stack trace to the specified print stream . |
void |
printStackTrace(PrintWriter writer)
Prints the original exception and its stack trace to the specified print writer. |
String |
stackTrace()
|
String |
toString()
Returns a string representation of the receiver indicating the receiver's class, its wrapped exception's class, and the wrapped exception's error message string. |
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, setStackTrace |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public NSForwardException(Throwable wrapped, String extraMessage)
wrapped
.
If wrapped
is already an NSForwardException, the constructor wraps
the exception's original exception.
The two-argument constructor allows you to specify an extra message;
in this case, the new NSForwardException's message is wrapped
's
message with extraMessage
appended.
wrapped
- the original exceptionextraMessage
- description to be attached to the original exceptionoriginalException()
public NSForwardException(Throwable wrapped)
wrapped
.
If wrapped
is already an NSForwardException, the constructor
wraps the exception's originalException
.
wrapped
- the original exceptionoriginalException()
Method Detail |
public Throwable originalException()
public void printStackTrace()
public void printStackTrace(PrintStream stream)
stream
.
stream
- the exception returned from the receiverpublic void printStackTrace(PrintWriter writer)
writer
- the printing device managerpublic String stackTrace()
public String toString()
|
Last updated Thu Oct 21 15:04:16 PDT 2004. | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |