com.ingenta.clownbike
Class DatabaseTransaction

java.lang.Object
  extended bycom.ingenta.clownbike.DatabaseTransaction
All Implemented Interfaces:
Transaction

public class DatabaseTransaction
extends java.lang.Object
implements Transaction


Constructor Summary
DatabaseTransaction(Database database, Index index)
           
 
Method Summary
 void commit()
           
 void create(java.lang.Object object)
           
 void create(java.lang.Object object, boolean index)
           
 java.sql.Connection getConnection()
           
 Manager getManager(java.lang.Class type)
           
 java.util.Date getNow()
           
 java.lang.Object getParameter(java.lang.Object name)
           
 boolean isActive()
           
 java.util.List load(java.lang.Class type)
           
 java.lang.Object load(java.lang.Class type, java.lang.Integer id)
           
 java.util.List load(java.lang.Class type, java.util.List ids)
           
 void remove(java.lang.Object object)
           
 void remove(java.lang.Object object, boolean index)
           
 void rollback()
           
 void setParameter(java.lang.Object name, java.lang.Object value)
           
 void update(java.lang.Object object)
           
 void update(java.lang.Object object, boolean index)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DatabaseTransaction

public DatabaseTransaction(Database database,
                           Index index)
                    throws DatabaseException
Method Detail

isActive

public boolean isActive()

load

public java.lang.Object load(java.lang.Class type,
                             java.lang.Integer id)
                      throws DatabaseException
Throws:
DatabaseException

load

public java.util.List load(java.lang.Class type,
                           java.util.List ids)
                    throws DatabaseException
Throws:
DatabaseException

load

public java.util.List load(java.lang.Class type)
                    throws DatabaseException
Throws:
DatabaseException

create

public void create(java.lang.Object object)
            throws DatabaseException
Throws:
DatabaseException

create

public void create(java.lang.Object object,
                   boolean index)
            throws DatabaseException
Throws:
DatabaseException

update

public void update(java.lang.Object object)
            throws DatabaseException
Throws:
DatabaseException

update

public void update(java.lang.Object object,
                   boolean index)
            throws DatabaseException
Throws:
DatabaseException

remove

public void remove(java.lang.Object object)
            throws DatabaseException
Throws:
DatabaseException

remove

public void remove(java.lang.Object object,
                   boolean index)
            throws DatabaseException
Throws:
DatabaseException

commit

public void commit()
            throws DatabaseException
Throws:
DatabaseException

rollback

public void rollback()
              throws DatabaseException
Throws:
DatabaseException

getConnection

public java.sql.Connection getConnection()
Specified by:
getConnection in interface Transaction

getNow

public java.util.Date getNow()

getManager

public Manager getManager(java.lang.Class type)
                   throws DatabaseException
Throws:
DatabaseException

getParameter

public java.lang.Object getParameter(java.lang.Object name)
Specified by:
getParameter in interface Transaction

setParameter

public void setParameter(java.lang.Object name,
                         java.lang.Object value)
Specified by:
setParameter in interface Transaction