Class CacheUtils
- java.lang.Object
-
- org.openstreetmap.josm.plugins.streetside.cache.CacheUtils
-
public final class CacheUtils extends java.lang.Object
Utility methods for working with cache.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classCacheUtils.IgnoreDownloadstatic classCacheUtils.PICTUREPicture quality
-
Field Summary
Fields Modifier and Type Field Description private static CacheUtils.IgnoreDownloadignoreDownload(package private) static org.apache.log4j.Loggerlogger
-
Constructor Summary
Constructors Modifier Constructor Description privateCacheUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voiddownloadCubemap(StreetsideImage cm)Downloads the the thumbnail and the full resolution picture of the given image.static voiddownloadPicture(StreetsideImage img)Downloads the the thumbnail and the full resolution picture of the given image.static voiddownloadPicture(StreetsideImage img, CacheUtils.PICTURE pic)Downloads the picture of the given image.static voidsubmit(java.lang.String key, StreetsideCache.Type type, ICachedLoaderListener lis)Requests the picture with the given key and quality and uses the given listener.
-
-
-
Field Detail
-
logger
static final org.apache.log4j.Logger logger
-
ignoreDownload
private static CacheUtils.IgnoreDownload ignoreDownload
-
-
Constructor Detail
-
CacheUtils
private CacheUtils()
-
-
Method Detail
-
downloadPicture
public static void downloadPicture(StreetsideImage img)
Downloads the the thumbnail and the full resolution picture of the given image. Does nothing if it is already in cache.- Parameters:
img- The image whose picture is going to be downloaded.
-
downloadCubemap
public static void downloadCubemap(StreetsideImage cm)
Downloads the the thumbnail and the full resolution picture of the given image. Does nothing if it is already in cache.- Parameters:
cm- The image whose picture is going to be downloaded.
-
downloadPicture
public static void downloadPicture(StreetsideImage img, CacheUtils.PICTURE pic)
Downloads the picture of the given image. Does nothing when it is already in cache.- Parameters:
img- The image to be downloaded.pic- The picture type to be downloaded (full quality, thumbnail or both.)
-
submit
public static void submit(java.lang.String key, StreetsideCache.Type type, ICachedLoaderListener lis)
Requests the picture with the given key and quality and uses the given listener.- Parameters:
key- The key of the picture to be requested.type- The quality of the picture to be requested.lis- The listener that is going to receive the picture.
-
-