Mage_Core_Model_Resource_Type_Db_Pdo_Mysql Class Reference

Inheritance diagram for Mage_Core_Model_Resource_Type_Db_Pdo_Mysql:

Mage_Core_Model_Resource_Type_Db Mage_Core_Model_Resource_Type_Abstract

List of all members.

Public Member Functions

 getConnection ($config)

Protected Member Functions

 _getDbAdapterInstance ($configArr)
 _getDbAdapterClassName ()


Detailed Description

Definition at line 28 of file Mysql.php.


Member Function Documentation

_getDbAdapterClassName (  )  [protected]

Retrieve DB adapter class name

Returns:
string

Definition at line 69 of file Mysql.php.

00070     {
00071         return 'Varien_Db_Adapter_Pdo_Mysql';
00072     }

_getDbAdapterInstance ( configArr  )  [protected]

Create and return DB adapter object instance

Parameters:
array $configArr Connection config
Returns:
Varien_Db_Adapter_Pdo_Mysql

Definition at line 57 of file Mysql.php.

00058     {
00059         $className = $this->_getDbAdapterClassName();
00060         $adapter = new $className($configArr);
00061         return $adapter;
00062     }

getConnection ( config  ) 

Enter description here...

Parameters:
array $config Connection config
Returns:
Varien_Db_Adapter_Pdo_Mysql

Definition at line 37 of file Mysql.php.

00038     {
00039         $configArr = (array)$config;
00040         $configArr['profiler'] = !empty($configArr['profiler']) && $configArr['profiler']!=='false';
00041 
00042         $conn = $this->_getDbAdapterInstance($configArr);
00043 
00044         if (!empty($configArr['initStatements']) && $conn) {
00045             $conn->query($configArr['initStatements']);
00046         }
00047 
00048         return $conn;
00049     }


The documentation for this class was generated from the following file:

Generated on Sat Jul 4 17:24:00 2009 for Magento by  doxygen 1.5.8