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 AuthCacheMBean
public void invalidate(K k)
public void setValidity(int validityPeriod)
setValidity
in interface AuthCacheMBean
public int getValidity()
getValidity
in interface AuthCacheMBean
public void setUpdateInterval(int updateInterval)
setUpdateInterval
in interface AuthCacheMBean
public int getUpdateInterval()
getUpdateInterval
in interface AuthCacheMBean
public void setMaxEntries(int maxEntries)
setMaxEntries
in interface AuthCacheMBean
public int getMaxEntries()
getMaxEntries
in interface AuthCacheMBean
Copyright © 2009-2022 The Apache Software Foundation