Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## sharin.util
Class SqlUtils

    java.lang.Object
      sharin.util.SqlUtils

    public class SqlUtils

extends Object

Constructor Summary
`SqlUtils()`

Method Summary
`static void` | `close(Connection conn)`
`static void` | `close(ResultSet rs)`
`static void` | `close(Statement stmt)`
`static ResultSet` | `executeQuery(PreparedStatement pstmt)`
`static int` | `executeUpdate(PreparedStatement pstmt)`
`static BigDecimal` | `getBigDecimal(ResultSet rs, int columnIndex)`
`static boolean` | `getBoolean(ResultSet rs, int columnIndex)`
`static byte` | `getByte(ResultSet rs, int columnIndex)`
`static byte[]` | `getBytes(ResultSet rs, int columnIndex)`
`static int` | `getColumnCount(ResultSetMetaData metaData)`
`static String` | `getColumnLabel(ResultSetMetaData metaData, int column)`
`static Connection` | `getConnection(DataSource ds)`
`static Date` | `getDate(ResultSet rs, int columnIndex)`
`static double` | `getDouble(ResultSet rs, int columnIndex)`
`static float` | `getFloat(ResultSet rs, int columnIndex)`
`static ResultSet` | `getGeneratedKeys(Statement stmt)`
`static int` | `getInt(ResultSet rs, int columnIndex)`
`static long` | `getLong(ResultSet rs, int columnIndex)`
`static ResultSetMetaData` | `getMetaData(ResultSet rs)`
`static Object` | `getObject(ResultSet rs, int columnIndex)`
`static short` | `getShort(ResultSet rs, int columnIndex)`
`static String` | `getString(ResultSet rs, int columnIndex)`
`static Time` | `getTime(ResultSet rs, int columnIndex)`
`static Timestamp` | `getTimestamp(ResultSet rs, int columnIndex)`
`static boolean` | `next(ResultSet rs)`
`static PreparedStatement` | `prepareStatement(Connection conn, String sql)`
`static void` | `setObject(PreparedStatement pstmt, int parameterIndex, Object x)`
`static boolean` | `wasNull(ResultSet rs)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### SqlUtils

    public SqlUtils()

Method Detail

### getConnection

    public static Connection getConnection(DataSource ds)

### prepareStatement

    public static PreparedStatement prepareStatement(Connection conn,
                                                     String sql)

### close

    public static void close(Connection conn)

### setObject

    public static void setObject(PreparedStatement pstmt,
                                 int parameterIndex,
                                 Object x)

### executeQuery

    public static ResultSet executeQuery(PreparedStatement pstmt)

### close

    public static void close(Statement stmt)

### next

    public static boolean next(ResultSet rs)

### close

    public static void close(ResultSet rs)

### executeUpdate

    public static int executeUpdate(PreparedStatement pstmt)

### getGeneratedKeys

    public static ResultSet getGeneratedKeys(Statement stmt)

### getMetaData

    public static ResultSetMetaData getMetaData(ResultSet rs)

### getColumnCount

    public static int getColumnCount(ResultSetMetaData metaData)

### getColumnLabel

    public static String getColumnLabel(ResultSetMetaData metaData,
                                        int column)

### getObject

    public static Object getObject(ResultSet rs,
                                   int columnIndex)

### getBigDecimal

    public static BigDecimal getBigDecimal(ResultSet rs,
                                           int columnIndex)

### getString

    public static String getString(ResultSet rs,
                                   int columnIndex)

### getBoolean

    public static boolean getBoolean(ResultSet rs,
                                     int columnIndex)

### getByte

    public static byte getByte(ResultSet rs,
                               int columnIndex)

### getBytes

    public static byte[] getBytes(ResultSet rs,
                                  int columnIndex)

### getDate

    public static Date getDate(ResultSet rs,
                               int columnIndex)

### getDouble

    public static double getDouble(ResultSet rs,
                                   int columnIndex)

### getFloat

    public static float getFloat(ResultSet rs,
                                 int columnIndex)

### getInt

    public static int getInt(ResultSet rs,
                             int columnIndex)

### getLong

    public static long getLong(ResultSet rs,
                               int columnIndex)

### getShort

    public static short getShort(ResultSet rs,
                                 int columnIndex)

### getTime

    public static Time getTime(ResultSet rs,
                               int columnIndex)

### getTimestamp

    public static Timestamp getTimestamp(ResultSet rs,
                                         int columnIndex)

### wasNull

    public static boolean wasNull(ResultSet rs)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SHU. All Rights Reserved.