Package com.complexible.common.pool
Class ApachePoolConfig<T>
- java.lang.Object
-
- com.complexible.common.pool.PoolConfig<T,java.lang.Exception>
-
- com.complexible.common.pool.ApachePoolConfig<T>
-
public class ApachePoolConfig<T> extends PoolConfig<T,java.lang.Exception>
Abstract base class for instantiating a pool backed by Apache Pool. Be careful that the PoolableObjectFactory passed into the config creates objects of the correct type or you will end up with runtime cast exceptions.
- Since:
- 0.5.1
- Version:
- 0.7
- Author:
- Michael Grove
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.commons.pool.PoolableObjectFactory<T>
mFactory
-
Fields inherited from class com.complexible.common.pool.PoolConfig
mConfig, mMinPool
-
-
Constructor Summary
Constructors Constructor Description ApachePoolConfig(org.apache.commons.pool.PoolableObjectFactory<T> theFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Pool<T,java.lang.Exception>
create()
Create the Pool-
Methods inherited from class com.complexible.common.pool.PoolConfig
blockAtCapacity, expiration, failAtCapacity, growAtCapacity, maxIdle, maxPool, minPool, noExpiration
-
-
-
-
Field Detail
-
mFactory
protected org.apache.commons.pool.PoolableObjectFactory<T> mFactory
-
-
Constructor Detail
-
ApachePoolConfig
public ApachePoolConfig(org.apache.commons.pool.PoolableObjectFactory<T> theFactory)
-
-
Method Detail
-
create
public Pool<T,java.lang.Exception> create()
Create the Pool- Specified by:
create
in classPoolConfig<T,java.lang.Exception>
- Returns:
- the pool
-
-