|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
public class Exception
The root class of all exceptions worth catching in a program. This
includes the special category of RuntimeException, which
does not need to be declared in a throws clause. Exceptions can be used
to represent almost any exceptional behavior, such as programming errors,
mouse movements, keyboard clicking, etc.
| Constructor Summary | |
|---|---|
Exception()
Create an exception without a message. |
|
Exception(String s)
Create an exception with a message. |
|
Exception(String s,
Throwable cause)
Create an exception with a message and a cause. |
|
Exception(Throwable cause)
Create an exception with a given cause, and a message of cause == null ? null : cause.toString(). |
|
| Method Summary |
|---|
| Methods inherited from class java.lang.Throwable |
|---|
getCause, getLocalizedMessage, getMessage, initCause, printStackTrace, printStackTrace, printStackTrace, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Exception()
Throwable.initCause(Throwable)public Exception(String s)
s - the messageThrowable.initCause(Throwable)
public Exception(String s,
Throwable cause)
s - the message stringcause - the cause of this errorpublic Exception(Throwable cause)
cause == null ? null : cause.toString().
cause - the cause of this exception
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||