summaryrefslogtreecommitdiffstats
path: root/system/database/drivers/pdo
diff options
context:
space:
mode:
authorTimothy Warren <tim@timshomepage.net>2012-03-20 00:05:25 +0100
committerTimothy Warren <tim@timshomepage.net>2012-03-20 00:05:25 +0100
commit5137ebcafe525752bfc79abc0628e45f55eb196e (patch)
tree4c5bf7c8dfdfa8af841dc84d80cb3b0422ac04ec /system/database/drivers/pdo
parent78a2de4e049f478ec1efd92d639aaf11be933335 (diff)
Revert "Fixed visibility declarations on dbforge and utility classes"
Diffstat (limited to 'system/database/drivers/pdo')
-rw-r--r--system/database/drivers/pdo/pdo_forge.php20
-rw-r--r--system/database/drivers/pdo/pdo_utility.php8
2 files changed, 17 insertions, 11 deletions
diff --git a/system/database/drivers/pdo/pdo_forge.php b/system/database/drivers/pdo/pdo_forge.php
index 7fca962b3..87b638570 100644
--- a/system/database/drivers/pdo/pdo_forge.php
+++ b/system/database/drivers/pdo/pdo_forge.php
@@ -39,10 +39,11 @@ class CI_DB_pdo_forge extends CI_DB_forge {
/**
* Create database
*
+ * @access private
* @param string the database name
* @return bool
*/
- public function _create_database()
+ function _create_database()
{
// PDO has no "create database" command since it's
// designed to connect to an existing database
@@ -58,10 +59,11 @@ class CI_DB_pdo_forge extends CI_DB_forge {
/**
* Drop database
*
+ * @access private
* @param string the database name
* @return bool
*/
- public function _drop_database($name)
+ function _drop_database($name)
{
// PDO has no "drop database" command since it's
// designed to connect to an existing database
@@ -77,6 +79,7 @@ class CI_DB_pdo_forge extends CI_DB_forge {
/**
* Create Table
*
+ * @access private
* @param string the table name
* @param array the fields
* @param mixed primary key(s)
@@ -84,7 +87,7 @@ class CI_DB_pdo_forge extends CI_DB_forge {
* @param boolean should 'IF NOT EXISTS' be added to the SQL
* @return bool
*/
- public function _create_table($table, $fields, $primary_keys, $keys, $if_not_exists)
+ function _create_table($table, $fields, $primary_keys, $keys, $if_not_exists)
{
$sql = 'CREATE TABLE ';
@@ -188,9 +191,10 @@ class CI_DB_pdo_forge extends CI_DB_forge {
/**
* Drop Table
*
+ * @access private
* @return bool
*/
- public function _drop_table($table)
+ function _drop_table($table)
{
// Not a supported PDO feature
if ($this->db->db_debug)
@@ -208,6 +212,7 @@ class CI_DB_pdo_forge extends CI_DB_forge {
* Generates a platform-specific query so that a table can be altered
* Called by add_column(), drop_column(), and column_alter(),
*
+ * @access private
* @param string the ALTER type (ADD, DROP, CHANGE)
* @param string the column name
* @param string the table name
@@ -217,7 +222,7 @@ class CI_DB_pdo_forge extends CI_DB_forge {
* @param string the field after which we should add the new field
* @return object
*/
- public function _alter_table($alter_type, $table, $column_name, $column_definition = '', $default_value = '', $null = '', $after_field = '')
+ function _alter_table($alter_type, $table, $column_name, $column_definition = '', $default_value = '', $null = '', $after_field = '')
{
$sql = 'ALTER TABLE `'.$this->db->protect_identifiers($table).'` '.$alter_type.' '.$this->db->protect_identifiers($column_name);
@@ -260,11 +265,12 @@ class CI_DB_pdo_forge extends CI_DB_forge {
*
* Generates a platform-specific query so that a table can be renamed
*
+ * @access private
* @param string the old table name
* @param string the new table name
* @return string
*/
- public function _rename_table($table_name, $new_table_name)
+ function _rename_table($table_name, $new_table_name)
{
return 'ALTER TABLE '.$this->db->protect_identifiers($table_name).' RENAME TO '.$this->db->protect_identifiers($new_table_name);
}
@@ -272,4 +278,4 @@ class CI_DB_pdo_forge extends CI_DB_forge {
}
/* End of file pdo_forge.php */
-/* Location: ./system/database/drivers/pdo/pdo_forge.php */ \ No newline at end of file
+/* Location: ./system/database/drivers/pdo/pdo_forge.php */
diff --git a/system/database/drivers/pdo/pdo_utility.php b/system/database/drivers/pdo/pdo_utility.php
index 02373b720..2c12d7438 100644
--- a/system/database/drivers/pdo/pdo_utility.php
+++ b/system/database/drivers/pdo/pdo_utility.php
@@ -41,7 +41,7 @@ class CI_DB_pdo_utility extends CI_DB_utility {
*
* @return bool
*/
- public function _list_databases()
+ protected function _list_databases()
{
// Not sure if PDO lets you list all databases...
if ($this->db->db_debug)
@@ -61,7 +61,7 @@ class CI_DB_pdo_utility extends CI_DB_utility {
* @param string the table name
* @return object
*/
- public function _optimize_table($table)
+ protected function _optimize_table($table)
{
// Not a supported PDO feature
if ($this->db->db_debug)
@@ -81,7 +81,7 @@ class CI_DB_pdo_utility extends CI_DB_utility {
* @param string the table name
* @return object
*/
- public function _repair_table($table)
+ protected function _repair_table($table)
{
// Not a supported PDO feature
if ($this->db->db_debug)
@@ -99,7 +99,7 @@ class CI_DB_pdo_utility extends CI_DB_utility {
* @param array Preferences
* @return mixed
*/
- public function _backup($params = array())
+ protected function _backup($params = array())
{
// Currently unsupported
return $this->db->display_error('db_unsuported_feature');