public class FIFOLimitedMemoryCache extends LimitedMemoryCache
bitmap cache. Provides bitmaps storing. Size of all stored bitmaps will not to
exceed size limit. When cache reaches limit size then cache clearing is processed by FIFO principle.| Constructor and Description |
|---|
FIFOLimitedMemoryCache(int sizeLimit) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Remove all items from cache
|
protected java.lang.ref.Reference<android.graphics.Bitmap> |
createReference(android.graphics.Bitmap value)
Creates not strong reference of value
|
protected int |
getSize(android.graphics.Bitmap value) |
boolean |
put(java.lang.String key,
android.graphics.Bitmap value)
Puts value into cache by key
|
android.graphics.Bitmap |
remove(java.lang.String key)
Removes item by key
|
protected android.graphics.Bitmap |
removeNext() |
getSizeLimitget, keyspublic boolean put(java.lang.String key,
android.graphics.Bitmap value)
MemoryCacheput in interface MemoryCacheput in class LimitedMemoryCachepublic android.graphics.Bitmap remove(java.lang.String key)
MemoryCacheremove in interface MemoryCacheremove in class LimitedMemoryCachepublic void clear()
MemoryCacheclear in interface MemoryCacheclear in class LimitedMemoryCacheprotected int getSize(android.graphics.Bitmap value)
getSize in class LimitedMemoryCacheprotected android.graphics.Bitmap removeNext()
removeNext in class LimitedMemoryCacheprotected java.lang.ref.Reference<android.graphics.Bitmap> createReference(android.graphics.Bitmap value)
BaseMemoryCachecreateReference in class BaseMemoryCache