Class NoOpCacheManager
java.lang.Object
org.springframework.cache.support.NoOpCacheManager
- All Implemented Interfaces:
- CacheManager
A basic, no operation 
CacheManager implementation suitable
 for disabling caching, typically used for backing cache declarations
 without an actual backing store.
 Will simply accept any items into the cache not actually storing them.
- Since:
- 3.1
- Author:
- Costin Leau, Stephane Nicoll
- See Also:
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionThis implementation always returns aCacheimplementation that will not store items.This implementation returns the name of the caches previously requested.
- 
Constructor Details- 
NoOpCacheManagerpublic NoOpCacheManager()
 
- 
- 
Method Details- 
getCacheThis implementation always returns aCacheimplementation that will not store items. Additionally, the request cache will be remembered by the manager for consistency.- Specified by:
- getCachein interface- CacheManager
- Parameters:
- name- the cache identifier (must not be- null)
- Returns:
- the associated cache, or nullif such a cache does not exist or could be not created
 
- 
getCacheNamesThis implementation returns the name of the caches previously requested.- Specified by:
- getCacheNamesin interface- CacheManager
- Returns:
- the names of all caches known by the cache manager
 
 
-