public class EhCacheImpl extends Object implements CacheImpl
Ehcache is an open source, standards-based cache used to boost performance, offload the database and simplify scalability. Ehcache is robust, proven and full-featured and this has made it the most widely-used Java-based cache.
Expiration is specified in secondsModifier and Type | Method and Description |
---|---|
void |
add(String key,
Object value,
int expiration) |
void |
clear() |
long |
decr(String key,
int by) |
void |
delete(String key) |
Object |
get(String key) |
Map<String,Object> |
get(String[] keys) |
static EhCacheImpl |
getInstance() |
long |
incr(String key,
int by) |
static EhCacheImpl |
newInstance() |
void |
replace(String key,
Object value,
int expiration) |
boolean |
safeAdd(String key,
Object value,
int expiration) |
boolean |
safeDelete(String key) |
boolean |
safeReplace(String key,
Object value,
int expiration) |
boolean |
safeSet(String key,
Object value,
int expiration) |
void |
set(String key,
Object value,
int expiration) |
void |
stop() |
public static EhCacheImpl getInstance()
public static EhCacheImpl newInstance()
public boolean safeDelete(String key)
safeDelete
in interface CacheImpl
public boolean safeReplace(String key, Object value, int expiration)
safeReplace
in interface CacheImpl
Guillaume Bort & zenexity - Distributed under Apache 2 licence, without any warrantly