com.octo.android.robospice.persistence.memory
Class StringLruCache
java.lang.Object
com.octo.android.robospice.persistence.memory.LruCache<Object,CacheItem<String>>
com.octo.android.robospice.persistence.memory.StringLruCache
public class StringLruCache
- extends LruCache<Object,CacheItem<String>>
LruCache
for String
.
- Author:
- David Stemmer, Mike Jancola, SNI
Method Summary |
protected int |
sizeOf(Object key,
CacheItem<String> value)
Returns the size of the entry for key and value in
user-defined units. |
Methods inherited from class com.octo.android.robospice.persistence.memory.LruCache |
create, createCount, entryRemoved, evictAll, evictionCount, get, hitCount, maxSize, missCount, put, putCount, remove, size, snapshot, toString, trimToSize |
StringLruCache
public StringLruCache(int maxSize)
sizeOf
protected int sizeOf(Object key,
CacheItem<String> value)
- Description copied from class:
LruCache
- Returns the size of the entry for
key
and value
in
user-defined units. The default implementation returns 1 so that size is
the number of entries and max size is the maximum number of entries.
An entry's size must not change while it is in the cache.
- Overrides:
sizeOf
in class LruCache<Object,CacheItem<String>>
Copyright © 2012-2014. All Rights Reserved.