MediaWiki
REL1_19
|
CDB reader class. More...
Public Member Functions | |
__construct ($fileName) | |
close () | |
Close the file. | |
get ($key) | |
Public Attributes | |
$dlen | |
$dpos | |
$fileName | |
The filename. | |
$handle | |
The file handle. | |
$hpos | |
$hslots | |
$khash | |
$kpos | |
$loop | |
Protected Member Functions | |
find ($key) | |
findNext ($key) | |
findStart () | |
match ($key, $pos) | |
read ($length, $pos) | |
unpack31 ($s) | |
Unpack an unsigned integer and throw an exception if it needs more than 31 bits. | |
unpackSigned ($s) | |
Unpack a 32-bit signed integer. |
CDB reader class.
Definition at line 84 of file Cdb_PHP.php.
CdbReader_PHP::__construct | ( | $ | fileName | ) |
$fileName | string |
Reimplemented from CdbReader.
Definition at line 115 of file Cdb_PHP.php.
References $fileName, and findStart().
Close the file.
Optional, you can just let the variable go out of scope.
Reimplemented from CdbReader.
Definition at line 124 of file Cdb_PHP.php.
CdbReader_PHP::find | ( | $ | key | ) | [protected] |
$key |
Definition at line 257 of file Cdb_PHP.php.
References findNext(), and findStart().
Referenced by get().
CdbReader_PHP::findNext | ( | $ | key | ) | [protected] |
$key |
Definition at line 211 of file Cdb_PHP.php.
References CdbFunctions\hash(), match(), read(), unpack31(), unpackSigned(), CdbFunctions\unsignedMod(), and CdbFunctions\unsignedShiftRight().
Referenced by find().
CdbReader_PHP::findStart | ( | ) | [protected] |
Definition at line 154 of file Cdb_PHP.php.
Referenced by __construct(), and find().
CdbReader_PHP::get | ( | $ | key | ) |
$key |
Reimplemented from CdbReader.
Definition at line 135 of file Cdb_PHP.php.
References find(), and read().
CdbReader_PHP::match | ( | $ | key, |
$ | pos | ||
) | [protected] |
$key | |
$pos |
Definition at line 149 of file Cdb_PHP.php.
References read().
Referenced by findNext().
CdbReader_PHP::read | ( | $ | length, |
$ | pos | ||
) | [protected] |
MWException |
$length | |
$pos |
Definition at line 164 of file Cdb_PHP.php.
Referenced by findNext(), get(), and match().
CdbReader_PHP::unpack31 | ( | $ | s | ) | [protected] |
Unpack an unsigned integer and throw an exception if it needs more than 31 bits.
$s |
Definition at line 188 of file Cdb_PHP.php.
Referenced by findNext().
CdbReader_PHP::unpackSigned | ( | $ | s | ) | [protected] |
Unpack a 32-bit signed integer.
$s |
Definition at line 202 of file Cdb_PHP.php.
Referenced by findNext().
CdbReader_PHP::$dlen |
Definition at line 110 of file Cdb_PHP.php.
CdbReader_PHP::$dpos |
Definition at line 107 of file Cdb_PHP.php.
CdbReader_PHP::$fileName |
CdbReader_PHP::$handle |
The file handle.
Definition at line 89 of file Cdb_PHP.php.
CdbReader_PHP::$hpos |
Definition at line 101 of file Cdb_PHP.php.
CdbReader_PHP::$hslots |
Definition at line 104 of file Cdb_PHP.php.
CdbReader_PHP::$khash |
Definition at line 95 of file Cdb_PHP.php.
CdbReader_PHP::$kpos |
Definition at line 98 of file Cdb_PHP.php.
CdbReader_PHP::$loop |
Definition at line 92 of file Cdb_PHP.php.