CDBMessageIndex Class Reference

Storage on CDB files. More...

Inheritance diagram for CDBMessageIndex:
Inheritance graph
[legend]
Collaboration diagram for CDBMessageIndex:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 retrieve ()

Protected Member Functions

 get ($key)
 Looks up the stored value for single key.
 store (array $array)
 getReader ()

Protected Attributes

 $index
 $reader
 $filename = 'translate_messageindex.cdb'

Detailed Description

Storage on CDB files.

This is improved version of SerializedMessageIndex. It uses CDB files for storage, which means it provides random access. The CDB files are about double the size of serialized files (~7M for 50000 keys).

Loading the whole index is slower than serialized, but about the same as for database. Suitable for single-server setups where SerializedMessageIndex is too slow for sloading the whole index.

Since:
2012-04-10

Definition at line 434 of file MessageIndex.php.


Member Function Documentation

CDBMessageIndex::get ( key  )  [protected]

Looks up the stored value for single key.

Only for testing.

Since:
2012-04-10
Parameters:
string $key
Returns:
string|array|null

Reimplemented from MessageIndex.

Reimplemented in TestableCDBMessageIndex.

Definition at line 463 of file MessageIndex.php.

Here is the call graph for this function:

CDBMessageIndex::getReader (  )  [protected]

Definition at line 506 of file MessageIndex.php.

Referenced by get(), and retrieve().

Here is the call graph for this function:

CDBMessageIndex::retrieve (  ) 
Returns:
array

Reimplemented from MessageIndex.

Definition at line 445 of file MessageIndex.php.

Here is the call graph for this function:

CDBMessageIndex::store ( array $  array  )  [protected]

Reimplemented from MessageIndex.

Reimplemented in TestableCDBMessageIndex.

Definition at line 486 of file MessageIndex.php.

Here is the call graph for this function:


Member Data Documentation

CDBMessageIndex::$filename = 'translate_messageindex.cdb' [protected]

Definition at line 442 of file MessageIndex.php.

CDBMessageIndex::$index [protected]

Definition at line 436 of file MessageIndex.php.

CDBMessageIndex::$reader [protected]

Definition at line 439 of file MessageIndex.php.

Referenced by get(), and retrieve().


The documentation for this class was generated from the following file:
Generated on Tue Oct 29 00:00:44 2013 for MediaWiki Translate Extension by  doxygen 1.6.3