Package | Description |
---|---|
org.cache2k | |
org.cache2k.event | |
org.cache2k.expiry |
Set of interfaces for customizing the expiry behavior.
|
org.cache2k.integration | |
org.cache2k.processor |
Modifier and Type | Method and Description |
---|---|
CacheEntry<K,V> |
Cache.getEntry(K key)
Returns an entry associated by the given key, that contains a non expired value.
|
CacheEntry<K,V> |
Cache.peekEntry(K key)
Returns an entry associated by the given key, that contains a non expired value.
|
Modifier and Type | Method and Description |
---|---|
Iterable<CacheEntry<K,V>> |
Cache.entries()
Iterate all entries in the cache.
|
Iterator<CacheEntry<K,V>> |
Cache.iterator()
Deprecated.
use
Cache.keys() |
Modifier and Type | Method and Description |
---|---|
long |
EntryExpiryCalculator.calculateExpiryTime(K _key,
V _value,
long _loadTime,
CacheEntry<K,V> _oldEntry)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
List<V> |
BulkCacheSource.getValues(List<CacheEntry<K,V>> entries,
long currentTime)
Deprecated.
Retrieve the values for the given cache entries.
|
Modifier and Type | Method and Description |
---|---|
void |
CacheEntryCreatedListener.onEntryCreated(Cache<K,V> cache,
CacheEntry<K,V> entry)
Called after a creation of a cache entry and after all cache writer ran successfully.
|
void |
CacheEntryExpiredListener.onEntryExpired(Cache<K,V> cache,
CacheEntry<K,V> entry)
Called after the expiry of an entry.
|
void |
CacheEntryRemovedListener.onEntryRemoved(Cache<K,V> cache,
CacheEntry<K,V> entry)
Called after the removal of a cache entry and after all cache writer ran successfully.
|
void |
CacheEntryUpdatedListener.onEntryUpdated(Cache<K,V> cache,
CacheEntry<K,V> currentEntry,
CacheEntry<K,V> entryWithNewData)
Called after a mutation of a cache entry and after all cache writer ran successfully.
|
void |
CacheEntryUpdatedListener.onEntryUpdated(Cache<K,V> cache,
CacheEntry<K,V> currentEntry,
CacheEntry<K,V> entryWithNewData)
Called after a mutation of a cache entry and after all cache writer ran successfully.
|
Modifier and Type | Method and Description |
---|---|
long |
ExpiryPolicy.calculateExpiryTime(K key,
V value,
long loadTime,
CacheEntry<K,V> oldEntry)
Returns the time of expiry in milliseconds since epoch.
|
Modifier and Type | Method and Description |
---|---|
abstract V |
AdvancedCacheLoader.load(K key,
long currentTime,
CacheEntry<K,V> currentEntry)
Retrieves or generates data based on the key.
|
abstract long |
ResiliencePolicy.suppressExceptionUntil(K key,
ExceptionInformation exceptionInformation,
CacheEntry<K,V> cachedContent)
Called after the loader threw an exception and a previous value is available.
|
Modifier and Type | Interface and Description |
---|---|
interface |
MutableCacheEntry<K,V>
A mutable entry is used inside the
EntryProcessor to perform
updates and retrieve information if the entry is existing in the cache. |
cache2k API documentation. Copyright © 2000–2016 headissue GmbH, Munich.