public interface BufferedImageCacheThe
BufferedImageCacheinterface defines a cache that is supposed to cache BufferedImages which are intended to be used more than once very quickly (e.g. Asset import). The impl. must make sure that the cache won't take too much memory from the overall jvm memory "pool" and that images won't life for ages in the cache.
Nested Class Summary
Nested Classes Modifier and Type Interface Description
BufferedImageCache.Entry getImage(Rendition rendition, AssetHandler handler) throws java.io.IOExceptionReturns the image for the given rendition. If the image is not in the cache, the asset handler is used to load the image.
This method always returns a copy of the buffered image. Returns null if param rendition is null.
rendition- of the image.
handler- the asset handler that will load the image if not in cache.
- a cache entry which is already acquired. Consumers of the entry
need to call
BufferedImageCache.Entry.release()if they are done using the buffered image in order to free system resources.
java.io.IOException- if an error occurs