public class HostMountContentPool extends RecyclePool implements MountContentPool
Constructor and Description |
---|
HostMountContentPool(java.lang.String name,
int maxSize,
boolean isEnabled) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
acquire(Context c,
ContentAllocator component)
Acquire a pooled content item from the pool
|
void |
maybePreallocateContent(Context c,
ContentAllocator component)
Called early in the lifecycle to allow the pool implementation to preallocate items in the
pool (as released items)
|
void |
release(java.lang.Object item)
Called when an item is released and can return to the pool
|
acquire, clear, getCurrentSize, getMaxSize, getName, isFull
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getCurrentSize, getMaxSize, getName
public HostMountContentPool(java.lang.String name, int maxSize, boolean isEnabled)
public java.lang.Object acquire(Context c, ContentAllocator component)
MountItemsPool.ItemPool
acquire
in interface MountItemsPool.ItemPool
c
- the Android contextpublic void release(java.lang.Object item)
MountItemsPool.ItemPool
release
in interface MountItemsPool.ItemPool
release
in class RecyclePool
item
- the item to release to the poolpublic void maybePreallocateContent(Context c, ContentAllocator component)
MountItemsPool.ItemPool
maybePreallocateContent
in interface MountItemsPool.ItemPool
c
- the android context