Joomla CMS
3.10.11 (avec JPlatform 13.1 inclus)
Documentation des API du CMS Joomla en version 3.10.11 et du framework Joomla Platform intégré
|
Fonctions membres publiques | |
getDriver ($name='joomla', $options=array()) | |
getQuery ($name, FOFDatabaseDriver $db=null) | |
Fonctions membres publiques statiques | |
static | getInstance () |
static | setInstance (FOFDatabaseFactory $instance=null) |
Attributs privés statiques | |
static | $_instance = null |
Joomla Platform Database Factory class
getDriver | ( | $name = 'joomla' , |
|
$options = array() |
|||
) |
Method to return a FOFDatabaseDriver instance based on the given options. There are three global options and then the rest are specific to the database driver. The 'database' option determines which database is to be used for the connection. The 'select' option determines whether the connector should automatically select the chosen database.
Instances are unique to the given options and new objects are only created when a unique options array is passed into the method. This ensures that we don't end up with unnecessary database connection resources.
string | $name | Name of the database driver you'd like to instantiate |
array | $options | Parameters to be passed to the database driver. |
RuntimeException |
|
static |
Gets an instance of the factory object.
Référencé par FOFIntegrationJoomlaPlatform\getDbo().
getQuery | ( | $name, | |
FOFDatabaseDriver | $db = null |
||
) |
Get the current query object or a new FOFDatabaseQuery object.
string | $name | Name of the driver you want an query object for. |
FOFDatabaseDriver | $db | Optional FOFDatabaseDriver instance |
RuntimeException |
|
static |
Gets an instance of a factory object to return on subsequent calls of getInstance.
FOFDatabaseFactory | $instance | A FOFDatabaseFactory object. |
|
staticprivate |