public abstract class AbstractManagedDynamicCacheRegistry extends java.lang.Object implements Registry, ManagedDynamicCache, ElementUpdate
Modifier and Type | Field and Description |
---|---|
static java.lang.String | COPYRIGHT
IBM copyright notice field.
|
Constructor and Description |
---|
AbstractManagedDynamicCacheRegistry() |
Modifier and Type | Method and Description |
---|---|
void | addElement(java.lang.Object key, java.lang.Object cacheObject)
This method adds an element to the cache.
|
abstract java.lang.Object | createKey(java.lang.String strKey)
This method creates a cache key for this registry based on a string representation of the key.
|
abstract java.lang.String | createKeyString(TypedProperty prop)
This method creates a string representation of a cache key for this registry based on the input properties.
|
java.lang.Object | findObject(java.lang.Object key)
This method gets an object from the registry.
|
com.ibm.commerce.registry.LRUDynamicHashtable | getCache()
This method gets the cache.
|
int | getCacheSize()
This method returns the total number of cache entries.
|
java.lang.Object | getElement(java.lang.Object key)
This method gets an element from the cache.
|
int | getElementCount()
This method gets the current number of cached elements.
|
java.util.Enumeration | getElements()
This method gets an enumeration of all cached elements.
|
long | getEvictions()
This method returns the number of entries that have been removed from the cache by an LRU (least-recently-used) algorithm.
|
long | getHits()
This method returns the number of cache hits.
|
java.util.Enumeration | getKeys()
This method gets an enumeration of all cached keys.
|
long | getMisses()
This method returns the number of cache misses.
|
int | getUsedCacheSize()
This method returns the number of currently contained cache entries.
|
void | initialize()
This method initializes the registry.
|
abstract void | populate(com.ibm.commerce.registry.LRUDynamicHashtable aCache)
This method populates the cache object.
|
void | refresh()
This method refreshes all the elements in the cache.
|
void | removeAllElements()
This method removes all cached elements.
|
void | removeElement(java.lang.Object key)
This method removes an element from the cache.
|
abstract java.lang.Object | retrieve(java.lang.Object key)
This method retrieves an object from the database and adds it to the registry.
|
void | setCache(com.ibm.commerce.registry.LRUDynamicHashtable cache)
This method sets the cache.
|
void | setCacheSize(int size)
This method specifies the maximum cache size.
|
void | setInitialCapacity(int initialCapacity)
This method sets the initial capacity of the registry.
|
void | setLoadFactor(float loadFactor)
This method sets the load factor of the registry.
|
void | update(java.lang.String action, java.lang.Object key)
This method updates a cached element.
|
public static final java.lang.String COPYRIGHT
public abstract java.lang.Object retrieve(java.lang.Object key) throws java.lang.Exception
public abstract void populate(com.ibm.commerce.registry.LRUDynamicHashtable aCache) throws java.lang.Exception
public abstract java.lang.String createKeyString(TypedProperty prop) throws java.lang.Exception
public abstract java.lang.Object createKey(java.lang.String strKey) throws java.lang.Exception
public void addElement(java.lang.Object key, java.lang.Object cacheObject)
public java.lang.Object getElement(java.lang.Object key)
public java.util.Enumeration getElements()
public java.util.Enumeration getKeys()
public int getElementCount()
public java.lang.Object findObject(java.lang.Object key) throws java.lang.Exception
public void initialize() throws java.lang.Exception
public void refresh() throws java.lang.Exception
public void update(java.lang.String action, java.lang.Object key) throws java.lang.Exception
public void removeAllElements()
public void removeElement(java.lang.Object key)
public int getCacheSize()
public long getMisses()
public long getEvictions()
public long getHits()
public int getUsedCacheSize()
public void setCacheSize(int size)
public void setInitialCapacity(int initialCapacity)
public void setLoadFactor(float loadFactor)
public com.ibm.commerce.registry.LRUDynamicHashtable getCache()
public void setCache(com.ibm.commerce.registry.LRUDynamicHashtable cache)