public class AuthCache<K,V> extends java.lang.Object implements AuthCacheMBean
| Modifier | Constructor and Description |
|---|---|
protected |
AuthCache(java.lang.String name,
java.util.function.Consumer<java.lang.Integer> setValidityDelegate,
java.util.function.Supplier<java.lang.Integer> getValidityDelegate,
java.util.function.Consumer<java.lang.Integer> setUpdateIntervalDelegate,
java.util.function.Supplier<java.lang.Integer> getUpdateIntervalDelegate,
java.util.function.Consumer<java.lang.Integer> setMaxEntriesDelegate,
java.util.function.Supplier<java.lang.Integer> getMaxEntriesDelegate,
java.util.function.Function<K,V> loadFunction,
java.util.function.Supplier<java.lang.Boolean> enableCache) |
| Modifier and Type | Method and Description |
|---|---|
V |
get(K k) |
int |
getMaxEntries() |
protected java.lang.String |
getObjectName() |
int |
getUpdateInterval() |
int |
getValidity() |
protected void |
init() |
void |
invalidate() |
void |
invalidate(K k) |
void |
setMaxEntries(int maxEntries) |
void |
setUpdateInterval(int updateInterval) |
void |
setValidity(int validityPeriod) |
protected AuthCache(java.lang.String name,
java.util.function.Consumer<java.lang.Integer> setValidityDelegate,
java.util.function.Supplier<java.lang.Integer> getValidityDelegate,
java.util.function.Consumer<java.lang.Integer> setUpdateIntervalDelegate,
java.util.function.Supplier<java.lang.Integer> getUpdateIntervalDelegate,
java.util.function.Consumer<java.lang.Integer> setMaxEntriesDelegate,
java.util.function.Supplier<java.lang.Integer> getMaxEntriesDelegate,
java.util.function.Function<K,V> loadFunction,
java.util.function.Supplier<java.lang.Boolean> enableCache)
protected void init()
protected java.lang.String getObjectName()
public void invalidate()
invalidate in interface AuthCacheMBeanpublic void invalidate(K k)
public void setValidity(int validityPeriod)
setValidity in interface AuthCacheMBeanpublic int getValidity()
getValidity in interface AuthCacheMBeanpublic void setUpdateInterval(int updateInterval)
setUpdateInterval in interface AuthCacheMBeanpublic int getUpdateInterval()
getUpdateInterval in interface AuthCacheMBeanpublic void setMaxEntries(int maxEntries)
setMaxEntries in interface AuthCacheMBeanpublic int getMaxEntries()
getMaxEntries in interface AuthCacheMBeanCopyright © 2009-2022 The Apache Software Foundation