private void initConnection() throws AdeException {
  if (!dbPropertiesInitialized) {
    throw new AdeInternalException("DB configuration is undefined.");
  }
  mLogger.debug("Loading driver " + dbDriver);
  try {
    Class.forName(dbDriver);
  }
 catch (  ClassNotFoundException e) {
    throw new AdeInternalException("Loading driver failed.",e);
  }
  mLogger.debug("Connecting to database " + dbURL);
  try {
    if (dbUserName == null || dbUserPassword == null) {
      dbConnection=DriverManager.getConnection(dbURL);
    }
 else {
      dbConnection=DriverManager.getConnection(dbURL,dbUserName,dbUserPassword);
    }
  }
 catch (  SQLException e) {
    throw new AdeInternalException("Failed obtaining connection.",e);
  }
catch (  Throwable t) {
    throw new AdeInternalException("Failed obtaining connection.",t);
  }
}

private void initConnection ( ) throws AdeException { if ( ! dbPropertiesInitialized ) { throw new AdeInternalException ( "DB configuration is undefined." ) ; } mLogger . debug ( "Loading driver " + dbDriver ) ; try { Class . forName ( dbDriver ) ; } catch ( ClassNotFoundException e ) { throw new AdeInternalException ( "Loading driver failed." , e ) ; } mLogger . debug ( "Connecting to database " + dbURL ) ; try { if ( dbUserName == null || dbUserPassword == null ) { dbConnection = DriverManager . getConnection ( dbURL ) ; } else { dbConnection = DriverManager . getConnection ( dbURL , dbUserName , dbUserPassword ) ; } } catch ( SQLException e ) { throw new AdeInternalException ( "Failed obtaining connection." , e ) ; } catch ( Throwable t ) { throw new AdeInternalException ( "Failed obtaining connection." , t ) ; } }
initializes a connection object .
