oracle.jbo.server
Class EntityCache
java.lang.Object
|
+--oracle.jbo.server.EntityCache
- public class EntityCache
- extends java.lang.Object
The EntityCache caches queried rows for a particular EntityImpl.
- Version:
- SDK
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EntityCache
public EntityCache()
- Constructor.
init
protected void init(DBTransactionImpl trans,
EntityDefImpl entityDef)
getEntityDef
protected EntityDefImpl getEntityDef()
add
protected EntityImpl add(EntityImpl srow)
- Add an Entity to the cache.
TODO: This really should check for conflicts between the
EntityDefImpl of the row and the cache.
- Parameters:
srow
- the row to be added.
removeRow
protected EntityImpl removeRow(EntityImpl srow)
- Remove a EntityImpl from the cache.
- Parameters:
srow
- the row to be removed.
clearCache
protected void clearCache()
addEntityListener
public void addEntityListener(EntityListener listener)
- Add an EntityListener.
- Parameters:
listener
- The object to be registered as listener.
removeEntityListener
public void removeEntityListener(EntityListener listener)
- Remove an EntityListener.
- Parameters:
listener
- The object to be removed from the list of listeners.
deliverEntityEvent
protected void deliverEntityEvent(EntityEvent event)
- Notify EntityListeners of a EntityImpl properties or state has changed.
- Parameters:
sRow
- The EntityImpl on which event has occurred.eventType
- The type of event.
replace
protected void replace(EntityImpl srow,
Key okey)
- Remove a row in cache and add it in using the new key values.
This is used when the key values changed by the user or from RETURNING
clause on INSERT or UPDATE.
- Parameters:
srow
- the row to be replaced.okey
- the original key.