org.opensubsystems.core.persist.db
Interface ModifiableDatabaseFactory

All Superinterfaces:
BasicDatabaseFactory, DatabaseFactory

public interface ModifiableDatabaseFactory
extends BasicDatabaseFactory

This interface defines methods, which should be implemented by factory which support batched update operation.

Version:
$Id: ModifiableDatabaseFactory.java,v 1.3 2007/01/07 06:14:18 bastafidli Exp $
Author:
Julian Legeny
Code reviewer:
Miro Halas
Code reviewed:
1.1 2006/07/26 00:02:45 jlegeny

Method Summary
 int setValuesForUpdate(java.sql.PreparedStatement updateStatement, DataObject data, int initialIndex)
          Method sets values to the prepared statement for update of data object.
 
Methods inherited from interface org.opensubsystems.core.persist.db.BasicDatabaseFactory
setValuesForInsert
 
Methods inherited from interface org.opensubsystems.core.persist.db.DatabaseFactory
load
 

Method Detail

setValuesForUpdate

int setValuesForUpdate(java.sql.PreparedStatement updateStatement,
                       DataObject data,
                       int initialIndex)
                       throws OSSException,
                              java.sql.SQLException
Method sets values to the prepared statement for update of data object.

Parameters:
updateStatement - - prepared statement the values will be set up for
data - - data object to update, based on the type of the data object it can be determined what data are we updating
initialIndex - - initial index for values to be set up into statement
Returns:
int - index of the last parameter in prepared statement (can be used for later processing outside of this method)
Throws:
OSSException - - exception during setting values
java.sql.SQLException - - exception during setting values


Copyright © 2003 - 2006 OpenSubsystems s.r.o.