org.firebirdsql.pool
Interface PooledObject

All Known Implementing Classes:
AbstractPingablePooledConnection

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 Detail

deallocate

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.


isValid

boolean isValid()
Check if this pooled object is still valid.

Returns:
true when the object is valid.

isInPool

boolean isInPool()
Check whether this object is currently in pool or had been released to the application.

Returns:
true if the object is currently in pool.

setInPool

void setInPool(boolean inPool)
Set the "inPool" flag to this object. This method should be called only by the pool implementation.

Parameters:
inPool - true if object is in pool, otherwise false.


Copyright © 2001 David Jencks and other authors. All rights reserved.