DboMysqli Class Reference

Inheritance diagram for DboMysqli:

DboMysqlBase DboSource DataSource Object List of all members.

Public Member Functions

 _execute ($sql)
 _executeProcedure ($sql)
 column ($real)
 connect ()
 describe (&$model)
 disconnect ()
 fetchResult ()
 getEncoding ()
 hasResult ()
 lastAffected ()
 lastError ()
 lastInsertId ($source=null)
 lastNumRows ()
 length ($real)
 listSources ()
 resultSet (&$results)
 value ($data, $column=null, $safe=false)

Public Attributes

 $_baseConfig
 $description = "Mysqli DBO Driver"

Detailed Description

Definition at line 36 of file dbo_mysqli.php.


Member Function Documentation

DboMysqli::_execute ( sql  ) 

Executes given SQL statement.

Parameters:
string $sql SQL statement
Returns:
resource Result resource identifier protected

Definition at line 105 of file dbo_mysqli.php.

References _executeProcedure().

Referenced by listSources().

DboMysqli::_executeProcedure ( sql  ) 

Executes given SQL statement (procedure call).

Parameters:
string $sql SQL statement (procedure call)
Returns:
resource Result resource identifier for first recordset protected

Definition at line 118 of file dbo_mysqli.php.

Referenced by _execute().

DboMysqli::column ( real  ) 

Converts database-layer column types to basic types

Parameters:
string $real Real database-layer column type (i.e. "varchar(255)")
Returns:
string Abstract column type (i.e. "string")

Reimplemented from DataSource.

Definition at line 289 of file dbo_mysqli.php.

References length(), DboSource::limit(), and DboSource::name().

Referenced by describe().

DboMysqli::connect (  ) 

Connects to the database using options in the given configuration array.

Returns:
boolean True if the database could be connected, else false

Definition at line 62 of file dbo_mysqli.php.

References DataSource::$config, config(), and DboMysqlBase::setEncoding().

DboMysqli::describe ( &$  model  ) 

Returns an array of the fields in given table name.

Parameters:
string $tableName Name of database table to inspect
Returns:
array Fields in table. Keys are name and type

Definition at line 158 of file dbo_mysqli.php.

References DataSource::__cacheDescription(), column(), DboSource::fullTableName(), DboMysqlBase::index(), length(), and DboSource::query().

DboMysqli::disconnect (  ) 

Disconnects from database.

Returns:
boolean True if the database could be disconnected, else false

Definition at line 91 of file dbo_mysqli.php.

DboMysqli::fetchResult (  ) 

Fetches the next row from the current result set

Returns:
unknown

Definition at line 378 of file dbo_mysqli.php.

References DboSource::$index.

DboMysqli::getEncoding (  ) 

Gets the database encoding

Returns:
string The database encoding

Definition at line 399 of file dbo_mysqli.php.

DboMysqli::hasResult (  ) 

Checks if the result is valid

Returns:
boolean True if the result is valid, else false

Reimplemented from DboSource.

Definition at line 407 of file dbo_mysqli.php.

Referenced by lastNumRows().

DboMysqli::lastAffected (  ) 

Returns number of affected rows in previous database operation. If no previous operation exists, this returns false.

Returns:
integer Number of affected rows

Definition at line 252 of file dbo_mysqli.php.

DboMysqli::lastError (  ) 

Returns a formatted error message from previous database operation.

Returns:
string Error message with error number

Definition at line 240 of file dbo_mysqli.php.

DboMysqli::lastInsertId ( source = null  ) 

Returns the ID generated from the previous INSERT operation.

Parameters:
unknown_type $source
Returns:
in

Reimplemented from DataSource.

Definition at line 276 of file dbo_mysqli.php.

References $id, and DboSource::fetchRow().

DboMysqli::lastNumRows (  ) 

Returns number of rows in previous resultset. If no previous resultset exists, this returns false.

Returns:
integer Number of rows in resultset

Definition at line 264 of file dbo_mysqli.php.

References hasResult().

DboMysqli::length ( real  ) 

Gets the length of a database-native column description, or null if no length

Parameters:
string $real Real database-layer column type (i.e. "varchar(255)")
Returns:
integer An integer representing the length of the column

Reimplemented from DboSource.

Definition at line 336 of file dbo_mysqli.php.

Referenced by column(), and describe().

DboMysqli::listSources (  ) 

Returns an array of sources (tables) in the database.

Returns:
array Array of tablenames in the database

Definition at line 133 of file dbo_mysqli.php.

References _execute(), config(), and DboSource::name().

DboMysqli::resultSet ( &$  results  ) 

Enter description here...

Parameters:
unknown_type $results

Definition at line 354 of file dbo_mysqli.php.

References DboSource::$index, and DboSource::name().

DboMysqli::value ( data,
column = null,
safe = false 
)

Returns a quoted and escaped string of $data for use in an SQL statement.

Parameters:
string $data String to be prepared for use in an SQL statement
string $column The column into which this data will be inserted
boolean $safe Whether or not numeric data should be handled automagically if no column data is provided
Returns:
string Quoted and escaped data

Reimplemented from DboSource.

Definition at line 197 of file dbo_mysqli.php.

References DboSource::boolean(), and DboSource::introspectType().


Member Data Documentation

DboMysqli::$_baseConfig

Initial value:

 array(
        'persistent' => true,
        'host' => 'localhost',
        'login' => 'root',
        'password' => '',
        'database' => 'cake',
        'port' => '3306',
        'connect' => 'mysqli_connect'
    )

Reimplemented from DataSource.

Definition at line 48 of file dbo_mysqli.php.

DboMysqli::$description = "Mysqli DBO Driver"

Reimplemented from DboMysqlBase.

Definition at line 42 of file dbo_mysqli.php.


The documentation for this class was generated from the following file:
Generated on Sun Nov 22 00:30:55 2009 for CakePHP 1.2.x.x (v1.2.4.8284) by doxygen 1.4.7