MediaWiki
REL1_37
DBExpectedError.php
Go to the documentation of this file.
1
<?php
21
namespace
Wikimedia\Rdbms
;
22
23
use
MessageSpecifier
;
24
34
class
DBExpectedError
extends
DBError
implements
MessageSpecifier
{
36
protected
$params
;
37
45
public
function
__construct
(
46
?
IDatabase
$db
, $error, array
$params
= [], \Throwable $prev =
null
47
) {
48
parent::__construct(
$db
, $error, $prev );
49
$this->params =
$params
;
50
}
51
52
public
function
getKey
() {
53
return
'databaseerror-text'
;
54
}
55
56
public
function
getParams
() {
57
return
$this->params
;
58
}
59
}
60
64
class_alias( DBExpectedError::class,
'DBExpectedError'
);
Wikimedia\Rdbms\DBError
Database error base class @newable.
Definition
DBError.php:32
Wikimedia\Rdbms\DBError\$db
IDatabase null $db
Definition
DBError.php:34
Wikimedia\Rdbms\DBExpectedError
Base class for the more common types of database errors.
Definition
DBExpectedError.php:34
Wikimedia\Rdbms\DBExpectedError\$params
string[] $params
Message parameters.
Definition
DBExpectedError.php:36
Wikimedia\Rdbms\DBExpectedError\getParams
getParams()
Returns the message parameters.
Definition
DBExpectedError.php:56
Wikimedia\Rdbms\DBExpectedError\getKey
getKey()
Returns the message key.
Definition
DBExpectedError.php:52
Wikimedia\Rdbms\DBExpectedError\__construct
__construct(?IDatabase $db, $error, array $params=[], \Throwable $prev=null)
Definition
DBExpectedError.php:45
MessageSpecifier
Definition
MessageSpecifier.php:24
Wikimedia\Rdbms\IDatabase
Basic database interface for live and lazy-loaded relation database handles.
Definition
IDatabase.php:38
Wikimedia\Rdbms
Definition
ChronologyProtector.php:24
includes
libs
rdbms
exception
DBExpectedError.php
Generated on Fri Apr 5 2024 23:40:31 for MediaWiki by
1.9.8