org.apache.commons.pool
Class BasePoolableObjectFactory

java.lang.Object
  |
  +--org.apache.commons.pool.BasePoolableObjectFactory
All Implemented Interfaces:
PoolableObjectFactory

public abstract class BasePoolableObjectFactory
extends Object
implements PoolableObjectFactory

A base implemenation of PoolableObjectFactory.

All operations defined here are essentially no-op's.

Version:
$Revision: 1.3 $ $Date: 2002/03/26 12:34:24 $
Author:
Rodney Waldhoff
See Also:
PoolableObjectFactory, BaseKeyedPoolableObjectFactory

Constructor Summary
BasePoolableObjectFactory()
           
 
Method Summary
 void activateObject(Object obj)
          No-op.
 void destroyObject(Object obj)
          No-op.
abstract  Object makeObject()
          Creates an instance that can be returned by the pool.
 void passivateObject(Object obj)
          No-op.
 boolean validateObject(Object obj)
          This implementation always returns true.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasePoolableObjectFactory

public BasePoolableObjectFactory()
Method Detail

activateObject

public void activateObject(Object obj)
                    throws Exception
No-op.

Specified by:
activateObject in interface PoolableObjectFactory
Parameters:
obj - the instance to be activated
Exception

destroyObject

public void destroyObject(Object obj)
                   throws Exception
No-op.

Specified by:
destroyObject in interface PoolableObjectFactory
Parameters:
obj - the instance to be destroyed
Exception

makeObject

public abstract Object makeObject()
                           throws Exception
Description copied from interface: PoolableObjectFactory
Creates an instance that can be returned by the pool.

Specified by:
makeObject in interface PoolableObjectFactory
Returns:
an instance that can be returned by the pool.
Exception

passivateObject

public void passivateObject(Object obj)
                     throws Exception
No-op.

Specified by:
passivateObject in interface PoolableObjectFactory
Parameters:
obj - the instance to be passivated
Exception

validateObject

public boolean validateObject(Object obj)
This implementation always returns true.

Specified by:
validateObject in interface PoolableObjectFactory
Parameters:
obj - the instance to be validated
Returns:
true


Copyright © 2001-2002 Apache Software Foundation. Documenation generated February 22 2003.