public class LruMemoryCacheStrategy<K,V> extends MemoryCacheStrategy<K,V>
As all MemoryCacheStrategys this cache is thread-safe.
| Modifier and Type | Field and Description |
|---|---|
static String |
ALIAS
Aliased used by provider for this implementation
|
static int |
DEFAULT_SIZE
Default cache size if no capacity is specified by the constructor.
|
| Constructor and Description |
|---|
LruMemoryCacheStrategy()
Constructs a
LruMemoryCacheStrategy and sets the default size up
to DEFAULT_SIZE |
LruMemoryCacheStrategy(int cacheSize)
Constructs a new
LruMemoryCacheStrategy and sets the cache size. |
public static final String ALIAS
public static final int DEFAULT_SIZE
public LruMemoryCacheStrategy()
LruMemoryCacheStrategy and sets the default size up
to DEFAULT_SIZEpublic LruMemoryCacheStrategy(int cacheSize)
LruMemoryCacheStrategy and sets the cache size.cacheSize - Cache size. It must be greater than 0.Copyright © 2008-2013. All Rights Reserved.