com.bankframe.services.cache
Interface CachePolicy

All Known Subinterfaces:
ConfigurableCachePolicy
All Known Implementing Classes:
LruCachePolicy, NullPolicy, PerEntryTimeoutCachePolicy, TimeoutCachePolicy

public interface CachePolicy

This interface defines the methods that all cache policies must provide. A cache policy determines when values should be removed from the cache.

Author:
Engineering

Method Summary
 java.util.Set cleanup()
          This method returns a set containing the keys of values that have expired.
 boolean isCacheEntryValid(java.lang.Object key, java.lang.Object value)
          This method determines if the specified entry should be removed from the cache
 void remove(java.lang.Object key)
          This method signals the entry has been removed from the cache
 void remove(java.util.Set keySet)
          This method signals the set of entries has been removed from the cache
 void removeAll()
          This method signals that all entries have been removed from the cache
 void updateCacheEntries(java.util.Map values)
          This method updates all the specified values
 void updateCacheEntry(java.lang.Object key, java.lang.Object value)
          This method updates the last access time for the specified entry
 

Method Detail

cleanup

public java.util.Set cleanup()
This method returns a set containing the keys of values that have expired. If this method returns an empty set then there are no values to be removed. If this method returns a null value, then all values have expired


isCacheEntryValid

public boolean isCacheEntryValid(java.lang.Object key,
                                 java.lang.Object value)
This method determines if the specified entry should be removed from the cache


remove

public void remove(java.lang.Object key)
This method signals the entry has been removed from the cache


remove

public void remove(java.util.Set keySet)
This method signals the set of entries has been removed from the cache


removeAll

public void removeAll()
This method signals that all entries have been removed from the cache


updateCacheEntries

public void updateCacheEntries(java.util.Map values)
This method updates all the specified values


updateCacheEntry

public void updateCacheEntry(java.lang.Object key,
                             java.lang.Object value)
This method updates the last access time for the specified entry



Copyright © 2004 Siebel Systems, Inc. All rights reserved.