public class EhCacheCache extends Object implements org.springframework.cache.Cache
Cache implementation on top of an Ehcache instance.| Constructor and Description |
|---|
EhCacheCache(net.sf.ehcache.Ehcache ehcache)
Create an
EhCacheCache instance. |
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
void |
evict(Object key) |
org.springframework.cache.Cache.ValueWrapper |
get(Object key) |
<T> T |
get(Object key,
Class<T> type) |
String |
getName() |
net.sf.ehcache.Ehcache |
getNativeCache() |
void |
put(Object key,
Object value) |
public EhCacheCache(net.sf.ehcache.Ehcache ehcache)
EhCacheCache instance.ehcache - backing Ehcache instancepublic final String getName()
getName in interface org.springframework.cache.Cachepublic final net.sf.ehcache.Ehcache getNativeCache()
getNativeCache in interface org.springframework.cache.Cachepublic org.springframework.cache.Cache.ValueWrapper get(Object key)
get in interface org.springframework.cache.Cachepublic <T> T get(Object key, Class<T> type)
get in interface org.springframework.cache.Cachepublic void put(Object key, Object value)
put in interface org.springframework.cache.Cachepublic void evict(Object key)
evict in interface org.springframework.cache.Cachepublic void clear()
clear in interface org.springframework.cache.Cache