public class Databases extends Object
| Constructor and Description |
|---|
Databases() |
| Modifier and Type | Method and Description |
|---|---|
static void |
close(Connection closable)
Closes a passed
Connection object and swallows any
SQLException that occurs. |
static void |
close(ResultSet closable)
Closes a passed
ResultSet object and swallows any
SQLException that occurs. |
static void |
close(Statement closable)
Closes a passed
Statement object and swallows any
SQLException that occurs. |
static String |
simpleErrorOutput(SQLException ex)
Formats an
SQLException to be output with more information about
the error |
public static String simpleErrorOutput(SQLException ex)
SQLException to be output with more information about
the errorex - The relevant SQLExceptionpublic static void close(Statement closable)
Statement object and swallows any
SQLException that occurs. Can handle null parametersclosable - The Statement to closepublic static void close(Connection closable)
Connection object and swallows any
SQLException that occurs. Can handle null parametersclosable - The Connection to closepublic static void close(ResultSet closable)
ResultSet object and swallows any
SQLException that occurs. Can handle null parametersclosable - The ResultSet to closeCopyright © 2015. All rights reserved.