/** Makes the default connection.
@param PntDbQueryHandler $qh The QueryHandler that will make the connection,
* or null if an arbitrary instance of QueryHandler may be used.
* @param boolean $makeDefault Wheather to make the connection the default
* */
function ($qh=null, $makeDefault=true) {
if (!$qh) $qh = new QueryHandler();
$qh->($this);
$qh->(); //sets $this->dbSource
if ($this->dbSource === false) return;
//connection succeeded
if ($makeDefault)
DatabaseConnection::defaultConnection($this);
}
|