Uses of Interface
org.apache.commons.pool.KeyedObjectPool
Packages that use KeyedObjectPool
Package
Description
Object pooling API.
Object pooling API implementations.
-
Uses of KeyedObjectPool in org.apache.commons.pool
Classes in org.apache.commons.pool that implement KeyedObjectPoolModifier and TypeClassDescriptionclass
BaseKeyedObjectPool<K,
V> A simple base implementation ofKeyedObjectPool
.private static class
A keyed object pool that performs type checking on objects passed to pool methods.private static class
Decorates a keyed object pool, adding "eroding" behavior.private static class
Extends ErodingKeyedObjectPool to allow erosion to take place on a per-key basis.private static class
Adapts an ObjectPool to implement KeyedObjectPool by ignoring key arguments.private static class
A synchronized (thread-safe) KeyedObjectPool backed by the specified KeyedObjectPool.Fields in org.apache.commons.pool declared as KeyedObjectPoolModifier and TypeFieldDescriptionprivate final KeyedObjectPool<K,
V> PoolUtils.CheckedKeyedObjectPool.keyedPool
Underlying poolprivate final KeyedObjectPool<K,
V> PoolUtils.ErodingKeyedObjectPool.keyedPool
Underlying poolprivate final KeyedObjectPool<K,
V> PoolUtils.KeyedObjectPoolMinIdleTimerTask.keyedPool
Keyed object poolprivate final KeyedObjectPool<Object,
V> PoolUtils.ObjectPoolAdaptor.keyedPool
Underlying KeyedObjectPoolprivate final KeyedObjectPool<K,
V> PoolUtils.SynchronizedKeyedObjectPool.keyedPool
Underlying object poolMethods in org.apache.commons.pool that return KeyedObjectPoolModifier and TypeMethodDescriptionstatic <K,
V> KeyedObjectPool<K, V> PoolUtils.adapt
(ObjectPool<V> pool) Adapt anObjectPool
to work where anKeyedObjectPool
is needed.static <K,
V> KeyedObjectPool<K, V> PoolUtils.checkedPool
(KeyedObjectPool<K, V> keyedPool, Class<V> type) Wraps aKeyedObjectPool
and dynamically checks the type of objects borrowed and returned to the keyedPool.KeyedObjectPoolFactory.createPool()
Create a newKeyedObjectPool
.static <K,
V> KeyedObjectPool<K, V> PoolUtils.erodingPool
(KeyedObjectPool<K, V> keyedPool) Returns a pool that adaptively decreases it's size when idle objects are no longer needed.static <K,
V> KeyedObjectPool<K, V> PoolUtils.erodingPool
(KeyedObjectPool<K, V> keyedPool, float factor) Returns a pool that adaptively decreases it's size when idle objects are no longer needed.static <K,
V> KeyedObjectPool<K, V> PoolUtils.erodingPool
(KeyedObjectPool<K, V> keyedPool, float factor, boolean perKey) Returns a pool that adaptively decreases it's size when idle objects are no longer needed.protected KeyedObjectPool<K,
V> PoolUtils.ErodingKeyedObjectPool.getKeyedPool()
Returns the underlying poolstatic <K,
V> KeyedObjectPool<K, V> PoolUtils.synchronizedPool
(KeyedObjectPool<K, V> keyedPool) Returns a synchronized (thread-safe) KeyedObjectPool backed by the specified KeyedObjectPool.Methods in org.apache.commons.pool with parameters of type KeyedObjectPoolModifier and TypeMethodDescriptionstatic <V> ObjectPool<V>
PoolUtils.adapt
(KeyedObjectPool<Object, V> keyedPool) Adapt aKeyedObjectPool
instance to work where anObjectPool
is needed.static <V> ObjectPool<V>
PoolUtils.adapt
(KeyedObjectPool<Object, V> keyedPool, Object key) Adapt aKeyedObjectPool
instance to work where anObjectPool
is needed using the specifiedkey
when delegating.static <K,
V> KeyedObjectPool<K, V> PoolUtils.checkedPool
(KeyedObjectPool<K, V> keyedPool, Class<V> type) Wraps aKeyedObjectPool
and dynamically checks the type of objects borrowed and returned to the keyedPool.PoolUtils.checkMinIdle
(KeyedObjectPool<K, V> keyedPool, Collection<? extends K> keys, int minIdle, long period) Periodically check the idle object count for each key in theCollection
keys
in the keyedPool.static <K,
V> TimerTask PoolUtils.checkMinIdle
(KeyedObjectPool<K, V> keyedPool, K key, int minIdle, long period) Periodically check the idle object count for the key in the keyedPool.static <K,
V> KeyedObjectPool<K, V> PoolUtils.erodingPool
(KeyedObjectPool<K, V> keyedPool) Returns a pool that adaptively decreases it's size when idle objects are no longer needed.static <K,
V> KeyedObjectPool<K, V> PoolUtils.erodingPool
(KeyedObjectPool<K, V> keyedPool, float factor) Returns a pool that adaptively decreases it's size when idle objects are no longer needed.static <K,
V> KeyedObjectPool<K, V> PoolUtils.erodingPool
(KeyedObjectPool<K, V> keyedPool, float factor, boolean perKey) Returns a pool that adaptively decreases it's size when idle objects are no longer needed.static <K,
V> void PoolUtils.prefill
(KeyedObjectPool<K, V> keyedPool, Collection<? extends K> keys, int count) CalladdObject(Object)
onkeyedPool
with each key inkeys
forcount
number of times.static <K,
V> void PoolUtils.prefill
(KeyedObjectPool<K, V> keyedPool, K key, int count) CalladdObject(Object)
onkeyedPool
withkey
count
number of times.static <K,
V> KeyedObjectPool<K, V> PoolUtils.synchronizedPool
(KeyedObjectPool<K, V> keyedPool) Returns a synchronized (thread-safe) KeyedObjectPool backed by the specified KeyedObjectPool.Constructors in org.apache.commons.pool with parameters of type KeyedObjectPoolModifierConstructorDescription(package private)
CheckedKeyedObjectPool
(KeyedObjectPool<K, V> keyedPool, Class<V> type) Create a new CheckedKeyedObjectPool from the given pool with given expected object type.ErodingKeyedObjectPool
(KeyedObjectPool<K, V> keyedPool, float factor) Create an ErodingObjectPool wrapping the given pool using the specified erosion factor.protected
ErodingKeyedObjectPool
(KeyedObjectPool<K, V> keyedPool, PoolUtils.ErodingFactor erodingFactor) Create an ErodingObjectPool wrapping the given pool using the specified erosion factor.ErodingPerKeyKeyedObjectPool
(KeyedObjectPool<K, V> keyedPool, float factor) Create a new ErordingPerKeyKeyedObjectPool decorating the given keyed pool with the specified erosion factor.(package private)
KeyedObjectPoolMinIdleTimerTask
(KeyedObjectPool<K, V> keyedPool, K key, int minIdle) Create a new KeyedObjecPoolMinIdleTimerTask.(package private)
ObjectPoolAdaptor
(KeyedObjectPool<Object, V> keyedPool, Object key) Create a new ObjectPoolAdaptor using the provided KeyedObjectPool and fixed key.(package private)
SynchronizedKeyedObjectPool
(KeyedObjectPool<K, V> keyedPool) Create a new SynchronizedKeyedObjectPool wrapping the given pool -
Uses of KeyedObjectPool in org.apache.commons.pool.impl
Classes in org.apache.commons.pool.impl that implement KeyedObjectPoolModifier and TypeClassDescriptionclass
A configurableKeyedObjectPool
implementation.class
StackKeyedObjectPool<K,
V> A simple,Stack
-basedKeyedObjectPool
implementation.Methods in org.apache.commons.pool.impl that return KeyedObjectPoolModifier and TypeMethodDescriptionGenericKeyedObjectPoolFactory.createPool()
Create a new GenericKeyedObjectPool with the currently configured properties.StackKeyedObjectPoolFactory.createPool()
Create a StackKeyedObjectPool with current property settings.