public class ComponentsPools extends Object
FUTURE: Consider customizing the pool implementation such that we can match buffer sizes. Without this we will tend to expand all buffers to the largest size needed.
Modifier and Type | Method and Description |
---|---|
static Object |
acquireMountContent(Context context,
ComponentLifecycle lifecycle,
int recyclingMode) |
static void |
clearMountContentPools()
Call from tests to clear external references.
|
static void |
maybePreallocateContent(Context context,
ComponentLifecycle lifecycle,
int recyclingMode)
Pre-allocates mount content for this component type within the pool for this context unless the
pre-allocation limit has been hit in which case we do nothing.
|
static void |
release(Context context,
ComponentLifecycle lifecycle,
Object mountContent,
int recyclingMode) |
public static Object acquireMountContent(Context context, ComponentLifecycle lifecycle, int recyclingMode)
public static void release(Context context, ComponentLifecycle lifecycle, Object mountContent, int recyclingMode)
public static void maybePreallocateContent(Context context, ComponentLifecycle lifecycle, int recyclingMode)
public static void clearMountContentPools()