public final class Utils
extends java.lang.Object
| Modifier and Type | Field | Description |
|---|---|---|
static java.lang.String |
DISCONNECTION_SQL_CODE_PREFIX |
Any SQL_STATE starting with this value is considered a fatal disconnect
|
static java.util.Set<java.lang.String> |
DISCONNECTION_SQL_CODES |
SQL codes of fatal connection errors.
|
static boolean |
IS_SECURITY_ENABLED |
| Modifier and Type | Method | Description |
|---|---|---|
static void |
closeQuietly(java.sql.Connection conn) |
Closes the Connection (which may be null).
|
static void |
closeQuietly(java.sql.ResultSet rset) |
Closes the ResultSet (which may be null).
|
static void |
closeQuietly(java.sql.Statement stmt) |
Closes the Statement (which may be null).
|
static java.lang.String |
getMessage(java.lang.String key) |
Obtain the correct i18n message for the given key.
|
static java.lang.String |
getMessage(java.lang.String key,
java.lang.Object... args) |
Obtain the correct i18n message for the given key with placeholders
replaced by the supplied arguments.
|
public static final java.lang.String DISCONNECTION_SQL_CODE_PREFIX
public static final java.util.Set<java.lang.String> DISCONNECTION_SQL_CODES
public static final boolean IS_SECURITY_ENABLED
public static void closeQuietly(java.sql.Connection conn)
conn - a Connection, may be nullpublic static void closeQuietly(java.sql.ResultSet rset)
rset - a ResultSet, may be nullpublic static void closeQuietly(java.sql.Statement stmt)
stmt - a Statement, may be nullpublic static java.lang.String getMessage(java.lang.String key)
public static java.lang.String getMessage(java.lang.String key,
java.lang.Object... args)
Copyright © 2001-2015 Apache Software Foundation. Documenation generated March 25 2019.