org.firebirdsql.pool

Interface PooledObject

Known Implementing Classes:
PingablePooledConnection

public interface PooledObject

Represents an object that can be stored in the pool. * * @author Roman Rokytskyy

Method Summary

void
deallocate()
Deallocate this object.
boolean
isInPool()
Check whether this object is currently in pool or had been released * to the application.
boolean
isValid()
Check if this pooled object is still valid.
void
setInPool(boolean inPool)
Set the "inPool" flag to this object.

Method Details

deallocate

public void deallocate()
Deallocate this object. This method deallocated the object * and releases all associated resources. This method is invoked when * object pool is shutdown and is needed to gracefully release resources.

isInPool

public boolean isInPool()
Check whether this object is currently in pool or had been released * to the application. * * @return true if the object is currently in pool.

isValid

public boolean isValid()
Check if this pooled object is still valid. * * @return true when the object is valid.

setInPool

public void setInPool(boolean inPool)
Set the "inPool" flag to this object. This method should be called only * by the pool implementation. * * @param inPool true if object is in pool, otherwise * false.

Copyright B) 2001 David Jencks and other authors. All rights reserved.