MediaWiki  master
LCStoreDB Class Reference

LCStore implementation which uses the standard DB functions to store data. More...

Inheritance diagram for LCStoreDB:
Collaboration diagram for LCStoreDB:

Public Member Functions

 __construct ( $params)
 
 finishWrite ()
 Finish a write transaction. More...
 
 get ( $code, $key)
 Get a value. More...
 
 set ( $key, $value)
 Set a key to a given value. More...
 
 startWrite ( $code)
 Start a write transaction. More...
 

Detailed Description

LCStore implementation which uses the standard DB functions to store data.

Definition at line 31 of file LCStoreDB.php.

Constructor & Destructor Documentation

◆ __construct()

LCStoreDB::__construct (   $params)

Definition at line 47 of file LCStoreDB.php.

Member Function Documentation

◆ finishWrite()

◆ get()

LCStoreDB::get (   $code,
  $key 
)

Get a value.

Parameters
string$codeLanguage code
string$keyCache key

Implements LCStore.

Definition at line 51 of file LCStoreDB.php.

References DB_REPLICA, and wfGetDB().

◆ set()

LCStoreDB::set (   $key,
  $value 
)

Set a key to a given value.

startWrite() must be called before this is called, and finishWrite() must be called afterwards.

Parameters
string$key
mixed$value

Implements LCStore.

Definition at line 115 of file LCStoreDB.php.

References Wikimedia\Rdbms\IDatabase\encodeBlob().

◆ startWrite()

LCStoreDB::startWrite (   $code)

Start a write transaction.

Parameters
string$codeLanguage code

Implements LCStore.

Definition at line 71 of file LCStoreDB.php.

References Wikimedia\Rdbms\IDatabase\isReadOnly().


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