|
Apache JMeter 2.0.1.20050615 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jmeter.protocol.jdbc.util.ConnectionObject
A wrapper class for a database Connection object. This class holds information about the state of the connection object in a pool managed by a DBConnectionManager object. It keeps track of how many times the connection object has been used, the time of its last usage, and whether it is currently in use.
Constructor Summary | |
ConnectionObject(DBKey k,
int maxUsage)
Constructor - takes a connection object. |
Method Summary | |
void |
close()
Closes out this object and returns resources to the system. |
Connection |
getCon()
Returns the connection held by this connection object. |
boolean |
getInMaintenance()
Gets whether the Connection Object is being maintained. |
boolean |
getInUse()
Gets whether the connection object is currently in use. |
long |
getLastAccessed()
Gets the last time this object was accessed. |
int |
getUseCount()
Gets the number of times this connection object has been used. |
Connection |
grab()
Grabs the connection and sets the inUse value to true. |
void |
release()
Releases the connection object. |
void |
reset()
Resets the use count, the last accessed time, and the in Use values and replaces the old connection object with the new one. |
void |
run()
Method to run in separate thread that resets the connection object |
void |
setInMaintenance(boolean b)
Sets whether the Connection Object is being maintained. |
void |
update()
Updates the last accessed time for the connection object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ConnectionObject(DBKey k, int maxUsage) throws SQLException
k
- DBKey object.maxUsage
- Method Detail |
public boolean getInMaintenance()
public void setInMaintenance(boolean b)
b
- true if the ConnectionObject is being maintained, false
otherwise.public long getLastAccessed()
public void close()
public void update()
public boolean getInUse()
public Connection grab()
public int getUseCount()
public void run()
run
in interface Runnable
public void reset() throws SQLException
SQLException
public void release()
public Connection getCon()
|
Apache JMeter 2.0.1.20050615 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |