BaseObjectPool

A simple base implementation of {@link ObjectPool}. Optional operations are implemented to either do nothing, return a value indicating it is unsupported or throw {@link UnsupportedOperationException}. <p> This class is intended to be thread-safe.

@param <T> Type of element pooled in this pool.

Members

Functions

addObject
void addObject()

Not supported in this base implementation. Subclasses should override this behavior.

assertOpen
void assertOpen()

<code>IllegalStateException</code> when this pool has been closed.

borrowObject
T borrowObject()
Undocumented in source.
clear
void clear()

Not supported in this base implementation.

close
void close()

{@inheritDoc} <p> This affects the behavior of <code>isClosed</code> and <code>assertOpen</code>. </p>

getNumActive
int getNumActive()

Not supported in this base implementation.

getNumIdle
int getNumIdle()

Not supported in this base implementation.

invalidateObject
void invalidateObject(T obj)
Undocumented in source.
isClosed
bool isClosed()

Has this pool instance been closed.

returnObject
void returnObject(T obj)
Undocumented in source.
toStringAppendFields
void toStringAppendFields(StringBuilder builder)
Undocumented in source. Be warned that the author may not have intended to support it.

Meta