コード例 #1
0
ファイル: Pool.php プロジェクト: ruslankus/invoice-crm
 /**
  * This function releases the specified connection within the connection pool.  The
  * connection will then be allowed to close via its destructor when completely unset.
  *
  * @access public
  * @param DB_Connection_Driver $connection      the connection to be released
  */
 public function release(DB_Connection_Driver $connection)
 {
     if ($connection !== NULL) {
         $connection_id = $connection->__hashCode();
         if (isset($this->lookup[$connection_id])) {
             $data_source_id = $this->lookup[$connection_id];
             unset($this->pool[$data_source_id][$connection_id]);
             unset($this->lookup[$connection_id]);
         }
     }
 }