com.finalist.tools.database
Class DBFRowMapper

java.lang.Object
  extended bycom.finalist.tools.database.RowMapper
      extended bycom.finalist.tools.database.DBFRowMapper

public class DBFRowMapper
extends RowMapper

Implementation of the rowmapper for Oracle. This class has been tested against Oracle 8.1.7 and 8.2.

Version:
1.0
Author:
P.S.D.Reitsma, Finalist IT Group

Constructor Summary
DBFRowMapper()
           
 
Method Summary
 java.sql.PreparedStatement bind(java.sql.PreparedStatement pstmt, java.lang.Object bindVar, java.lang.String bindVarClassType, int pos)
          Method that binds an object of a specified type into a PreparedStatement and returns the PreparedStatement.
static java.lang.String byteArrayExtendedToString(byte[] ba)
           
 java.lang.Object unBindIntoBean(java.sql.ResultSet rset, java.lang.Object target)
          Method that reads the values from a ResultSet an populates the properties of a bean
 java.util.HashMap unBindIntoHashMap(java.sql.ResultSet r, java.util.HashMap target)
          Method that reads the values from a ResultSet for one row and stores them into a HashMap.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DBFRowMapper

public DBFRowMapper()
Method Detail

bind

public java.sql.PreparedStatement bind(java.sql.PreparedStatement pstmt,
                                       java.lang.Object bindVar,
                                       java.lang.String bindVarClassType,
                                       int pos)
                                throws java.sql.SQLException,
                                       NotMappableException
Description copied from class: RowMapper
Method that binds an object of a specified type into a PreparedStatement and returns the PreparedStatement.

Specified by:
bind in class RowMapper
Parameters:
pstmt - PreparedStatement to which the object should be bound.
bindVar - the object that is to be bound.
bindVarClassType - the full classname that identifies the type of the class
pos - the position at which the object should be bound into the statement.
Returns:
PreparedStatement the resulting PreparedStatement after the bind has happened.
Throws:
java.sql.SQLException
NotMappableException - when no appropriate bind method could be found

unBindIntoHashMap

public java.util.HashMap unBindIntoHashMap(java.sql.ResultSet r,
                                           java.util.HashMap target)
                                    throws java.sql.SQLException,
                                           NotMappableException
Description copied from class: RowMapper
Method that reads the values from a ResultSet for one row and stores them into a HashMap.

Specified by:
unBindIntoHashMap in class RowMapper
Parameters:
r - the resultset that serves a source
target - the HashMap in which the values will be stored
Returns:
the resulting HashMap
Throws:
java.sql.SQLException
NotMappableException - when no appropriate unbind method could be found

unBindIntoBean

public java.lang.Object unBindIntoBean(java.sql.ResultSet rset,
                                       java.lang.Object target)
                                throws java.sql.SQLException,
                                       NotMappableException
Description copied from class: RowMapper
Method that reads the values from a ResultSet an populates the properties of a bean

Specified by:
unBindIntoBean in class RowMapper
Parameters:
rset - the resultset that serves a source
target - the bean of which the properties should be set
Returns:
the resulting bean
Throws:
java.sql.SQLException
NotMappableException - when no appropriate unbind method could be found

byteArrayExtendedToString

public static java.lang.String byteArrayExtendedToString(byte[] ba)


Copyright © 2003-2004 SourceForge. All Rights Reserved.