public class RenderResourceCache extends LruMemoryCache<java.lang.Object,RenderResource> implements Retriever.Callback<ImageSource,ImageOptions,android.graphics.Bitmap>, android.os.Handler.Callback
Constructor and Description |
---|
RenderResourceCache(int capacity) |
RenderResourceCache(int capacity,
int lowWater) |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
android.content.res.Resources |
getResources() |
boolean |
handleMessage(android.os.Message msg) |
static int |
recommendedCapacity(android.content.Context context) |
void |
releaseEvictedResources(DrawContext dc) |
void |
retrievalFailed(Retriever<ImageSource,ImageOptions,android.graphics.Bitmap> retriever,
ImageSource key,
java.lang.Throwable ex) |
void |
retrievalRejected(Retriever<ImageSource,ImageOptions,android.graphics.Bitmap> retriever,
ImageSource key) |
void |
retrievalSucceeded(Retriever<ImageSource,ImageOptions,android.graphics.Bitmap> retriever,
ImageSource key,
ImageOptions options,
android.graphics.Bitmap value) |
Texture |
retrieveTexture(ImageSource imageSource,
ImageOptions options) |
void |
setResources(android.content.res.Resources res) |
containsKey, get, getCapacity, getEntryCount, getUsedCapacity, put, remove, trimToAge
public RenderResourceCache(int capacity)
public RenderResourceCache(int capacity, int lowWater)
public static int recommendedCapacity(android.content.Context context)
public android.content.res.Resources getResources()
public void setResources(android.content.res.Resources res)
public void clear()
clear
in class LruMemoryCache<java.lang.Object,RenderResource>
public void releaseEvictedResources(DrawContext dc)
public Texture retrieveTexture(ImageSource imageSource, ImageOptions options)
public void retrievalSucceeded(Retriever<ImageSource,ImageOptions,android.graphics.Bitmap> retriever, ImageSource key, ImageOptions options, android.graphics.Bitmap value)
retrievalSucceeded
in interface Retriever.Callback<ImageSource,ImageOptions,android.graphics.Bitmap>
public void retrievalFailed(Retriever<ImageSource,ImageOptions,android.graphics.Bitmap> retriever, ImageSource key, java.lang.Throwable ex)
retrievalFailed
in interface Retriever.Callback<ImageSource,ImageOptions,android.graphics.Bitmap>
public void retrievalRejected(Retriever<ImageSource,ImageOptions,android.graphics.Bitmap> retriever, ImageSource key)
retrievalRejected
in interface Retriever.Callback<ImageSource,ImageOptions,android.graphics.Bitmap>
public boolean handleMessage(android.os.Message msg)
handleMessage
in interface android.os.Handler.Callback