|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.ejb.plugins.cmp.jdbc.ReadAheadCache
public final class ReadAheadCache
ReadAheadCache stores all of the data readahead for an entity. Data is stored in the JDBCStoreManager entity tx data map on a per entity basis. The read ahead data for each entity is stored with a soft reference.
Nested Class Summary | |
---|---|
static class |
ReadAheadCache.EntityReadAheadInfo
|
Constructor Summary | |
---|---|
ReadAheadCache(JDBCStoreManager manager)
|
Method Summary | |
---|---|
void |
addFinderResults(List results,
JDBCReadAheadMetaData readahead)
|
void |
addPreloadData(Object pk,
JDBCFieldBridge field,
Object fieldValue)
Add preloaded data for an entity within the scope of a transaction |
void |
create()
|
void |
destroy()
|
Collection |
getCachedCMRValue(Object pk,
JDBCCMRFieldBridge cmrField)
Returns the cached value of a CMR field or null if nothing was cached for this field. |
ReadAheadCache.EntityReadAheadInfo |
getEntityReadAheadInfo(Object pk)
|
Map |
getPreloadDataMap(Object entityPrimaryKey,
boolean create)
Gets the map of preloaded data. |
boolean |
load(EntityEnterpriseContext ctx)
Loads all of the preloaded data for the ctx into it. |
void |
removeCachedData(Object primaryKey)
|
void |
start()
|
void |
stop()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ReadAheadCache(JDBCStoreManager manager)
Method Detail |
---|
public void create()
public void start()
public void stop()
public void destroy()
public void addFinderResults(List results, JDBCReadAheadMetaData readahead)
public ReadAheadCache.EntityReadAheadInfo getEntityReadAheadInfo(Object pk)
public boolean load(EntityEnterpriseContext ctx)
ctx
- the context that will be loaded
public Collection getCachedCMRValue(Object pk, JDBCCMRFieldBridge cmrField)
pk
- primary key.cmrField
- the field to get the cached value for.
cmrField
or null if no value cached.public void addPreloadData(Object pk, JDBCFieldBridge field, Object fieldValue)
public void removeCachedData(Object primaryKey)
public Map getPreloadDataMap(Object entityPrimaryKey, boolean create)
entityPrimaryKey
- the primary key of the entitycreate
- should a new preload data map be created if one is not found
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |