com.ibatis.common.jdbc.exception
Class RuntimeSQLException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by com.ibatis.common.jdbc.exception.RuntimeSQLException
所有已实现接口:
java.io.Serializable

public class RuntimeSQLException
extends java.lang.RuntimeException

Unchecked exception to allow passing an Exception with the original SQLException

另请参见:
Serialized Form

构造器摘要
RuntimeSQLException()
          Default constructor
RuntimeSQLException(java.sql.SQLException sqlException)
          Constructor to pass along another exception
RuntimeSQLException(java.lang.String msg)
          Constructor to pass along a message
RuntimeSQLException(java.lang.String msg, java.sql.SQLException sqlException)
          Constructor to pass along a message and an exception
 
方法摘要
 int getErrorCode()
          Getter for the error code
 java.sql.SQLException getNextException()
          Get the next exception in the chain
 java.lang.String getSQLState()
          Getter for the SQL State
 void setNextException(java.sql.SQLException ex)
          Set the next exception in the chain
 
类方法继承: java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
类方法继承: java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

构造器详细信息

RuntimeSQLException

public RuntimeSQLException()
Default constructor


RuntimeSQLException

public RuntimeSQLException(java.lang.String msg)
Constructor to pass along a message

参数:
msg - - the message

RuntimeSQLException

public RuntimeSQLException(java.sql.SQLException sqlException)
Constructor to pass along another exception

参数:
sqlException - - the exception

RuntimeSQLException

public RuntimeSQLException(java.lang.String msg,
                           java.sql.SQLException sqlException)
Constructor to pass along a message and an exception

参数:
msg - - the message
sqlException - - the exception
方法详细信息

getSQLState

public java.lang.String getSQLState()
Getter for the SQL State

返回:
- the state

getErrorCode

public int getErrorCode()
Getter for the error code

返回:
- the error code

getNextException

public java.sql.SQLException getNextException()
Get the next exception in the chain

返回:
- the next exception

setNextException

public void setNextException(java.sql.SQLException ex)
Set the next exception in the chain

参数:
ex - - the next exception