MediaWiki  REL1_19
FakeResultWrapper Class Reference

Overloads the relevant methods of the real ResultsWrapper so it doesn't go anywhere near an actual database. More...

Inheritance diagram for FakeResultWrapper:
Collaboration diagram for FakeResultWrapper:

List of all members.

Public Member Functions

 __construct ($array)
 fetchObject ()
 Fetch the next row from the given result object, in object form.
 fetchRow ()
 Fetch the next row from the given result object, in associative array form.
 free ()
 Free a result object.
 next ()
 numRows ()
 rewind ()
 seek ($row)
 Change the position of the cursor in a result object.

Public Attributes

 $currentRow = null
 $db = null
 $pos = 0
 $result = array()

Detailed Description

Overloads the relevant methods of the real ResultsWrapper so it doesn't go anywhere near an actual database.

Definition at line 199 of file DatabaseUtility.php.


Constructor & Destructor Documentation

Definition at line 205 of file DatabaseUtility.php.


Member Function Documentation

Fetch the next row from the given result object, in object form.

Fields can be retrieved with $row->fieldname, with fields acting like member variables.

Returns:
object
Exceptions:
DBUnexpectedErrorThrown if the database returns an error

Reimplemented from ResultWrapper.

Definition at line 233 of file DatabaseUtility.php.

References fetchRow().

Referenced by next().

Here is the call graph for this function:

Here is the caller graph for this function:

Fetch the next row from the given result object, in associative array form.

Fields are retrieved with $row['fieldname'].

Returns:
Array
Exceptions:
DBUnexpectedErrorThrown if the database returns an error

Reimplemented from ResultWrapper.

Definition at line 216 of file DatabaseUtility.php.

Referenced by fetchObject().

Here is the caller graph for this function:

Free a result object.

Reimplemented from ResultWrapper.

Definition at line 230 of file DatabaseUtility.php.

Returns:
int

Reimplemented from ResultWrapper.

Definition at line 247 of file DatabaseUtility.php.

References fetchObject().

Here is the call graph for this function:

Returns:
int

Reimplemented from ResultWrapper.

Definition at line 212 of file DatabaseUtility.php.

Reimplemented from ResultWrapper.

Definition at line 242 of file DatabaseUtility.php.

Change the position of the cursor in a result object.

See mysql_data_seek()

Parameters:
$rowinteger

Reimplemented from ResultWrapper.

Definition at line 226 of file DatabaseUtility.php.


Member Data Documentation

FakeResultWrapper::$currentRow = null

Reimplemented from ResultWrapper.

Definition at line 203 of file DatabaseUtility.php.

FakeResultWrapper::$db = null

Reimplemented from ResultWrapper.

Definition at line 201 of file DatabaseUtility.php.

FakeResultWrapper::$pos = 0

Reimplemented from ResultWrapper.

Definition at line 202 of file DatabaseUtility.php.

FakeResultWrapper::$result = array()

Reimplemented from ResultWrapper.

Definition at line 200 of file DatabaseUtility.php.


The documentation for this class was generated from the following file: