Class BaseObjectPool<T>

java.lang.Object
org.apache.commons.pool.BaseObjectPool<T>
Type Parameters:
T - the type of objects held in this pool
All Implemented Interfaces:
ObjectPool<T>
Direct Known Subclasses:
GenericObjectPool, SoftReferenceObjectPool, StackObjectPool

public abstract class BaseObjectPool<T> extends Object implements ObjectPool<T>
A simple base implementation of ObjectPool. Optional operations are implemented to either do nothing, return a value indicating it is unsupported or throw UnsupportedOperationException.
Since:
Pool 1.0
Version:
$Revision: 1222396 $ $Date: 2011-12-22 14:02:25 -0500 (Thu, 22 Dec 2011) $
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private boolean
    Whether or not the pool is closed
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Not supported in this base implementation.
    protected final void
    Throws an IllegalStateException when this pool has been closed.
    abstract T
    Obtains an instance from the pool.
    void
    Not supported in this base implementation.
    void
    Close this pool.
    int
    Not supported in this base implementation.
    int
    Not supported in this base implementation.
    abstract void
    Invalidates an object from the pool.
    final boolean
    Has this pool instance been closed.
    abstract void
    Returns an instance to the pool.
    void
    Deprecated.
    to be removed in pool 2.0

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait