类 GuavaUtils
java.lang.Object
org.tio.utils.guava.GuavaUtils
- 作者:
- tanyaowu 2017年8月4日 下午5:42:37
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static <K,V> com.google.common.cache.LoadingCache<K, V> createLoadingCache(Integer concurrencyLevel, Long timeToLiveSeconds, Long timeToIdleSeconds, Integer initialCapacity, Integer maximumSize, boolean recordStats) static <K,V> com.google.common.cache.LoadingCache<K, V> createLoadingCache(Integer concurrencyLevel, Long timeToLiveSeconds, Long timeToIdleSeconds, Integer initialCapacity, Integer maximumSize, boolean recordStats, com.google.common.cache.RemovalListener<K, V> removalListener)
-
构造器详细资料
-
GuavaUtils
public GuavaUtils()
-
-
方法详细资料
-
createLoadingCache
public static <K,V> com.google.common.cache.LoadingCache<K,V> createLoadingCache(Integer concurrencyLevel, Long timeToLiveSeconds, Long timeToIdleSeconds, Integer initialCapacity, Integer maximumSize, boolean recordStats) - 参数:
concurrencyLevel-timeToLiveSeconds- 设置写缓存后过期时间(单位:秒)timeToIdleSeconds- 设置读缓存后过期时间(单位:秒)initialCapacity-maximumSize-recordStats-- 返回:
-
createLoadingCache
public static <K,V> com.google.common.cache.LoadingCache<K,V> createLoadingCache(Integer concurrencyLevel, Long timeToLiveSeconds, Long timeToIdleSeconds, Integer initialCapacity, Integer maximumSize, boolean recordStats, com.google.common.cache.RemovalListener<K, V> removalListener) - 参数:
concurrencyLevel-timeToLiveSeconds- 设置写缓存后过期时间(单位:秒)timeToIdleSeconds- 设置读缓存后过期时间(单位:秒)initialCapacity-maximumSize-recordStats-removalListener-- 返回:
-