JRDriver.connect method actions

COMPONENT JAVA
Extending the Power of JDBC Drivers
Nitin Nanda
Listing 2. JRDriver.connect method actions.


public Connection connect(String url,
  Properties info) throws SQLException
{
    try
    {
/*call the getConnection method of pool manager*/
	       if( url.startsWith(driverURL, 0) == true)
	       {
              String sUsername = info.getProperty ("user");
              String sPassword = info.getProperty ("password");
              return poolManager.getConnection(url,
                         sUsername, sPassword);
	       }
	       else
	           return null;
	       }
	       catch(Exception e)
	       {
      	    throw new
		          SQLException(e.getMessage());
	       }
}