| 程序包 | 说明 |
|---|---|
| org.springframework.cache |
Spring's generic cache abstraction.
|
| org.springframework.cache.concurrent |
Implementation package for
java.util.concurrent based caches. |
| org.springframework.cache.interceptor |
AOP-based solution for declarative caching demarcation.
|
| org.springframework.cache.support |
Support classes for the org.springframework.cache package.
|
| 限定符和类型 | 方法和说明 |
|---|---|
Cache |
CacheManager.getCache(String name)
Return the cache associated with the given name.
|
| 限定符和类型 | 类和说明 |
|---|---|
class |
ConcurrentMapCache
Simple
Cache implementation based on the
core JDK java.util.concurrent package. |
| 限定符和类型 | 方法和说明 |
|---|---|
protected Cache |
ConcurrentMapCacheManager.createConcurrentMapCache(String name)
Create a new ConcurrentMapCache instance for the specified cache name.
|
Cache |
ConcurrentMapCacheManager.getCache(String name) |
| 限定符和类型 | 方法和说明 |
|---|---|
protected Collection<? extends Cache> |
CacheAspectSupport.CacheOperationContext.getCaches() |
protected Collection<? extends Cache> |
CacheAspectSupport.getCaches(CacheOperationInvocationContext<CacheOperation> context,
CacheResolver cacheResolver) |
Collection<? extends Cache> |
AbstractCacheResolver.resolveCaches(CacheOperationInvocationContext<?> context) |
Collection<? extends Cache> |
CacheResolver.resolveCaches(CacheOperationInvocationContext<?> context)
Return the cache(s) to use for the specified invocation.
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
AbstractCacheInvoker.doClear(Cache cache)
|
protected void |
AbstractCacheInvoker.doEvict(Cache cache,
Object key)
Execute
evict(Object) on the specified Cache and
invoke the error handler if an exception occurs. |
protected Cache.ValueWrapper |
AbstractCacheInvoker.doGet(Cache cache,
Object key)
Execute
get(Object) on the specified Cache and
invoke the error handler if an exception occurs. |
protected void |
AbstractCacheInvoker.doPut(Cache cache,
Object key,
Object result)
Execute
put(Object, Object) on the specified Cache
and invoke the error handler if an exception occurs. |
void |
CacheErrorHandler.handleCacheClearError(RuntimeException exception,
Cache cache)
Handle the given runtime exception thrown by the cache provider when
clearing the specified
Cache, possibly rethrowing it as a
fatal exception. |
void |
SimpleCacheErrorHandler.handleCacheClearError(RuntimeException exception,
Cache cache) |
void |
CacheErrorHandler.handleCacheEvictError(RuntimeException exception,
Cache cache,
Object key)
Handle the given runtime exception thrown by the cache provider when
clearing an item with the specified
key, possibly rethrowing
it as a fatal exception. |
void |
SimpleCacheErrorHandler.handleCacheEvictError(RuntimeException exception,
Cache cache,
Object key) |
void |
CacheErrorHandler.handleCacheGetError(RuntimeException exception,
Cache cache,
Object key)
Handle the given runtime exception thrown by the cache provider when
retrieving an item with the specified
key, possibly
rethrowing it as a fatal exception. |
void |
SimpleCacheErrorHandler.handleCacheGetError(RuntimeException exception,
Cache cache,
Object key) |
void |
CacheErrorHandler.handleCachePutError(RuntimeException exception,
Cache cache,
Object key,
Object value)
Handle the given runtime exception thrown by the cache provider when
updating an item with the specified
key and value,
possibly rethrowing it as a fatal exception. |
void |
SimpleCacheErrorHandler.handleCachePutError(RuntimeException exception,
Cache cache,
Object key,
Object value) |
| 限定符和类型 | 类和说明 |
|---|---|
class |
AbstractValueAdaptingCache
Common base class for
Cache implementations that need to adapt
null values (and potentially other such special values) before
passing them on to the underlying store. |
class |
NoOpCache
A no operation
Cache implementation suitable for disabling caching. |
| 限定符和类型 | 方法和说明 |
|---|---|
protected Cache |
AbstractCacheManager.decorateCache(Cache cache)
Decorate the given Cache object if necessary.
|
Cache |
AbstractCacheManager.getCache(String name) |
Cache |
CompositeCacheManager.getCache(String name) |
Cache |
NoOpCacheManager.getCache(String name)
This implementation always returns a
Cache implementation that will not store items. |
protected Cache |
AbstractCacheManager.getMissingCache(String name)
Return a missing cache with the specified
name or null if
such cache does not exist or could not be created on the fly. |
protected Cache |
AbstractCacheManager.lookupCache(String name)
Check for a registered cache of the given name.
|
| 限定符和类型 | 方法和说明 |
|---|---|
protected abstract Collection<? extends Cache> |
AbstractCacheManager.loadCaches()
Load the initial caches for this cache manager.
|
protected Collection<? extends Cache> |
SimpleCacheManager.loadCaches() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
AbstractCacheManager.addCache(Cache cache)
已过时。
as of Spring 4.3, in favor of
AbstractCacheManager.getMissingCache(String) |
protected Cache |
AbstractCacheManager.decorateCache(Cache cache)
Decorate the given Cache object if necessary.
|
| 限定符和类型 | 方法和说明 |
|---|---|
void |
SimpleCacheManager.setCaches(Collection<? extends Cache> caches)
Specify the collection of Cache instances to use for this CacheManager.
|