|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.jaffa.persistence.engines.jdbcengine.querygenerator.JdbcBridge
Use the methods of this class to execute various operations on the database.
| Method Summary | |
static void |
executeAdd(IPersistent object,
DataSource dataSource)
Adds the Persistent object to the database. |
static void |
executeDelete(IPersistent object,
DataSource dataSource)
Deletes the Persistent object from the database. |
static void |
executeLock(IPersistent object,
DataSource dataSource)
Locks the underlying database row of the Persistent object. |
static Collection |
executeQuery(Criteria criteria,
DataSource dataSource)
Executes the query based on the Criteria object. |
static void |
executeStoredProcedure(IStoredProcedure sp,
DataSource dataSource)
Executes the Stored Procedure. |
static void |
executeUpdate(IPersistent object,
DataSource dataSource)
Updates the Persistent object in the database. |
static void |
updatePersistentFlagsOnAdd(IPersistent object)
This method sets the appropriate flags on a Persistent object after being added to the database. |
static void |
updatePersistentFlagsOnDelete(IPersistent object)
This method sets the appropriate flags on a Persistent object after being deleted from the database. |
static void |
updatePersistentFlagsOnLock(IPersistent object)
This method sets the appropriate flags on a Persistent object after the underlying row is locked in the database. |
static void |
updatePersistentFlagsOnQuery(IPersistent object,
Criteria criteria)
This method sets the appropriate flags on a Persistent object after being retrieved from the database. |
static void |
updatePersistentFlagsOnUpdate(IPersistent object)
This method sets the appropriate flags on a Persistent object after being updated to the database. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
public static void executeAdd(IPersistent object,
DataSource dataSource)
throws SQLException,
IllegalAccessException,
InvocationTargetException,
IOException
object - The object to be added.dataSource - The DataSource to which the object will be added.
SQLException - if any database error occurs.
IllegalAccessException - if the Persistent class is not accessible for introspection.
InvocationTargetException - if the accessor method for the Persistent class throws an exception.
IOException - if any error occurs while extracting the value for an attribute.
public static void executeUpdate(IPersistent object,
DataSource dataSource)
throws SQLException,
IllegalAccessException,
InvocationTargetException,
IOException
object - The object to be updated.dataSource - The DataSource in which the object will be updated.
SQLException - if any database error occurs.
IllegalAccessException - if the Persistent class is not accessible for introspection.
InvocationTargetException - if the accessor method for the Persistent class throws an exception.
IOException - if any error occurs while extracting the value for an attribute.
public static void executeDelete(IPersistent object,
DataSource dataSource)
throws SQLException,
IllegalAccessException,
InvocationTargetException,
IOException
object - The object to be deleted.dataSource - The DataSource from which the object will be deleted.
SQLException - if any database error occurs.
IllegalAccessException - if the Persistent class is not accessible for introspection.
InvocationTargetException - if the accessor method for the Persistent class throws an exception.
IOException - if any error occurs while extracting the value for an attribute.
public static Collection executeQuery(Criteria criteria,
DataSource dataSource)
throws IOException,
SQLException,
PostLoadFailedException,
DataSourceCursorRuntimeException
criteria - The input Criteria.dataSource - The DataSource against which the query is to be executed.
IOException - if any error occurs while extracting the String from the criteria.
SQLException - if any database error occurs.
PostLoadFailedException - if any error is thrown in the PostLoad trigger of the persistent object.
DataSourceCursorRuntimeException - if any error occurs while molding the row into the Persistent object.
public static void executeStoredProcedure(IStoredProcedure sp,
DataSource dataSource)
throws SQLException,
IllegalAccessException,
InvocationTargetException,
IOException
sp - The Stored Procedure to execute.dataSource - The DataSource against which the Stored Procedure is to be executed.
SQLException - if any database error occurs.
IllegalAccessException - if the class is not accessible.
InvocationTargetException - if the accessor/mutator method for the Stored Procedure throws an exception.
IOException - if any error occurs in reading the data from the database.
public static void executeLock(IPersistent object,
DataSource dataSource)
throws SQLException,
IllegalAccessException,
InvocationTargetException,
IOException
object - The object to be locked.dataSource - The DataSource in which the object will be locked.
SQLException - if any database error occurs.
IllegalAccessException - if the Persistent class is not accessible for introspection.
InvocationTargetException - if the accessor method for the Persistent class throws an exception.
IOException - if any error occurs while extracting the value for an attribute.public static void updatePersistentFlagsOnAdd(IPersistent object)
object - the Persistent object.public static void updatePersistentFlagsOnUpdate(IPersistent object)
object - the Persistent object.public static void updatePersistentFlagsOnDelete(IPersistent object)
object - the Persistent object.
public static void updatePersistentFlagsOnQuery(IPersistent object,
Criteria criteria)
object - the Persistent object.criteria - the Criteria used for retrieving the object.public static void updatePersistentFlagsOnLock(IPersistent object)
object - the Persistent object.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||