public enum StorageCache extends Enum<StorageCache> implements org.aoju.bus.cache.metric.ExtendCache
| Enum Constant and Description |
|---|
INSTANCE
当前实例
|
| Modifier and Type | Method and Description |
|---|---|
void |
cache(String key,
String value)
存入缓存
|
void |
cache(String key,
String value,
long timeout)
存入缓存
|
Object |
get(String key)
获取缓存内容
|
static StorageCache |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static StorageCache[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final StorageCache INSTANCE
public static StorageCache[] values()
for (StorageCache c : StorageCache.values()) System.out.println(c);
public static StorageCache valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic void cache(String key, String value)
cache in interface org.aoju.bus.cache.metric.ExtendCachekey - 缓存keyvalue - 缓存内容public void cache(String key, String value, long timeout)
cache in interface org.aoju.bus.cache.metric.ExtendCachekey - 缓存keyvalue - 缓存内容timeout - 指定缓存过期时间(毫秒)Copyright © 2021. All rights reserved.