public class MetadataMortalCacheValue extends ImmortalCacheValue implements MetadataAware
MetadataMortalCacheEntry| Modifier and Type | Class and Description |
|---|---|
static class |
MetadataMortalCacheValue.Externalizer |
value| Constructor and Description |
|---|
MetadataMortalCacheValue(Object value,
Metadata metadata,
long created) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canExpire() |
long |
getCreated() |
long |
getExpiryTime() |
long |
getLifespan() |
Metadata |
getMetadata()
Get metadata of this cache entry.
|
boolean |
isExpired() |
boolean |
isExpired(long now) |
void |
setMetadata(Metadata metadata)
Set the metadata in the cache entry.
|
InternalCacheEntry |
toInternalCacheEntry(Object key) |
clone, equals, getLastUsed, getMaxIdle, getValue, hashCode, setValue, toStringpublic InternalCacheEntry toInternalCacheEntry(Object key)
toInternalCacheEntry in interface InternalCacheValuetoInternalCacheEntry in class ImmortalCacheValuepublic Metadata getMetadata()
MetadataAwaregetMetadata in interface InternalCacheValuegetMetadata in interface MetadataAwaregetMetadata in class ImmortalCacheValuepublic void setMetadata(Metadata metadata)
MetadataAwaresetMetadata in interface MetadataAwaremetadata - to apply to the cache entrypublic final long getCreated()
getCreated in interface InternalCacheValuegetCreated in class ImmortalCacheValuepublic final long getLifespan()
getLifespan in interface InternalCacheValuegetLifespan in class ImmortalCacheValuepublic boolean isExpired(long now)
isExpired in interface InternalCacheValueisExpired in class ImmortalCacheValuenow - the current time as expressed by System.currentTimeMillis()public boolean isExpired()
isExpired in interface InternalCacheValueisExpired in class ImmortalCacheValuepublic long getExpiryTime()
getExpiryTime in interface InternalCacheValuegetExpiryTime in class ImmortalCacheValuepublic final boolean canExpire()
canExpire in interface InternalCacheValuecanExpire in class ImmortalCacheValueCopyright © 2025 JBoss, a division of Red Hat. All rights reserved.