MediaWiki
master
HistoryBlobCurStub.php
Go to the documentation of this file.
1
<?php
9
use
MediaWiki\MediaWikiServices
;
10
16
class
HistoryBlobCurStub
{
18
public
$mCurId
;
19
23
public
function
__construct
( $curid = 0 ) {
24
$this->mCurId = $curid;
25
}
26
33
public
function
setLocation
( $id ) {
34
$this->mCurId = $id;
35
}
36
40
public
function
getText
() {
41
$dbr = MediaWikiServices::getInstance()->getConnectionProvider()->getReplicaDatabase();
42
return
$dbr->newSelectQueryBuilder()
43
->select(
'cur_text'
)
44
->from(
'cur'
)
45
->where( [
'cur_id'
=> $this->mCurId ] )
46
->caller( __METHOD__ )
47
->fetchField();
48
}
49
}
50
51
// Blobs generated by MediaWiki < 1.5 on PHP 4 were serialized with the
52
// class name coerced to lowercase. We can improve efficiency by adding
53
// autoload entries for the lowercase variants of these classes (T166759).
54
// The code below is never executed, but it is picked up by the AutoloadGenerator
55
// parser, which scans for class_alias() calls.
56
/*
57
class_alias( HistoryBlobCurStub::class, 'historyblobcurstub' );
58
*/
HistoryBlobCurStub
To speed up conversion from 1.4 to 1.5 schema, text rows can refer to the leftover cur table as the b...
Definition
HistoryBlobCurStub.php:16
HistoryBlobCurStub\$mCurId
int $mCurId
Definition
HistoryBlobCurStub.php:18
HistoryBlobCurStub\setLocation
setLocation( $id)
Sets the location (cur_id) of the main object to which this object points.
Definition
HistoryBlobCurStub.php:33
HistoryBlobCurStub\__construct
__construct( $curid=0)
Definition
HistoryBlobCurStub.php:23
HistoryBlobCurStub\getText
getText()
Definition
HistoryBlobCurStub.php:40
MediaWiki\MediaWikiServices
Service locator for MediaWiki core services.
Definition
MediaWikiServices.php:265
includes
HistoryBlob
HistoryBlobCurStub.php
Generated on Wed May 20 2026 21:25:25 for MediaWiki by
1.10.0