public class SuppressCache<T>
extends java.lang.Object
限定符和类型 | 类和说明 |
---|---|
static class |
SuppressCache.Value |
限定符和类型 | 字段和说明 |
---|---|
protected java.util.concurrent.ConcurrentMap<T,SuppressCache.Value> |
map |
protected T |
NULL_KEY |
构造器和说明 |
---|
SuppressCache() |
限定符和类型 | 方法和说明 |
---|---|
void |
clear() |
SuppressCache.Value |
putIfAbsent(T key,
long expiry_time)
Adds a new key to the hashmap, or updates the Value associated with the existing key if present.
|
void |
removeAll(java.util.Collection<T> list) |
void |
removeExpired(long expiry_time) |
void |
retainAll(java.util.Collection<T> list) |
int |
size()
Returns the total count of all values
|
java.lang.String |
toString() |
protected final java.util.concurrent.ConcurrentMap<T,SuppressCache.Value> map
protected final T NULL_KEY
public SuppressCache.Value putIfAbsent(T key, long expiry_time)
key
- The keyexpiry_time
- Expiry time (in ms)public void clear()
public void retainAll(java.util.Collection<T> list)
public void removeAll(java.util.Collection<T> list)
public void removeExpired(long expiry_time)
public int size()
public java.lang.String toString()
toString
在类中 java.lang.Object