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