java.lang
Class Throwable
java.lang.Object
java.lang.Throwable
- Direct Known Subclasses:
- Exception
public class Throwable
- extends Object
Throwable
public Throwable()
Throwable
public Throwable(String message)
Throwable
public Throwable(String message,
Throwable cause)
Throwable
public Throwable(Throwable cause)
getMessage
public String getMessage()
getLocalizedMessage
public String getLocalizedMessage()
getCause
public Throwable getCause()
toString
public String toString()
- Overrides:
toString in class Object
printStackTrace
public void printStackTrace()
nullStackTrace
public void nullStackTrace()
printStackTrace
public void printStackTrace(PrintStream s)
fillInStackTrace
public Throwable fillInStackTrace()
- This method fills in the stack trace when a new Throwable is created.
This can be quite an expensive operation if the stack is deep, so if you
are creating many Throwables (for example if you are using Throwables
for program flow control) you should use a subclass of Throwable where
this method is overridden. An acceptable implementation is just to
return this.