public class J2CacheFactory extends Object implements CacheFactory
| 构造器和说明 |
|---|
J2CacheFactory() |
| 限定符和类型 | 方法和说明 |
|---|---|
J2Cache |
getCache(String cacheName) |
AbsCache |
getCache(String cacheName,
boolean skipNull) |
Map<String,? extends AbsCache> |
getMap() |
AbsCache |
register(CacheName cacheName) |
AbsCache |
register(String cacheName,
Long timeToLiveSeconds,
Long timeToIdleSeconds)
注册并获取一个 Cache 实例。
|
<T> AbsCache |
register(String cacheName,
Long timeToLiveSeconds,
Long timeToIdleSeconds,
RemovalListenerWrapper<T> removalListenerWrapper) |
public AbsCache register(String cacheName, Long timeToLiveSeconds, Long timeToIdleSeconds)
CacheFactoryregister 在接口中 CacheFactorycacheName - 缓存名称timeToLiveSeconds - 存活时间(秒)timeToIdleSeconds - 空闲时间(秒)public <T> AbsCache register(String cacheName, Long timeToLiveSeconds, Long timeToIdleSeconds, RemovalListenerWrapper<T> removalListenerWrapper)
register 在接口中 CacheFactorypublic AbsCache getCache(String cacheName, boolean skipNull)
getCache 在接口中 CacheFactorypublic J2Cache getCache(String cacheName)
getCache 在接口中 CacheFactorypublic Map<String,? extends AbsCache> getMap()
getMap 在接口中 CacheFactorypublic AbsCache register(CacheName cacheName)
register 在接口中 CacheFactoryCopyright © 2024. All rights reserved.