Example usage for org.apache.commons.pool ObjectPoolFactory createPool

List of usage examples for org.apache.commons.pool ObjectPoolFactory createPool

Introduction

In this page you can find the example usage for org.apache.commons.pool ObjectPoolFactory createPool.

Prototype

ObjectPool createPool() throws IllegalStateException;

Source Link

Document

Create and return a new ObjectPool .

Usage

From source file:com.ewcms.plugin.externalds.generate.service.dbcp.DbcpDataSource.java

protected ObjectPool createPool(ObjectPoolFactory objectPoolFactory) {
    ObjectPool objectPool = objectPoolFactory.createPool();
    return objectPool;
}

From source file:org.geotools.referencing.factory.AbstractAuthorityMediator.java

ObjectPool getPool() {
    if (workers == null) {
        // create pool
        PoolableObjectFactory objectFactory = new AuthorityPoolableObjectFactory();
        ObjectPoolFactory poolFactory = new GenericObjectPoolFactory(objectFactory, poolConfig);
        this.setPool(poolFactory.createPool());
    }//from w  ww. ja va  2s .  co m
    return workers;
}