getConnection method code for retrieving a connection
- By Nitin Nanda
- February 5, 2001
COMPONENT JAVA
Extending the Power of JDBC Drivers
Nitin Nanda
Listing 4. getConnection method code for retrieving a connection.
// retrieve one unused
for(int i = 0; i < vconnections.size();="" i++)="" {="" jrconnection="" jrconnection="(JRConnection)" vconnections.elementat(i);="" if(jrconnection.isinuse()="=" false)="" {="" jrconnection.setinuse(true);="" return="" jrconnection.getconnection();="" }="" }="">