This implementation uses a bounded MRU Map to limit the in-memory size of the cache. Thus the size of this cache never grows beyond the stated size.
| Modifier and Type | Field and Description |
|---|---|
| private transient LRUMap | |
| public static final int | |
| private final int |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public synchronized void | |
| public synchronized Object | |
| private void | |
| public synchronized Object | |
| private void | |
| public synchronized int |
| cache | back to summary |
|---|---|
| private transient LRUMap cache | |
| DEFAULT_STRONG_REF_COUNT | back to summary |
|---|---|
| public static final int DEFAULT_STRONG_REF_COUNT | |
| strongReferenceCount | back to summary |
|---|---|
| private final int strongReferenceCount | |
| SimpleMRUCache | back to summary |
|---|---|
| public SimpleMRUCache() | |
| SimpleMRUCache | back to summary |
|---|---|
| public SimpleMRUCache(int strongReferenceCount) | |
| clear | back to summary |
|---|---|
| public synchronized void clear() | |
| get | back to summary |
|---|---|
| public synchronized Object get(Object key) | |
| init | back to summary |
|---|---|
| private void init() | |
| put | back to summary |
|---|---|
| public synchronized Object put(Object key, Object value) | |
| readObject | back to summary |
|---|---|
| private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException | |
| size | back to summary |
|---|---|
| public synchronized int size() | |