|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
The PoolableObjectFactory is designed to manage the creation, validation, and destruction of objects that are stored in the ObjectPool.
Having this object handle object maintenance reduces the load the ObjectPool must handle. In addition, it allows for the implementing class to handle the particulars that each object it creates has.
| Method Summary | |
Object |
createObject()
Create a new object for the ObjectPool |
void |
destroyObject(Object object)
Destroy an object that can no longer needed by the ObjectPool. |
boolean |
validateObject(Object object)
Ensures that the Object is safe to be returned by the pool. |
| Method Detail |
public Object createObject()
throws Exception
Exception - Throws an Exception if an error occurred while trying to create a new objectpublic void destroyObject(Object object)
object - The object to be destroyed.public boolean validateObject(Object object)
object - The object to be validated.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||