Package | Description |
---|---|
org.cache2k |
API package for cache2k Java caching library.
|
org.cache2k.event |
Events that are fired on behalf of a cache operation.
|
org.cache2k.spi |
Service provider interface that is used by the cache2k implementation.
|
Modifier and Type | Interface and Description |
---|---|
interface |
IntCache<V>
Deprecated.
will be removed in version 2.0
|
interface |
LongCache<V>
Deprecated.
will be removed in version 2.0
|
Modifier and Type | Class and Description |
---|---|
class |
AbstractCache<K,V>
Base class for implementations of the cache interface.
|
class |
ForwardingCache<K,V>
Wrapper class that forwards all method calls to a delegate.
|
Modifier and Type | Method and Description |
---|---|
Cache<K,V> |
Cache2kBuilder.build()
Builds a cache with the specified configuration parameters.
|
abstract <K,V> Cache<K,V> |
CacheManager.createCache(Cache2kConfiguration<K,V> cfg)
Create a new cache from the configuration.
|
protected abstract Cache<K,V> |
ForwardingCache.delegate()
Subclasses need to implement this method which specifies the delegation
target.
|
abstract <K,V> Cache<K,V> |
CacheManager.getCache(String name)
Return a known cache that must be created before via the
Cache2kBuilder
or CacheManager.createCache(Cache2kConfiguration) |
Modifier and Type | Method and Description |
---|---|
abstract Iterable<Cache> |
CacheManager.getActiveCaches()
Returns all open caches associated with this cache manager.
|
Modifier and Type | Method and Description |
---|---|
void |
CacheClosedListener.onCacheClosed(Cache cache)
Called when cache closes.
|
void |
CacheEntryCreatedListener.onEntryCreated(Cache<K,V> cache,
CacheEntry<K,V> entry)
Called for the creation of a cache entry and after all cache writers ran successfully.
|
void |
CacheEntryEvictedListener.onEntryEvicted(Cache<K,V> cache,
CacheEntry<K,V> entry)
Called upon eviction of a cache entry.
|
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 writers 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 writers ran successfully.
|
Modifier and Type | Method and Description |
---|---|
<K,V> Cache<K,V> |
Cache2kCoreProvider.createCache(CacheManager m,
Cache2kConfiguration<K,V> cfg)
Create a cache, apply external configuration before creating it.
|
cache2k API documentation. Copyright © 2000–2020 headissue GmbH, Munich.