public interface CachePolicy
Policy
to indicate if continue alive.Modifier and Type | Field and Description |
---|---|
static long |
DEFAULT_INITIALDELAY |
static long |
DEFAULT_PERIOD |
static long |
DEFAULT_SIZE |
static long |
DEFAULT_SIZEOF |
static long |
DEFAULT_TTI |
static long |
DEFAULT_TTL |
Modifier and Type | Method and Description |
---|---|
boolean |
isAlive(long miliseconds)
Verify if cache is live indicating to discard the cache content.
|
boolean |
isAlive(long ttl,
long tti)
Verify if cache is live indicating to discard the cache content.
|
long |
size()
Returns the number of elements in cache.
|
long |
sizeof()
Returns the limit size of objects in cache.
|
static final long DEFAULT_TTL
static final long DEFAULT_TTI
static final long DEFAULT_SIZE
static final long DEFAULT_INITIALDELAY
static final long DEFAULT_PERIOD
static final long DEFAULT_SIZEOF
boolean isAlive(long miliseconds)
miliseconds
- time from object storedboolean isAlive(long ttl, long tti)
ttl
- time-to-live from stored object in secondstti
- time-to-idle for stored store in secondslong size()
long sizeof()
Copyright © 2012–2020 jkniv, copyleft code. All rights reserved.