|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.hibernate.util.JDBCExceptionReporter
public final class JDBCExceptionReporter
Nested Class Summary | |
---|---|
static class |
JDBCExceptionReporter.StandardWarningHandler
|
static interface |
JDBCExceptionReporter.WarningHandler
Contract for handling warnings |
static class |
JDBCExceptionReporter.WarningHandlerLoggingSupport
Basic support for JDBCExceptionReporter.WarningHandler implementations which log |
Field Summary | |
---|---|
static java.lang.String |
DEFAULT_EXCEPTION_MSG
|
static java.lang.String |
DEFAULT_WARNING_MSG
|
static org.slf4j.Logger |
log
|
static JDBCExceptionReporter.StandardWarningHandler |
STANDARD_WARNING_HANDLER
|
Method Summary | |
---|---|
static void |
handleAndClearWarnings(java.sql.Connection connection,
JDBCExceptionReporter.WarningHandler handler)
General purpose handling of warnings associated with a JDBC Connection . |
static void |
handleAndClearWarnings(java.sql.Statement statement,
JDBCExceptionReporter.WarningHandler handler)
General purpose handling of warnings associated with a JDBC Statement . |
static void |
logAndClearWarnings(java.sql.Connection connection)
Standard (legacy) behavior for logging warnings associated with a JDBC Connection and clearing them. |
static void |
logExceptions(java.sql.SQLException ex)
|
static void |
logExceptions(java.sql.SQLException ex,
java.lang.String message)
|
static void |
logWarnings(java.sql.SQLWarning warning)
Deprecated. Use walkWarnings(java.sql.SQLWarning, org.hibernate.util.JDBCExceptionReporter.WarningHandler) instead |
static void |
logWarnings(java.sql.SQLWarning warning,
java.lang.String message)
Deprecated. Use walkWarnings(java.sql.SQLWarning, org.hibernate.util.JDBCExceptionReporter.WarningHandler) instead |
static void |
walkWarnings(java.sql.SQLWarning warning,
JDBCExceptionReporter.WarningHandler handler)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final org.slf4j.Logger log
public static final java.lang.String DEFAULT_EXCEPTION_MSG
public static final java.lang.String DEFAULT_WARNING_MSG
public static JDBCExceptionReporter.StandardWarningHandler STANDARD_WARNING_HANDLER
Method Detail |
---|
public static void logAndClearWarnings(java.sql.Connection connection)
Connection
and clearing them.
Calls handleAndClearWarnings(Connection, WarningHandler)
using STANDARD_WARNING_HANDLER
connection
- The JDBC connection potentially containing warningspublic static void handleAndClearWarnings(java.sql.Connection connection, JDBCExceptionReporter.WarningHandler handler)
Connection
.
connection
- The JDBC connection potentially containing warningshandler
- The handler for each individual warning in the stack.walkWarnings(java.sql.SQLWarning, org.hibernate.util.JDBCExceptionReporter.WarningHandler)
public static void handleAndClearWarnings(java.sql.Statement statement, JDBCExceptionReporter.WarningHandler handler)
Statement
.
statement
- The JDBC statement potentially containing warningshandler
- The handler for each individual warning in the stack.walkWarnings(java.sql.SQLWarning, org.hibernate.util.JDBCExceptionReporter.WarningHandler)
@Deprecated public static void logWarnings(java.sql.SQLWarning warning)
walkWarnings(java.sql.SQLWarning, org.hibernate.util.JDBCExceptionReporter.WarningHandler)
instead
default message
warning
- The warning to log@Deprecated public static void logWarnings(java.sql.SQLWarning warning, java.lang.String message)
walkWarnings(java.sql.SQLWarning, org.hibernate.util.JDBCExceptionReporter.WarningHandler)
instead
warning
- The warning to logmessage
- The prologue messagepublic static void walkWarnings(java.sql.SQLWarning warning, JDBCExceptionReporter.WarningHandler handler)
public static void logExceptions(java.sql.SQLException ex)
public static void logExceptions(java.sql.SQLException ex, java.lang.String message)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |