com.j_spaces.sadapter.GenericJDBC.lob
Class OracleLobHandler

java.lang.Object
  extended by com.j_spaces.sadapter.GenericJDBC.lob.DefaultLobHandler
      extended by com.j_spaces.sadapter.GenericJDBC.lob.OracleLobHandler
All Implemented Interfaces:
ILobHandler

public class OracleLobHandler
extends DefaultLobHandler

LobHandler implementation for Oracle databases. Uses proprietary API to create oracle.sql.BLOB instance. While most JDBC compliant databases work fine with the DefaultLobHandler, this handler should be used when working with Oracle 9i.

Since:
5.1

Constructor Summary
OracleLobHandler()
           
 
Method Summary
 void init()
          Initialize lob handler
 void setBlobAsBytes(PreparedStatement ps, int paramIndex, byte[] content)
          Set the given content as bytes on the given statement, using the given parameter index.
 
Methods inherited from class com.j_spaces.sadapter.GenericJDBC.lob.DefaultLobHandler
getBlobAsBytes, getBlobAsBytes
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OracleLobHandler

public OracleLobHandler()
Method Detail

setBlobAsBytes

public void setBlobAsBytes(PreparedStatement ps,
                           int paramIndex,
                           byte[] content)
                    throws SQLException
Description copied from interface: ILobHandler
Set the given content as bytes on the given statement, using the given parameter index.

Specified by:
setBlobAsBytes in interface ILobHandler
Overrides:
setBlobAsBytes in class DefaultLobHandler
Parameters:
ps - the PreparedStatement to the set the content on
paramIndex - the parameter index to use
content - the content as byte array
Throws:
SQLException - if thrown by JDBC methods

init

public void init()
          throws Exception
Description copied from interface: ILobHandler
Initialize lob handler

Specified by:
init in interface ILobHandler
Overrides:
init in class DefaultLobHandler
Throws:
Exception