|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.excalibur.mpool.FixedSizePool
This is an Pool
that caches Poolable objects for reuse.
Please note that this pool offers no resource limiting whatsoever.
Constructor Summary | |
FixedSizePool(ObjectFactory factory,
int size)
|
Method Summary | |
Object |
acquire()
Acquire an instance of the pooled object. |
void |
dispose()
|
Object |
newInstance()
Create a new instance of the object being pooled. |
void |
release(Object object)
Release the instance of the pooled object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public FixedSizePool(ObjectFactory factory, int size) throws Exception
Method Detail |
public Object acquire()
Pool
acquire
in interface Pool
public void release(Object object)
Pool
release
in interface Pool
object
- The pooled object to release to the pool.public Object newInstance() throws Exception
Pool
newInstance
in interface Pool
Exception
- if the instance cannot be createdpublic void dispose()
dispose
in interface Disposable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |