Package es.bsc.dataclay.util.structs
Class LruCacheByDate<A,B>
- java.lang.Object
- 
- es.bsc.dataclay.util.structs.LruCacheByDate<A,B>
 
- 
- Type Parameters:
- A- Key element class
- B- Value element class
 
 public final class LruCacheByDate<A,B> extends Object Class that implements a simple LRU cache with specified max entries.
- 
- 
Constructor SummaryConstructors Constructor Description LruCacheByDate(int theMaxEntries)LruCache constructor
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcleanCache()Cleans expired entriesvoidclear()booleancontainsKey(A key)booleancontainsValue(B value)Set<Map.Entry<A,B>>entrySet()voidfinishCacheThreads()Finish cache threadsBget(A key)Set<A>keySet()Bput(A key, B value)voidputAll(Map<? extends A,? extends B> m)Bremove(A key)intsize()
 
- 
- 
- 
Method Detail- 
cleanCachepublic void cleanCache() Cleans expired entries
 - 
containsKeypublic boolean containsKey(A key) 
 - 
containsValuepublic boolean containsValue(B value) 
 - 
sizepublic int size() 
 - 
clearpublic void clear() 
 - 
finishCacheThreadspublic void finishCacheThreads() throws InterruptedExceptionFinish cache threads- Throws:
- InterruptedException- if shutdown was interrupted.
 
 
- 
 
-