|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.midao.jdbc.spring.exception.SpringExceptionHandler
public class SpringExceptionHandler
Exception handler implementation inspired by Spring JDBC implementation
Constructor Summary | |
---|---|
SpringExceptionHandler(java.lang.String dbName)
Creates new SpringExceptionHandler instance. |
Method Summary | |
---|---|
MidaoSQLException |
convert(java.sql.Connection conn,
java.sql.SQLException cause,
java.lang.String sql,
java.lang.Object... params)
Converts SQLException into MidaoSQLException while populating it with query parameters |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SpringExceptionHandler(java.lang.String dbName)
dbName
- Database nameMethod Detail |
---|
public MidaoSQLException convert(java.sql.Connection conn, java.sql.SQLException cause, java.lang.String sql, java.lang.Object... params)
convert
in interface ExceptionHandler
conn
- SQL Connection which is used in current session. Is not guaranteed to be opencause
- original SQL Exceptionsql
- SQL string which was executedparams
- parameters which were supplied to the query
MidaoSQLException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |