T
- public class CachedValue<T>
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static Logger |
LOGGER |
Constructor and Description |
---|
CachedValue() |
CachedValue(java.util.concurrent.Callable<T> reload) |
CachedValue(long expireTimeInMillis) |
CachedValue(long expireTimeInMillis,
java.util.concurrent.Callable<T> reload) |
Modifier and Type | Method and Description |
---|---|
protected void |
cleanValue() |
void |
expired() |
T |
get() |
long |
getExpireTime() |
protected T |
getValue() |
boolean |
isExpired() |
protected void |
reload() |
void |
resetAccess() |
void |
set(T value) |
void |
setExpireTime(long expireTimeInMillis) |
protected void |
setValue(T value) |
public CachedValue()
public CachedValue(long expireTimeInMillis)
public CachedValue(java.util.concurrent.Callable<T> reload)
public CachedValue(long expireTimeInMillis, java.util.concurrent.Callable<T> reload)
protected void reload()
protected final T getValue()
protected void setValue(T value)
public final boolean isExpired()
public final void set(T value)
public final void setExpireTime(long expireTimeInMillis)
public final long getExpireTime()
public final void resetAccess()
public final void expired()
protected void cleanValue()
public final T get()