Back to Fresco

BucketMap

docs/javadoc/reference/com/facebook/imagepipeline/memory/BucketMap.html

3.6.015.5 KB
Original Source

Fresco

|

|

Packages | Classes

Interfaces

Classes

Annotations

Exceptions

Packages | Classes

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

public class

BucketMap

extends Object

| java.lang.Object | | ↳ | com.facebook.imagepipeline.memory.BucketMap<T> |

Class Overview

Map-like datastructure that allows to have more than one value per int key. Allows to remove a value from LRU key by calling removeFromEnd()

Summary

Fields
protected final SparseArray<LinkedEntry<T>>
Public Constructors
Public Methods
synchronized T
synchronized void
Associates the object with the specified key and puts it into the BucketMap.
synchronized T

| [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() |

|

Fields

protected final SparseArray<LinkedEntry<T>> mMap

Public Constructors

public BucketMap()

Public Methods

public synchronized T acquire(int key)

Returns
  • Retrieve an object that corresponds to the specified key if present in the BucketMap or null otherwise

public synchronized void release(int key, T value)

Associates the object with the specified key and puts it into the BucketMap. Does not overwrite the previous object, if any.

public synchronized T removeFromEnd()

+Generated by Doclava. +