Wrapper for a value inside a cache that adds timestamp information for expiration and prevents "cache storms" with a Lock. JMM happens-before is ensured with AtomicReference. Objects in cache are assumed to not change after publication.
Constructor and description |
---|
CacheEntry
(T value) |
Type | Name and description |
---|---|
T |
getValue(long timeout, java.security.PrivilegedAction<T> updater) |
Methods inherited from class | Name |
---|---|
class CacheEntry |
expire, getCreatedMillis, getValue, getValue, getValue, getValue, getValue, getValue, getValueWhileUpdating, hasExpired, isInitialized, resetTimestamp, setInitialized, setValue, shouldUpdate, updateValue |
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |