Package org.keycloak.storage
Class CacheableStorageProviderModel
- java.lang.Object
-
- org.keycloak.component.ComponentModel
-
- org.keycloak.component.PrioritizedComponentModel
-
- org.keycloak.storage.CacheableStorageProviderModel
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ClientScopeStorageProviderModel
,ClientStorageProviderModel
,GroupStorageProviderModel
,RoleStorageProviderModel
,UserStorageProviderModel
public class CacheableStorageProviderModel extends PrioritizedComponentModel
- Version:
- $Revision: 1 $
- Author:
- Bill Burke
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CacheableStorageProviderModel.CachePolicy
-
Field Summary
Fields Modifier and Type Field Description static String
CACHE_INVALID_BEFORE
static String
CACHE_POLICY
static String
ENABLED
static String
EVICTION_DAY
static String
EVICTION_HOUR
static String
EVICTION_MINUTE
static String
MAX_LIFESPAN
-
Fields inherited from class org.keycloak.component.PrioritizedComponentModel
comparator, PRIORITY
-
-
Constructor Summary
Constructors Constructor Description CacheableStorageProviderModel()
CacheableStorageProviderModel(ComponentModel copy)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static long
dailyEvictionBoundary(int hour, int minute)
static long
dailyTimeout(int hour, int minute)
long
getCacheInvalidBefore()
CacheableStorageProviderModel.CachePolicy
getCachePolicy()
int
getEvictionDay()
int
getEvictionHour()
int
getEvictionMinute()
long
getLifespan()
long
getMaxLifespan()
boolean
isEnabled()
void
setCacheInvalidBefore(long cacheInvalidBefore)
void
setCachePolicy(CacheableStorageProviderModel.CachePolicy cachePolicy)
void
setEnabled(boolean flag)
void
setEvictionDay(int evictionDay)
void
setEvictionHour(int evictionHour)
void
setEvictionMinute(int evictionMinute)
void
setMaxLifespan(long maxLifespan)
boolean
shouldInvalidate(CachedObject cached)
static long
weeklyTimeout(int day, int hour, int minute)
-
Methods inherited from class org.keycloak.component.PrioritizedComponentModel
getPriority, parsePriority, setPriority
-
Methods inherited from class org.keycloak.component.ComponentModel
contains, get, get, get, get, get, getConfig, getId, getName, getNote, getParentId, getProviderId, getProviderType, getSubType, hasNote, put, put, put, put, removeNote, setConfig, setId, setName, setNote, setParentId, setProviderId, setProviderType, setSubType
-
-
-
-
Field Detail
-
CACHE_POLICY
public static final String CACHE_POLICY
- See Also:
- Constant Field Values
-
MAX_LIFESPAN
public static final String MAX_LIFESPAN
- See Also:
- Constant Field Values
-
EVICTION_HOUR
public static final String EVICTION_HOUR
- See Also:
- Constant Field Values
-
EVICTION_MINUTE
public static final String EVICTION_MINUTE
- See Also:
- Constant Field Values
-
EVICTION_DAY
public static final String EVICTION_DAY
- See Also:
- Constant Field Values
-
CACHE_INVALID_BEFORE
public static final String CACHE_INVALID_BEFORE
- See Also:
- Constant Field Values
-
ENABLED
public static final String ENABLED
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
CacheableStorageProviderModel
public CacheableStorageProviderModel()
-
CacheableStorageProviderModel
public CacheableStorageProviderModel(ComponentModel copy)
-
-
Method Detail
-
getCachePolicy
public CacheableStorageProviderModel.CachePolicy getCachePolicy()
-
setCachePolicy
public void setCachePolicy(CacheableStorageProviderModel.CachePolicy cachePolicy)
-
getMaxLifespan
public long getMaxLifespan()
-
setMaxLifespan
public void setMaxLifespan(long maxLifespan)
-
getEvictionHour
public int getEvictionHour()
-
setEvictionHour
public void setEvictionHour(int evictionHour)
-
getEvictionMinute
public int getEvictionMinute()
-
setEvictionMinute
public void setEvictionMinute(int evictionMinute)
-
getEvictionDay
public int getEvictionDay()
-
setEvictionDay
public void setEvictionDay(int evictionDay)
-
getCacheInvalidBefore
public long getCacheInvalidBefore()
-
setCacheInvalidBefore
public void setCacheInvalidBefore(long cacheInvalidBefore)
-
setEnabled
public void setEnabled(boolean flag)
-
isEnabled
public boolean isEnabled()
-
getLifespan
public long getLifespan()
-
shouldInvalidate
public boolean shouldInvalidate(CachedObject cached)
-
dailyTimeout
public static long dailyTimeout(int hour, int minute)
-
dailyEvictionBoundary
public static long dailyEvictionBoundary(int hour, int minute)
-
weeklyTimeout
public static long weeklyTimeout(int day, int hour, int minute)
-
-