com.ibatis.common.exception
Class NestedException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.ibatis.common.exception.NestedException
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
DaoException, JtaTransactionException

public class NestedException
extends java.lang.Exception

Nexted exception implementation. Thanks Claus.

See Also:
Serialized Form

Field Summary
private  java.lang.Throwable cause
           
 
Constructor Summary
NestedException()
          Constructor
NestedException(java.lang.String msg)
          Constructor
NestedException(java.lang.String msg, java.lang.Throwable cause)
          Constructor
NestedException(java.lang.Throwable cause)
          Constructor
 
Method Summary
 java.lang.Throwable getCause()
          Gets the causing exception, if any.
 void printStackTrace()
           
 void printStackTrace(java.io.PrintStream ps)
           
 void printStackTrace(java.io.PrintWriter pw)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getLocalizedMessage, getMessage, getStackTrace, initCause, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

cause

private java.lang.Throwable cause
Constructor Detail

NestedException

public NestedException()
Constructor


NestedException

public NestedException(java.lang.String msg)
Constructor

Parameters:
msg - error message

NestedException

public NestedException(java.lang.Throwable cause)
Constructor

Parameters:
cause - the nested exception (caused by)

NestedException

public NestedException(java.lang.String msg,
                       java.lang.Throwable cause)
Constructor

Parameters:
msg - error message
cause - the nested exception (caused by)
Method Detail

getCause

public java.lang.Throwable getCause()
Gets the causing exception, if any.

Overrides:
getCause in class java.lang.Throwable

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Throwable

printStackTrace

public void printStackTrace()
Overrides:
printStackTrace in class java.lang.Throwable

printStackTrace

public void printStackTrace(java.io.PrintStream ps)
Overrides:
printStackTrace in class java.lang.Throwable

printStackTrace

public void printStackTrace(java.io.PrintWriter pw)
Overrides:
printStackTrace in class java.lang.Throwable