public final class JDBCExceptionReporter
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
JDBCExceptionReporter.StandardWarningHandler |
static interface |
JDBCExceptionReporter.WarningHandler
Contract for handling
warnings |
static class |
JDBCExceptionReporter.WarningHandlerLoggingSupport
Basic support for
JDBCExceptionReporter.WarningHandler implementations which log |
| Modifier and Type | Field and Description |
|---|---|
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 |
| Modifier and Type | Method and Description |
|---|---|
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.
|
static void |
logWarnings(java.sql.SQLWarning warning,
java.lang.String message)
Deprecated.
|
static void |
walkWarnings(java.sql.SQLWarning warning,
JDBCExceptionReporter.WarningHandler handler) |
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
public static void logAndClearWarnings(java.sql.Connection connection)
Connection and clearing them.
Calls handleAndClearWarnings(Connection, WarningHandler) using STANDARD_WARNING_HANDLERconnection - 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) insteaddefault messagewarning - 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) insteadwarning - 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)
Copyright © 2013. All Rights Reserved.