| |
|
| java.lang.Object java.util.AbstractMap com.opensymphony.oscache.base.algorithm.AbstractConcurrentReadCache com.opensymphony.oscache.base.algorithm.FIFOCache
Constructor Summary | |
public | FIFOCache() Constructs a FIFO Cache. | public | FIFOCache(int capacity) Constructs a FIFO Cache of the specified capacity. |
Method Summary | |
protected void | itemPut(Object key) An object was put in the cache. | protected void | itemRemoved(Object key) Remove specified key since that object has been removed from the cache. | protected void | itemRetrieved(Object key) An object was retrieved from the cache. | protected Object | removeItem() An item needs to be removed from the cache. |
FIFOCache | public FIFOCache()(Code) | | Constructs a FIFO Cache.
|
FIFOCache | public FIFOCache(int capacity)(Code) | | Constructs a FIFO Cache of the specified capacity.
Parameters: capacity - The maximum cache capacity. |
itemPut | protected void itemPut(Object key)(Code) | | An object was put in the cache. This implementation just adds
the key to the end of the list if it doesn't exist in the list
already.
Parameters: key - The cache key of the item that was put. |
itemRemoved | protected void itemRemoved(Object key)(Code) | | Remove specified key since that object has been removed from the cache.
Parameters: key - The cache key of the item that was removed. |
itemRetrieved | protected void itemRetrieved(Object key)(Code) | | An object was retrieved from the cache. This implementation
does noting since this event has no impact on the FIFO algorithm.
Parameters: key - The cache key of the item that was retrieved. |
removeItem | protected Object removeItem()(Code) | | An item needs to be removed from the cache. The FIFO implementation
removes the first element in the list (ie, the item that has been in
the cache for the longest time).
The key of whichever item was removed. |
|
|
|