|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.sape.sqlutils.ResultSetHelper
Translates database values to application values. Also contains other ResultSet utilities, such as getting column names.
| Field Summary | |
private static int |
BUF_LEN
|
private static org.apache.commons.logging.Log |
log
|
| Constructor Summary | |
ResultSetHelper()
|
|
| Method Summary | |
static boolean |
getBooleanFromChar(ResultSet rs,
String column)
Converts a 'Y' or 'N' character stored in the database to a boolean. |
static String |
getColumnNames(ResultSet rs)
Returns the column names in the supplied ResultSet. |
static Date |
getDate(ResultSet rs,
String column)
Converts a java.sql.Date object stored in the database to a java.util.Date object. |
static Date |
getTimestamp(ResultSet rs,
String column)
Converts a java.sql.Timestamp object stored in the database to a java.util.Date object. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private static final org.apache.commons.logging.Log log
private static final int BUF_LEN
| Constructor Detail |
public ResultSetHelper()
| Method Detail |
public static Date getDate(ResultSet rs,
String column)
throws SQLException
rs - ResultSet from which value is to be extractedcolumn - from which value is to be extracted
SQLException
public static Date getTimestamp(ResultSet rs,
String column)
throws SQLException
rs - ResultSet from which value is to be extractedcolumn - from which value is to be extracted
SQLException
public static boolean getBooleanFromChar(ResultSet rs,
String column)
throws SQLException
rs - ResultSet from which value is to be extractedcolumn - from which boolean conversion to be performed
SQLExceptionpublic static String getColumnNames(ResultSet rs)
rs - ResultSet whose column names are needed
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||