I guess the title says it all. I tried:
imageLoader.getMemoryCache().get(key);
with the image uri as key, but it always return null
I think you can create a simple method in your utility class like this:
public static boolean isImageAvailableInCache(String imageUrl){
MemoryCache memoryCache = ImageLoader.getInstance().getMemoryCache();
if(memoryCache!=null) {
for (String key : memoryCache.keys()) {
if (key.startsWith(imageUrl)) {
return true;
}
}
}
return false;
}
and Use it like:
if(Utils.isImageAvailableInCache(imageUrl)){
//
}