publish 2.0.0.rc15
This commit is contained in:
@@ -29,24 +29,24 @@ public class TsCacheService {
|
||||
tsCacheHandler.put(key, value);
|
||||
}
|
||||
|
||||
public void put(String key, String value, long timeout) {
|
||||
tsCacheHandler.put(key, value, timeout);
|
||||
public void put(String key, String value, long seconds) {
|
||||
tsCacheHandler.put(key, value, seconds);
|
||||
}
|
||||
|
||||
public void putObj(String key, Object value, long timeout) {
|
||||
tsCacheHandler.put(key, JSONUtil.toJsonStr(value), timeout);
|
||||
public void putObj(String key, Object value, long seconds) {
|
||||
tsCacheHandler.put(key, JSONUtil.toJsonStr(value), seconds);
|
||||
}
|
||||
|
||||
public String get(String key) {
|
||||
return tsCacheHandler.get(key);
|
||||
}
|
||||
|
||||
public String get(String key, long timeout) {
|
||||
return tsCacheHandler.get(key, timeout);
|
||||
public String get(String key, long seconds) {
|
||||
return tsCacheHandler.get(key, seconds);
|
||||
}
|
||||
|
||||
public <T> T getObj(String key, Class<T> tClass, long timeout) {
|
||||
return JSONUtil.toBean(get(key, timeout), tClass, true);
|
||||
public <T> T getObj(String key, Class<T> tClass, long seconds) {
|
||||
return JSONUtil.toBean(get(key, seconds), tClass, true);
|
||||
}
|
||||
|
||||
public void remove(String key) {
|
||||
|
||||
Reference in New Issue
Block a user