Package de.intarsys.tools.pool
Class GenericPool
java.lang.Object
de.intarsys.tools.pool.GenericPool
- All Implemented Interfaces:
IPool
A very simple implementation of a generic
IPool.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidactivateObject(Object object) protected voidvoidAdd an object to the pool.checkout(long timeout) Get an object from the pool.voidclose()Close the pool.protected Objectprotected voiddeactivateObject(Object object) voidDestroy an object previously allocated from the pool.protected voiddestroyObject(Object object) protected booleanisClosed()
-
Constructor Details
-
GenericPool
-
-
Method Details
-
checkin
Description copied from interface:IPoolAdd an object to the pool. -
deactivateObject
- Throws:
Exception
-
destroyObject
- Throws:
Exception
-
isClosed
protected boolean isClosed() -
assertOpen
protected void assertOpen() -
checkout
Description copied from interface:IPoolGet an object from the pool.This may be a reused object or a new one, up to the pool strategy and size.
-
activateObject
- Throws:
Exception
-
createObject
- Throws:
Exception
-
close
Description copied from interface:IPoolClose the pool. -
destroy
Description copied from interface:IPoolDestroy an object previously allocated from the pool.
-