Interface | Description |
---|---|
ImageCache.CompressListener |
set image compress scale
|
ImageMemoryCache.OnImageCallbackListener |
callback interface when getting image
|
ImageSDCardCache.OnImageSDCallbackListener |
callback interface when getting image
|
PreloadDataCache.OnGetDataListener<K,V> |
get data interface, implements this to get data
|
Class | Description |
---|---|
FileNameRuleCurrentTime |
File name rule, used when saving images in
ImageSDCardCache
use FileNameRuleCurrentTime.TimeRule as file name
use file suffix in url as target file suffix
|
FileNameRuleImageUrl |
File name rule, used when saving images in
ImageSDCardCache
use image url as file name, replace char with _ if not letter or number
use file suffix in url as target file suffix
use FileNameRuleImageUrl.setFileExtension(String) set file extension
|
ImageCache |
Image Cache
It's a cache with primary cache and secondary cache. |
ImageMemoryCache |
Image Memory Cache
It applies to images those uesd frequently, like users avatar of twitter or sina weibo. |
ImageSDCardCache |
Image SDCard Cache
It applies to images those uesd frequently and their size is big that we cannot store too much in memory, like pictures of twitter or sina weibo. |
PreloadDataCache<K,V> |
Preload data cache, It a good choice for network application which need to preload data.
|
RemoveTypeBitmapLarge |
Remove type when cache is full, data type of cache is bitmap.
|
RemoveTypeBitmapSmall |
Remove type when cache is full, data type of cache is bitmap.
|
RemoveTypeDataBig<T> |
Remove type when cache is full.
|
RemoveTypeDataSmall<T> |
Remove type when cache is full.
|
RemoveTypeEnterTimeFirst<T> |
Remove type when cache is full.
|
RemoveTypeEnterTimeLast<T> |
Remove type when cache is full.
|
RemoveTypeFileLarge |
Remove type when cache is full, data type of cache is string, and it represents the path of a file.
|
RemoveTypeFileSmall |
Remove type when cache is full, data type of cache is string, and it represents the path of a file.
|
RemoveTypeLastUsedTimeFirst<T> |
Remove type when cache is full.
|
RemoveTypeLastUsedTimeLast<T> |
Remove type when cache is full.
|
RemoveTypeNotRemove<T> |
Remove type when cache is full. not remove any one, it means nothing can be put later
|
RemoveTypePriorityHigh<T> |
Remove type when cache is full.
|
RemoveTypePriorityLow<T> |
Remove type when cache is full.
|
RemoveTypeUsedCountBig<T> |
Remove type when cache is full.
|
RemoveTypeUsedCountSmall<T> |
Remove type when cache is full.
|
SimpleCache<K,V> |
Simple Cache
Usage Use one of constructors below to construct cache SimpleCache.setCacheFullRemoveType(CacheFullRemoveType) set remove type when cache is full
SimpleCache.setValidTime(long) set valid time of elements in cache, in mills
SimpleCache.put(Object, CacheObject) or SimpleCache.put(Object, Object) put element
SimpleCache.get(Object) get element
SimpleCache.loadCache(String) restore cache from file
SimpleCache.saveCache(String, SimpleCache) save cache to file
Constructor
SimpleCache.SimpleCache()
SimpleCache.SimpleCache(int)
SimpleCache.loadCache(String) restore cache from file
About hit and miss of the cache
SimpleCache.getHitRate() get hit rate of the cache
SimpleCache.getHitCount() get hit count of the cache
SimpleCache.getMissCount() get miss count of the cache
About size of cache
SimpleCache.getMaxSize() get the maximum capacity of the cache
SimpleCache.getSize() get the number of elements in the cache valid
Other interfaces same to Map
|
Enum | Description |
---|---|
FileNameRuleCurrentTime.TimeRule |
Time Rule
FileNameRuleCurrentTime.TimeRule.YEAR year of current time, E.g., at 2012-7-6 14:37:58.365 PM result is 2012
FileNameRuleCurrentTime.TimeRule.DAY_OF_MONTH indicating the day of the month. |