Package com.google.common.cache
Class LocalCache.AbstractReferenceEntry<K,V>
java.lang.Object
com.google.common.cache.LocalCache.AbstractReferenceEntry<K,V>
- All Implemented Interfaces:
ReferenceEntry<K,V>
- Direct Known Subclasses:
LocalCache.StrongEntry
- Enclosing class:
- LocalCache<K,
V>
abstract static class LocalCache.AbstractReferenceEntry<K,V>
extends Object
implements ReferenceEntry<K,V>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the time that this entry was last accessed, in ns.intgetHash()Returns the entry's hash.getKey()Returns the key for this entry.getNext()Returns the next entry in the chain.Returns the next entry in the access queue.Returns the next entry in the write queue.Returns the previous entry in the access queue.Returns the previous entry in the write queue.Returns the value reference from this entry.longvoidsetAccessTime(long time) Sets the entry access time in ns.voidsetNextInAccessQueue(ReferenceEntry<K, V> next) Sets the next entry in the access queue.voidsetNextInWriteQueue(ReferenceEntry<K, V> next) Sets the next entry in the write queue.voidsetPreviousInAccessQueue(ReferenceEntry<K, V> previous) Sets the previous entry in the access queue.voidsetPreviousInWriteQueue(ReferenceEntry<K, V> previous) Sets the previous entry in the write queue.voidsetValueReference(LocalCache.ValueReference<K, V> valueReference) Sets the value reference for this entry.voidsetWriteTime(long time) Sets the entry write time in ns.
-
Constructor Details
-
AbstractReferenceEntry
AbstractReferenceEntry()
-
-
Method Details
-
getValueReference
Description copied from interface:ReferenceEntryReturns the value reference from this entry.- Specified by:
getValueReferencein interfaceReferenceEntry<K,V>
-
setValueReference
Description copied from interface:ReferenceEntrySets the value reference for this entry.- Specified by:
setValueReferencein interfaceReferenceEntry<K,V>
-
getNext
Description copied from interface:ReferenceEntryReturns the next entry in the chain.- Specified by:
getNextin interfaceReferenceEntry<K,V>
-
getHash
public int getHash()Description copied from interface:ReferenceEntryReturns the entry's hash.- Specified by:
getHashin interfaceReferenceEntry<K,V>
-
getKey
Description copied from interface:ReferenceEntryReturns the key for this entry.- Specified by:
getKeyin interfaceReferenceEntry<K,V>
-
getAccessTime
public long getAccessTime()Description copied from interface:ReferenceEntryReturns the time that this entry was last accessed, in ns.- Specified by:
getAccessTimein interfaceReferenceEntry<K,V>
-
setAccessTime
public void setAccessTime(long time) Description copied from interface:ReferenceEntrySets the entry access time in ns.- Specified by:
setAccessTimein interfaceReferenceEntry<K,V>
-
getNextInAccessQueue
Description copied from interface:ReferenceEntryReturns the next entry in the access queue.- Specified by:
getNextInAccessQueuein interfaceReferenceEntry<K,V>
-
setNextInAccessQueue
Description copied from interface:ReferenceEntrySets the next entry in the access queue.- Specified by:
setNextInAccessQueuein interfaceReferenceEntry<K,V>
-
getPreviousInAccessQueue
Description copied from interface:ReferenceEntryReturns the previous entry in the access queue.- Specified by:
getPreviousInAccessQueuein interfaceReferenceEntry<K,V>
-
setPreviousInAccessQueue
Description copied from interface:ReferenceEntrySets the previous entry in the access queue.- Specified by:
setPreviousInAccessQueuein interfaceReferenceEntry<K,V>
-
getWriteTime
public long getWriteTime()- Specified by:
getWriteTimein interfaceReferenceEntry<K,V>
-
setWriteTime
public void setWriteTime(long time) Description copied from interface:ReferenceEntrySets the entry write time in ns.- Specified by:
setWriteTimein interfaceReferenceEntry<K,V>
-
getNextInWriteQueue
Description copied from interface:ReferenceEntryReturns the next entry in the write queue.- Specified by:
getNextInWriteQueuein interfaceReferenceEntry<K,V>
-
setNextInWriteQueue
Description copied from interface:ReferenceEntrySets the next entry in the write queue.- Specified by:
setNextInWriteQueuein interfaceReferenceEntry<K,V>
-
getPreviousInWriteQueue
Description copied from interface:ReferenceEntryReturns the previous entry in the write queue.- Specified by:
getPreviousInWriteQueuein interfaceReferenceEntry<K,V>
-
setPreviousInWriteQueue
Description copied from interface:ReferenceEntrySets the previous entry in the write queue.- Specified by:
setPreviousInWriteQueuein interfaceReferenceEntry<K,V>
-