Added __call method to query builder

This commit is contained in:
Timothy Warren 2012-04-02 09:40:16 -04:00
parent da92e9c85c
commit 24ce87ca08
2 changed files with 19 additions and 0 deletions

View File

@ -111,6 +111,25 @@ class Query_Builder {
$this->sql =& $this->db->sql; $this->sql =& $this->db->sql;
} }
// --------------------------------------------------------------------------
/**
* Return methods from the driver object
*
* @param string $name
* @param array $params
* @return mixed
*/
public function __call($name, $params)
{
if (method_exists($this->db, $name))
{
return call_user_func_array(array($this->db, $name), $params);
}
return NULL;
}
// -------------------------------------------------------------------------- // --------------------------------------------------------------------------
// ! Select Queries // ! Select Queries
// -------------------------------------------------------------------------- // --------------------------------------------------------------------------

Binary file not shown.