java.lang

Class Error

public class Error extends Throwable

Applications should not try to catch errors since they indicate abnormal conditions. An abnormal condition is something which should not occur, or which should not be recovered from. This latter category includes ThreadDeath and AssertionError.

A method is not required to declare any subclass of Error in its throws clause which might be thrown but not caught while executing the method.

Since: 1.0

UNKNOWN: updated to 1.4

Constructor Summary
Error()
Create an error without a message.
Error(String s)
Create an error with a message.
Error(String s, Throwable cause)
Create an error with a message and a cause.
Error(Throwable cause)
Create an error with a given cause, and a message of cause == null ?

Constructor Detail

Error

public Error()
Create an error without a message. The cause remains uninitialized.

See Also: Error

Error

public Error(String s)
Create an error with a message. The cause remains uninitialized.

Parameters: s the message string

See Also: Error

Error

public Error(String s, Throwable cause)
Create an error with a message and a cause.

Parameters: s the message string cause the cause of this error

Since: 1.4

Error

public Error(Throwable cause)
Create an error with a given cause, and a message of cause == null ? null : cause.toString().

Parameters: cause the cause of this error

Since: 1.4