Package com.google.common.cache
Class LocalCache.StrongAccessEntry<K,V>
- java.lang.Object
-
- com.google.common.cache.LocalCache.AbstractReferenceEntry<K,V>
-
- com.google.common.cache.LocalCache.StrongEntry<K,V>
-
- com.google.common.cache.LocalCache.StrongAccessEntry<K,V>
-
- All Implemented Interfaces:
LocalCache.ReferenceEntry<K,V>
- Enclosing class:
- LocalCache<K,V>
static final class LocalCache.StrongAccessEntry<K,V> extends LocalCache.StrongEntry<K,V>
-
-
Field Summary
Fields Modifier and Type Field Description (package private) long
accessTime
(package private) LocalCache.ReferenceEntry<K,V>
nextAccess
(package private) LocalCache.ReferenceEntry<K,V>
previousAccess
-
Fields inherited from class com.google.common.cache.LocalCache.StrongEntry
hash, key, next, valueReference
-
-
Constructor Summary
Constructors Constructor Description StrongAccessEntry(K key, int hash, LocalCache.ReferenceEntry<K,V> next)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getAccessTime()
Returns the time that this entry was last accessed, in ns.LocalCache.ReferenceEntry<K,V>
getNextInAccessQueue()
Returns the next entry in the access queue.LocalCache.ReferenceEntry<K,V>
getPreviousInAccessQueue()
Returns the previous entry in the access queue.void
setAccessTime(long time)
Sets the entry access time in ns.void
setNextInAccessQueue(LocalCache.ReferenceEntry<K,V> next)
Sets the next entry in the access queue.void
setPreviousInAccessQueue(LocalCache.ReferenceEntry<K,V> previous)
Sets the previous entry in the access queue.-
Methods inherited from class com.google.common.cache.LocalCache.StrongEntry
getHash, getKey, getNext, getValueReference, setValueReference
-
Methods inherited from class com.google.common.cache.LocalCache.AbstractReferenceEntry
getNextInWriteQueue, getPreviousInWriteQueue, getWriteTime, setNextInWriteQueue, setPreviousInWriteQueue, setWriteTime
-
-
-
-
Field Detail
-
accessTime
volatile long accessTime
-
nextAccess
LocalCache.ReferenceEntry<K,V> nextAccess
-
previousAccess
LocalCache.ReferenceEntry<K,V> previousAccess
-
-
Constructor Detail
-
StrongAccessEntry
StrongAccessEntry(K key, int hash, @Nullable LocalCache.ReferenceEntry<K,V> next)
-
-
Method Detail
-
getAccessTime
public long getAccessTime()
Description copied from interface:LocalCache.ReferenceEntry
Returns the time that this entry was last accessed, in ns.- Specified by:
getAccessTime
in interfaceLocalCache.ReferenceEntry<K,V>
- Overrides:
getAccessTime
in classLocalCache.AbstractReferenceEntry<K,V>
-
setAccessTime
public void setAccessTime(long time)
Description copied from interface:LocalCache.ReferenceEntry
Sets the entry access time in ns.- Specified by:
setAccessTime
in interfaceLocalCache.ReferenceEntry<K,V>
- Overrides:
setAccessTime
in classLocalCache.AbstractReferenceEntry<K,V>
-
getNextInAccessQueue
public LocalCache.ReferenceEntry<K,V> getNextInAccessQueue()
Description copied from interface:LocalCache.ReferenceEntry
Returns the next entry in the access queue.- Specified by:
getNextInAccessQueue
in interfaceLocalCache.ReferenceEntry<K,V>
- Overrides:
getNextInAccessQueue
in classLocalCache.AbstractReferenceEntry<K,V>
-
setNextInAccessQueue
public void setNextInAccessQueue(LocalCache.ReferenceEntry<K,V> next)
Description copied from interface:LocalCache.ReferenceEntry
Sets the next entry in the access queue.- Specified by:
setNextInAccessQueue
in interfaceLocalCache.ReferenceEntry<K,V>
- Overrides:
setNextInAccessQueue
in classLocalCache.AbstractReferenceEntry<K,V>
-
getPreviousInAccessQueue
public LocalCache.ReferenceEntry<K,V> getPreviousInAccessQueue()
Description copied from interface:LocalCache.ReferenceEntry
Returns the previous entry in the access queue.- Specified by:
getPreviousInAccessQueue
in interfaceLocalCache.ReferenceEntry<K,V>
- Overrides:
getPreviousInAccessQueue
in classLocalCache.AbstractReferenceEntry<K,V>
-
setPreviousInAccessQueue
public void setPreviousInAccessQueue(LocalCache.ReferenceEntry<K,V> previous)
Description copied from interface:LocalCache.ReferenceEntry
Sets the previous entry in the access queue.- Specified by:
setPreviousInAccessQueue
in interfaceLocalCache.ReferenceEntry<K,V>
- Overrides:
setPreviousInAccessQueue
in classLocalCache.AbstractReferenceEntry<K,V>
-
-