com.thoughtworks.proxy.kit
Interface Resetter

All Known Implementing Classes:
NoOperationResetter

public interface Resetter

Interface for a resetter component. This will automatically reset the state of the pooled element, when it is retunred to the pool.

Since:
0.2
Author:
Jörg Schaible

Method Summary
 boolean reset(Object object)
          Reset the pooled object.
 

Method Detail

reset

boolean reset(Object object)
Reset the pooled object. The implementation may do anything to reset the state of the pooled element. If the element is definately exhausted, a return value of false prevents the element from returning into the pool and the instance is garbage collected.

Parameters:
object - the object to reset
Returns:
true if the element can be used for further tasks.
Since:
0.2