XOOPS  2.6.0
Xoops\Core\Database\Factory Class Reference
Inheritance diagram for Xoops\Core\Database\Factory:
Inheritance graph

Static Public Member Functions

static getConnection ($options=null)
 

Detailed Description

Definition at line 31 of file Factory.php.

Member Function Documentation

static Xoops\Core\Database\Factory::getConnection (   $options = null)
static

Get a reference to the only instance of database class and connects to DB

if the class has not been instantiated yet, this will also take care of that

Doctrine connection function

NOTE: Persistance connection is not included. XOOPS_DB_PCONNECT is ignored. allowWebChanges also needs to be addressed

Parameters
array$optionsdriverOptions for Doctrine
Returns
Connection|null Reference to the only instance of database class
Todo:
change driver to support other databases and support for port, unix_socket and driver options.

Definition at line 51 of file Factory.php.

References Xoops\$config, $options, $xoops, XoopsBaseConfig\get(), and Xoops\getInstance().

Referenced by Xmf\Module\Helper\GenericHelper\_initHandler(), and Xmf\Module\Permission\init().

Here is the call graph for this function:

Here is the caller graph for this function:


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