Back to Fresco

DefaultCacheKeyFactory

docs/javadoc/reference/com/facebook/imagepipeline/cache/DefaultCacheKeyFactory.html

3.6.019.9 KB
Original Source

Fresco

|

|

Packages | Classes

Interfaces

Classes

Packages | Classes

Summary: Protected Ctors | Methods | Protected Methods | Inherited Methods | [Expand All]

public class

DefaultCacheKeyFactory

extends Object
implements CacheKeyFactory

| java.lang.Object | | ↳ | com.facebook.imagepipeline.cache.DefaultCacheKeyFactory |

| Known Direct Subclasses

FlipperCacheKeyFactory

| FlipperCacheKeyFactory | |

|

Class Overview

Default implementation of CacheKeyFactory.

Summary

Protected Constructors
Public Methods
CacheKey
CacheKey
Creates a key to be used in the encoded memory and disk caches.
CacheKey
Creates a key to be used in the encoded memory and disk caches.
synchronized static DefaultCacheKeyFactory
CacheKey
Protected Methods
Uri

| [Expand] Inherited Methods | | --- | | From class java.lang.Object

| Object | clone() | | boolean | equals(Object arg0) | | void | finalize() | | final Class<?> | getClass() | | int | hashCode() | | final void | notify() | | final void | notifyAll() | | String | toString() | | final void | wait(long arg0, int arg1) | | final void | wait(long arg0) | | final void | wait() |

| | From interface com.facebook.imagepipeline.cache.CacheKeyFactory

| abstract CacheKey | getBitmapCacheKey(ImageRequest request, Object callerContext) | | abstract CacheKey | getEncodedCacheKey(ImageRequest request, Object callerContext) Creates a key to be used in the encoded memory and disk caches. | | abstract CacheKey | getEncodedCacheKey(ImageRequest request, Uri sourceUri, Object callerContext) Creates a key to be used in the encoded memory and disk caches. | | abstract CacheKey | getPostprocessedBitmapCacheKey(ImageRequest request, Object callerContext) |

|

Protected Constructors

protected DefaultCacheKeyFactory()

Public Methods

public CacheKey getBitmapCacheKey(ImageRequest request, Object callerContext)

public CacheKey getEncodedCacheKey(ImageRequest request, Object callerContext)

Creates a key to be used in the encoded memory and disk caches.

Implementations must return consistent values for the same request or else caches will not work efficiently.

Parameters

| request | the image request to be cached or queried from cache | | callerContext | included for optional debugging or logging purposes only |

Returns
  • CacheKey for doing encoded image lookups in the pipeline.

public CacheKey getEncodedCacheKey(ImageRequest request, Uri sourceUri, Object callerContext)

Creates a key to be used in the encoded memory and disk caches.

This version of the method receives a specific URI which may differ from the one held by the request. You should not consider the URI in the request.

Implementations must return consistent values for the same request or else caches will not work efficiently.

Parameters

| request | the image request to be cached or queried from cache | | sourceUri | the URI to use for the key, which may override the one held in the request | | callerContext | included for optional debugging or logging purposes only |

Returns
  • CacheKey for doing encoded image lookups in the pipeline.

public static synchronized DefaultCacheKeyFactory getInstance()

public CacheKey getPostprocessedBitmapCacheKey(ImageRequest request, Object callerContext)

Protected Methods

protected Uri getCacheKeySourceUri(Uri sourceUri)

Returns
  • a Uri that unambiguously indicates the source of the image.

+Generated by Doclava. +