java.lang.Object | |
↳ | com.facebook.imagepipeline.memory.BitmapCounter |
Counts bitmaps - keeps track of both, count and total size in bytes.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
BitmapCounter(int maxCount, int maxSize) |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
List<CloseableReference<Bitmap>> |
associateBitmapsWithBitmapCounter(List<Bitmap> bitmaps)
Associates bitmaps with the bitmap counter.
| ||||||||||
synchronized void |
decrease(Bitmap bitmap)
Excludes given bitmap from the count.
| ||||||||||
synchronized int | getCount() | ||||||||||
ResourceReleaser<Bitmap> | getReleaser() | ||||||||||
synchronized long | getSize() | ||||||||||
synchronized boolean |
increase(Bitmap bitmap)
Includes given bitmap in the bitmap count.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Associates bitmaps with the bitmap counter.
If this method throws
TooManyBitmapsException, the code will have called recycle()
on the
bitmaps.
bitmaps | the bitmaps to associate |
---|
TooManyBitmapsException | if the pool is full |
---|
Excludes given bitmap from the count.
bitmap | to be excluded from the count |
---|
Includes given bitmap in the bitmap count. The bitmap is included only if doing so does not violate configured limit
bitmap | to include in the count |
---|