|
dbXML API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Trigger represents a dbXML trigger. Triggers are class implementations that are capable of responding to Collection level events. Triggerrs are a fairly low level interface, and use Object instances to represent the data that is being reported. Depending on the type of Collection that is being monitored, the actual type of Object will be a DocumentTable (for Document collections) or a byte array (for Binary collections).
Method Summary | |
void |
afterDelete(Transaction tx,
Key key,
java.lang.Object oldObj)
afterDelete is fired after a Object is deleted from the Collection. |
void |
afterGet(Transaction tx,
Key key,
java.lang.Object obj)
afterGet is fired after a Object is retrieved from the Collection, but before it is actually returned. |
void |
afterInsert(Transaction tx,
Key key,
java.lang.Object newObj)
afterInsert is fired after a new Object is inserted into the Collection. |
void |
afterUpdate(Transaction tx,
Key key,
java.lang.Object oldObj,
java.lang.Object newObj)
afterUpdate is fired after a Object is updated in the Collection. |
void |
beforeDelete(Transaction tx,
Key key,
java.lang.Object oldObj)
beforeDelete is fired before a Object is deleted from the Collection. |
void |
beforeGet(Transaction tx,
Key key)
beforeGet is fired before a Object is retrieved from the Collection. |
java.lang.Object |
beforeInsert(Transaction tx,
Key key,
java.lang.Object newObj)
beforeInsert is fired before a new Object is inserted into the Collection. |
java.lang.Object |
beforeUpdate(Transaction tx,
Key key,
java.lang.Object oldObj,
java.lang.Object newObj)
beforeUpdate is fired before a Object is updated in the Collection. |
Collection |
getCollection()
getCollection returns the Collection context for this Trigger. |
java.lang.String |
getName()
getName returns the name of this Trigger. |
void |
setCollection(Collection collection)
setCollection sets the Collection context for this Trigger. |
Methods inherited from interface com.dbxml.util.Configurable |
getConfig, setConfig |
Method Detail |
public java.lang.String getName()
public void setCollection(Collection collection)
collection
- The Collectionpublic Collection getCollection()
public java.lang.Object beforeInsert(Transaction tx, Key key, java.lang.Object newObj) throws DBException
tx
- The controlling Transactionkey
- The Object KeynewObj
- The new Object
DBException
public void afterInsert(Transaction tx, Key key, java.lang.Object newObj) throws DBException
tx
- The controlling Transactionkey
- The Object KeynewObj
- The new Object
DBException
public java.lang.Object beforeUpdate(Transaction tx, Key key, java.lang.Object oldObj, java.lang.Object newObj) throws DBException
tx
- The controlling Transactionkey
- The Object KeyoldObj
- The old ObjectnewObj
- The new Object
DBException
public void afterUpdate(Transaction tx, Key key, java.lang.Object oldObj, java.lang.Object newObj) throws DBException
tx
- The controlling Transactionkey
- The Object KeyoldObj
- The old ObjectnewObj
- The new Object
DBException
public void beforeDelete(Transaction tx, Key key, java.lang.Object oldObj) throws DBException
tx
- The controlling Transactionkey
- The Object KeyoldObj
- The Object to be deleted
DBException
public void afterDelete(Transaction tx, Key key, java.lang.Object oldObj) throws DBException
tx
- The controlling Transactionkey
- The Object KeyoldObj
- The Object that was deleted
DBException
public void beforeGet(Transaction tx, Key key) throws DBException
tx
- The controlling Transactionkey
- The Object Key
DBException
public void afterGet(Transaction tx, Key key, java.lang.Object obj) throws DBException
tx
- The controlling Transactionkey
- The Object Key
DBException
|
dbXML API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |