com.anthonyeden.lib.util
Class SQLUtilities

java.lang.Object
  extended bycom.anthonyeden.lib.util.SQLUtilities

public class SQLUtilities
extends java.lang.Object

Useful SQL utilities.

Author:
Anthony Eden, kalman

Constructor Summary
SQLUtilities()
           
 
Method Summary
static void close(java.sql.Connection c)
          Close the given JDBC connection if it is not null.
static void close(java.sql.ResultSet rs)
          Close the given JDBC ResultSet if it is not null.
static void close(java.sql.Statement stmt)
          Close the given JDBC statement if it is not null.
static java.lang.String toString(java.sql.SQLException sqlx)
          Convert the given SQLException into a String.
static java.lang.String toString(java.sql.SQLWarning sqlw)
          Convert the given SQLWarning into a String.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SQLUtilities

public SQLUtilities()
Method Detail

close

public static void close(java.sql.ResultSet rs)
Close the given JDBC ResultSet if it is not null.

Parameters:
rs - The JDBC ResultSet

close

public static void close(java.sql.Statement stmt)
Close the given JDBC statement if it is not null.

Parameters:
stmt - The JDBC Statement

close

public static void close(java.sql.Connection c)
Close the given JDBC connection if it is not null.

Parameters:
c - The JDBC connection

toString

public static java.lang.String toString(java.sql.SQLWarning sqlw)
Convert the given SQLWarning into a String.

Parameters:
sqlw - The SQLWarning

toString

public static java.lang.String toString(java.sql.SQLException sqlx)
Convert the given SQLException into a String.

Parameters:
sqlx - The SQLException
Returns:
A String


Copyright (c) 2000-2003 Anthony Eden. All Rights Reserved.