public interface CacheEntry<K,V> extends Cloneable, Map.Entry<K,V>, MetadataAware
Modifier and Type | Method and Description |
---|---|
CacheEntry<K,V> |
clone() |
void |
commit(DataContainer<K,V> container)
Commits changes
|
default long |
getCreated() |
default PrivateMetadata |
getInternalMetadata() |
K |
getKey()
Retrieves the key to this entry
|
default long |
getLastUsed() |
long |
getLifespan() |
long |
getMaxIdle() |
V |
getValue()
Retrieves the value of this entry
|
boolean |
isChanged() |
boolean |
isCreated() |
boolean |
isEvicted() |
boolean |
isNull()
Tests whether the entry represents a null value, typically used for repeatable read.
|
boolean |
isRemoved() |
void |
setChanged(boolean changed) |
void |
setCreated(boolean created) |
default void |
setCreated(long created) |
void |
setEvicted(boolean evicted) |
default void |
setInternalMetadata(PrivateMetadata metadata) |
default void |
setLastUsed(long lastUsed) |
void |
setRemoved(boolean removed) |
void |
setSkipLookup(boolean skipLookup)
See
skipLookup() . |
V |
setValue(V value)
Sets the value of the entry, returning the previous value
|
boolean |
skipLookup() |
comparingByKey, comparingByKey, comparingByValue, comparingByValue, equals, hashCode
getMetadata, setMetadata
boolean isNull()
boolean isChanged()
boolean isCreated()
boolean isRemoved()
boolean isEvicted()
K getKey()
V getValue()
long getLifespan()
long getMaxIdle()
boolean skipLookup()
true
if the value must not be fetch from an external sourcedefault long getCreated()
default long getLastUsed()
void commit(DataContainer<K,V> container)
container
- data container to commit tovoid setChanged(boolean changed)
void setCreated(boolean created)
void setRemoved(boolean removed)
void setEvicted(boolean evicted)
void setSkipLookup(boolean skipLookup)
skipLookup()
.skipLookup
- CacheEntry<K,V> clone()
default void setCreated(long created)
default void setLastUsed(long lastUsed)
default PrivateMetadata getInternalMetadata()
default void setInternalMetadata(PrivateMetadata metadata)
Copyright © 2021 JBoss by Red Hat. All rights reserved.