public class java.lang
Exception


Show All Login
Java SE 6
  
Extends: Throwable
Extended by: AclNotFoundException, ActivationException, AlreadyBoundException, ApplicationException, AWTException, BackingStoreException, BadAttributeValueExpException, BadBinaryOpValueExpException, BadLocationException, BadStringOperationException, BrokenBarrierException, CardException, ClassNotFoundException, CloneNotSupportedException, DataFormatException, DatatypeConfigurationException, DatatypeException, DestroyFailedException, ExecutionException, ExpandVetoException, FontFormatException, GeneralSecurityException, GSSException, IllegalAccessException, IllegalClassFormatException, InstantiationException, InterruptedException, IntrospectionException, InvalidApplicationException, InvalidMidiDataException, InvalidPreferencesFormatException, InvalidTargetObjectTypeException, InvocationTargetException, IOException, JAXBException, JMException, KeySelectorException, LastOwnerException, LineUnavailableException, MarshalException, MidiUnavailableException, MimeTypeParseException, NamingException, NoninvertibleTransformException, NoSuchFieldException, NoSuchMethodException, NotBoundException, NotOwnerException, ParseException, ParserConfigurationException, PrinterException, PrintException, PrivilegedActionException, PropertyVetoException, RefreshFailedException, RemarshalException, RuntimeException, SAXException, ScriptException, ServerNotActiveException, SOAPException, SQLException, TimeoutException, TooManyListenersException, TransformerException, TransformException, UnmodifiableClassException, UnsupportedAudioFileException, UnsupportedCallbackException, UnsupportedFlavorException, UnsupportedLookAndFeelException, URIReferenceException, URISyntaxException, UserException, XAException, XMLParseException, XMLSignatureException, XMLStreamException, XPathException
Details
The class Exception and its subclasses are a form of Throwable that indicates conditions that a reasonable application might want to catch.
version1.32, 11/17/05
sinceJDK1.0
See also java.lang.Error

Constructors
public Exception()
Constructs a new exception with null as its detail message. The cause is not initialized, and may subsequently be initialized by a call to #initCause.
public Exception(String message) Details
Constructs a new exception with the specified detail message. The cause is not initialized, and may subsequently be initialized by a call to #initCause.
messagethe detail message. The detail message is saved for later retrieval by the #getMessage() method.
public Exception(String message, Throwable cause) Details
Constructs a new exception with the specified detail message and cause.

Note that the detail message associated with cause is not automatically incorporated in this exception's detail message.
messagethe detail message (which is saved for later retrieval by the #getMessage() method).
causethe cause (which is saved for later retrieval by the #getCause() method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
since1.4

public Exception(Throwable cause) Details
Constructs a new exception with the specified cause and a detail message of (cause==null ? null : cause.toString()) (which typically contains the class and detail message of cause). This constructor is useful for exceptions that are little more than wrappers for other throwables (for example, java.security.PrivilegedActionException).
causethe cause (which is saved for later retrieval by the #getCause() method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
since1.4