org.makumba.db.makumba
Class MakumbaCRUDOperationProvider

java.lang.Object
  extended by org.makumba.providers.CRUDOperationProvider
      extended by org.makumba.db.makumba.MakumbaCRUDOperationProvider

public class MakumbaCRUDOperationProvider
extends CRUDOperationProvider

Makumba-specific implementation of the CRUDOperationProvider

Version:
$Id: MakumbaCRUDOperationProvider.java,v 1.1 02.11.2007 12:29:23 Manuel Exp $
Author:
Manuel Gay

Field Summary
 
Fields inherited from class org.makumba.providers.CRUDOperationProvider
ddp
 
Constructor Summary
MakumbaCRUDOperationProvider()
           
 
Method Summary
 void checkInsert(Transaction t, String type, Dictionary<String,Object> fieldsToCheck, Dictionary<String,DataHolder> fieldsToIgnore, Dictionary<String,Object> allFields)
          Checks if a set of values can be updated in the database
 void checkUpdate(Transaction t, String type, Pointer pointer, Dictionary<String,Object> fieldsToCheck, Dictionary<String,DataHolder> fieldsToIgnore, Dictionary<String,Object> allFields)
          Checks if a set of values can be updated in the database.
 Pointer insert(Transaction t, String type, Dictionary<String,Object> data)
          Inserts data of a given type
 int update1(Transaction t, Pointer p, DataDefinition typeDef, Dictionary<String,Object> dic)
           
 
Methods inherited from class org.makumba.providers.CRUDOperationProvider
checkUpdate, delete, deleteSet, read, update, updateSet, updateSet1
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MakumbaCRUDOperationProvider

public MakumbaCRUDOperationProvider()
Method Detail

insert

public Pointer insert(Transaction t,
                      String type,
                      Dictionary<String,Object> data)
Description copied from class: CRUDOperationProvider
Inserts data of a given type

Specified by:
insert in class CRUDOperationProvider
Parameters:
t - the Transaction handling the insertion
type - the type of the object to be inserted
data - the data to be inserted
Returns:
a Pointer corresponding to the place where the record has been inserted

checkInsert

public void checkInsert(Transaction t,
                        String type,
                        Dictionary<String,Object> fieldsToCheck,
                        Dictionary<String,DataHolder> fieldsToIgnore,
                        Dictionary<String,Object> allFields)
Description copied from class: CRUDOperationProvider
Checks if a set of values can be updated in the database

Specified by:
checkInsert in class CRUDOperationProvider
Parameters:
t - the Transaction to be used
type - the type of the base object to insert to
fieldsToCheck - the values to be checked
fieldsToIgnore - the values of toCheck not to be checked
allFields - the entire data to be inserted

checkUpdate

public void checkUpdate(Transaction t,
                        String type,
                        Pointer pointer,
                        Dictionary<String,Object> fieldsToCheck,
                        Dictionary<String,DataHolder> fieldsToIgnore,
                        Dictionary<String,Object> allFields)
Description copied from class: CRUDOperationProvider
Checks if a set of values can be updated in the database.

Specified by:
checkUpdate in class CRUDOperationProvider
Parameters:
t - the Transaction to be used
type - the type of the base object to insert to
pointer - the pointer to the record to be updated
fieldsToCheck - the values to be checked
fieldsToIgnore - the values of toCheck not to be checked
allFields - the entire data to be inserted

update1

public int update1(Transaction t,
                   Pointer p,
                   DataDefinition typeDef,
                   Dictionary<String,Object> dic)
Specified by:
update1 in class CRUDOperationProvider