
public class SSMCacheManager extends Object implements org.springframework.cache.CacheManager, org.springframework.beans.factory.InitializingBean
Cache. Because using Spring Cache
and CacheManager it is not possible to pass expiration time to backend cache, default expiration time has to be set
in SSMCache.SSMCache(com.google.code.ssm.Cache, int, boolean). This expiration time is used for all store
requests.
Methods addCache(SSMCache) and removeCache(String) aren't thread safe.| Constructor and Description |
|---|
SSMCacheManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
addCache(SSMCache cache)
Adds new cache, registers also all aliases if set.
|
void |
afterPropertiesSet() |
SSMCache |
getCache(String name) |
Collection<String> |
getCacheNames() |
Collection<SSMCache> |
getCaches() |
void |
removeCache(String nameOrAlias)
Removes given cache and related aliases.
|
void |
setCaches(Collection<SSMCache> caches) |
public void afterPropertiesSet()
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanpublic Collection<String> getCacheNames()
getCacheNames in interface org.springframework.cache.CacheManagerpublic SSMCache getCache(String name)
getCache in interface org.springframework.cache.CacheManagerpublic void addCache(SSMCache cache)
cache - public void removeCache(String nameOrAlias)
name - the name or alias of a cachepublic void setCaches(Collection<SSMCache> caches)
@Generated(value="lombok") public Collection<SSMCache> getCaches()
Copyright © 2019. All rights reserved.