diff options
author | Phil Sturgeon <email@philsturgeon.co.uk> | 2012-01-27 19:54:13 +0100 |
---|---|---|
committer | Phil Sturgeon <email@philsturgeon.co.uk> | 2012-01-27 19:54:13 +0100 |
commit | 0c4fb6a578d23e5a0fa5c8ce41a75d2b2b1310e7 (patch) | |
tree | 09099689064cb390799a4e67a6cdceb61e89e2be /system/database/drivers/mysqli/mysqli_utility.php | |
parent | 756e70c1d6b27b20c4e093d48466842fcba31a00 (diff) | |
parent | a3c5cfca6b4a1ec183f3b3c9af88c7f686cf167e (diff) |
Merge pull request #992 from narfbg/develop-db-mysqli
Improve the MySQLi database driver
Diffstat (limited to 'system/database/drivers/mysqli/mysqli_utility.php')
-rw-r--r-- | system/database/drivers/mysqli/mysqli_utility.php | 34 |
1 files changed, 14 insertions, 20 deletions
diff --git a/system/database/drivers/mysqli/mysqli_utility.php b/system/database/drivers/mysqli/mysqli_utility.php index 76bd49e31..3fdc5c723 100644 --- a/system/database/drivers/mysqli/mysqli_utility.php +++ b/system/database/drivers/mysqli/mysqli_utility.php @@ -1,13 +1,13 @@ -<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); +<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * NOTICE OF LICENSE - * + * * Licensed under the Open Software License version 3.0 - * + * * This source file is subject to the Open Software License (OSL 3.0) that is * bundled with this package in the files license.txt / license.rst. It is * also available through the world wide web at this URL: @@ -25,8 +25,6 @@ * @filesource */ -// ------------------------------------------------------------------------ - /** * MySQLi Utility Class * @@ -39,12 +37,11 @@ class CI_DB_mysqli_utility extends CI_DB_utility { /** * List databases * - * @access private - * @return bool + * @return string */ - function _list_databases() + public function _list_databases() { - return "SHOW DATABASES"; + return 'SHOW DATABASES'; } // -------------------------------------------------------------------- @@ -54,13 +51,12 @@ class CI_DB_mysqli_utility extends CI_DB_utility { * * Generates a platform-specific query so that a table can be optimized * - * @access private * @param string the table name - * @return object + * @return string */ - function _optimize_table($table) + public function _optimize_table($table) { - return "OPTIMIZE TABLE ".$this->db->_escape_identifiers($table); + return 'OPTIMIZE TABLE '.$this->db->_escape_identifiers($table); } // -------------------------------------------------------------------- @@ -70,13 +66,12 @@ class CI_DB_mysqli_utility extends CI_DB_utility { * * Generates a platform-specific query so that a table can be repaired * - * @access private * @param string the table name - * @return object + * @return string */ - function _repair_table($table) + public function _repair_table($table) { - return "REPAIR TABLE ".$this->db->_escape_identifiers($table); + return 'REPAIR TABLE '.$this->db->_escape_identifiers($table); } // -------------------------------------------------------------------- @@ -84,11 +79,10 @@ class CI_DB_mysqli_utility extends CI_DB_utility { /** * MySQLi Export * - * @access private * @param array Preferences * @return mixed */ - function _backup($params = array()) + public function _backup($params = array()) { // Currently unsupported return $this->db->display_error('db_unsuported_feature'); @@ -96,4 +90,4 @@ class CI_DB_mysqli_utility extends CI_DB_utility { } /* End of file mysqli_utility.php */ -/* Location: ./system/database/drivers/mysqli/mysqli_utility.php */
\ No newline at end of file +/* Location: ./system/database/drivers/mysqli/mysqli_utility.php */ |