org.openstreetmap.josm.plugins.streetside.cache

## Class StreetsideCache

- java.lang.Object
- - org.openstreetmap.josm.data.cache.JCSCachedTileLoaderJob<String,BufferedImageCacheEntry>
  - - org.openstreetmap.josm.plugins.streetside.cache.StreetsideCache

- All Implemented Interfaces:
    Runnable, ICachedLoaderJob<String>

      public class StreetsideCache
      extends JCSCachedTileLoaderJob<String,BufferedImageCacheEntry>

  Stores the downloaded pictures locally.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `StreetsideCache.Type` Types of images.

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `private String` | `id`
    `private URL` | `url`

    - ### Fields inherited from class org.openstreetmap.josm.data.cache.JCSCachedTileLoaderJob

      `ABSOLUTE_EXPIRE_TIME_LIMIT, attributes, cacheData, DEFAULT_EXPIRE_TIME, EXPIRE_TIME_SERVER_LIMIT, now, THREAD_LIMIT`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StreetsideCache(String id, StreetsideCache.Type type)` Main constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected BufferedImageCacheEntry` | `createCacheEntry(byte[] content)`
    `String` | `getCacheKey()`
    `URL` | `getUrl()`
    `protected boolean` | `isObjectLoadable()`

    - ### Methods inherited from class org.openstreetmap.josm.data.cache.JCSCachedTileLoaderJob

      `cacheAsEmpty, cancelOutstandingTasks, executionFinished, get, getServerKey, handleJobCancellation, isCacheElementValid, isResponseLoadable, parseHeaders, run, setFinishedTask, submit`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### url

          private final URL url

    - #### id

          private final String id

  - ### Constructor Detail

    - #### StreetsideCache

          public StreetsideCache(String id,
                                 StreetsideCache.Type type)

      Main constructor.
      Parameters:
        `id` - The id of the image.
        `type` - The type of image that must be downloaded (THUMBNAIL or FULL_IMAGE).

  - ### Method Detail

    - #### getCacheKey

          public String getCacheKey()

    - #### getUrl

          public URL getUrl()

    - #### createCacheEntry

          protected BufferedImageCacheEntry createCacheEntry(byte[] content)

      Specified by:
        `createCacheEntry` in class `JCSCachedTileLoaderJob<String,BufferedImageCacheEntry>`

    - #### isObjectLoadable

          protected boolean isObjectLoadable()

      Overrides:
        `isObjectLoadable` in class `JCSCachedTileLoaderJob<String,BufferedImageCacheEntry>`

JOSM Plugins