|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.ojb.broker.cache.ObjectCacheSoftImpl
A global ObjectCache implementation.
| Nested Class Summary | |
static class |
ObjectCacheSoftImpl.SoftHashMap
Kind of map using SoftReference to store values |
| Constructor Summary | |
ObjectCacheSoftImpl(PersistenceBroker broker,
java.util.Properties properties)
Constructor called by ojb |
|
| Method Summary | |
void |
cache(Identity oid,
java.lang.Object obj)
Used to cache objects by it's Identity. |
boolean |
cacheIfNew(Identity oid,
java.lang.Object obj)
|
void |
clear()
Clear the cache. |
void |
configure(org.apache.ojb.broker.util.configuration.Configuration configuration)
|
java.lang.Object |
lookup(Identity oid)
Lookup object with Identity 'oid' in cache. |
void |
remove(Identity oid)
Removes an Object from the cache. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ObjectCacheSoftImpl(PersistenceBroker broker,
java.util.Properties properties)
broker - ignored parameterproperties - ignored parameter| Method Detail |
public void configure(org.apache.ojb.broker.util.configuration.Configuration configuration)
throws org.apache.ojb.broker.util.configuration.ConfigurationException
configure in interface org.apache.ojb.broker.util.configuration.Configurableorg.apache.ojb.broker.util.configuration.ConfigurationExceptionConfigurable.configure(org.apache.ojb.broker.util.configuration.Configuration)
public void cache(Identity oid,
java.lang.Object obj)
ObjectCacheIdentity.
cache in interface ObjectCacheoid - Identity of the object to cache.obj - The object to cache.ObjectCache.cache(org.apache.ojb.broker.Identity, java.lang.Object)
public boolean cacheIfNew(Identity oid,
java.lang.Object obj)
public java.lang.Object lookup(Identity oid)
ObjectCache
lookup in interface ObjectCacheoid - Identity of the object to search for.
Identity is found.ObjectCache.lookup(org.apache.ojb.broker.Identity)public void remove(Identity oid)
ObjectCache
remove in interface ObjectCacheoid - Identity of the object to be removed.ObjectCache.remove(org.apache.ojb.broker.Identity)public void clear()
ObjectCache
clear in interface ObjectCacheObjectCache.clear()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||