velosurf.sql
Class Pooled

java.lang.Object
  |
  +--velosurf.sql.Pooled
Direct Known Subclasses:
PooledPreparedStatement, PooledStatement

public abstract class Pooled
extends java.lang.Object

this abstract class represents a pooled object.

It has two booleans : inUse and useOver (understand : usageOver).

The cycle of those two booleans is the following :

states (inUse - useOver) : (false-false) -> (true-false) -> (true-true) -> [delay] (false-false)

Author:
Claude Brisson

Field Summary
protected  boolean mInUse
          is this object in use ?
protected  long mTagTime
          time tag
protected  boolean mUseOver
          is the usage of this object over ?
 
Constructor Summary
Pooled()
          builds a new pooled object
 
Method Summary
abstract  void close()
          close this pooled object
 long getTagTime()
          get the time tag of this pooled object
 boolean isInUse()
          checks whether this pooled object is in use
 void notifyInUse()
          notify this object that it is in use
 void notifyOver()
          notify this object that it is no more in use
 void resetTagTime()
          reset the time tag
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

mTagTime

protected long mTagTime
time tag

mInUse

protected boolean mInUse
is this object in use ?

mUseOver

protected boolean mUseOver
is the usage of this object over ?
Constructor Detail

Pooled

public Pooled()
builds a new pooled object
Method Detail

getTagTime

public long getTagTime()
get the time tag of this pooled object
Returns:
the time tag

resetTagTime

public void resetTagTime()
reset the time tag

notifyInUse

public void notifyInUse()
notify this object that it is in use

notifyOver

public void notifyOver()
notify this object that it is no more in use

isInUse

public boolean isInUse()
checks whether this pooled object is in use
Returns:
whether this object is in use

close

public abstract void close()
                    throws java.sql.SQLException
close this pooled object
Throws:
java.sql.SQLException - when thrown by the database engine


ooOoo