DatabaseModelTrait

Trait representing a model holding a database reference

since

1.3.0

note

As of 2.0 the Joomla\Database\DatabaseInterface will be typehinted.

Methods

getDb

Get the database driver.

getDb() : \Joomla\Database\DatabaseDriver
since

1.3.0

throws

\UnexpectedValueException

Response

\Joomla\Database\DatabaseDriverThe database driver.

setDb

Set the database driver.

setDb(\Joomla\Database\DatabaseDriver $db) : void
since

1.3.0

Arguments

$db

\Joomla\Database\DatabaseDriverThe database driver.

Properties

db

The database driver.

since

1.3.0

Type(s)

\Joomla\Database\DatabaseDriver