| 1 |
<?php |
| 2 |
|
| 3 |
namespace MediaWiki\Settings; |
| 4 |
|
| 5 |
use RuntimeException; |
| 6 |
use Throwable; |
| 7 |
use Wikimedia\NormalizedException\INormalizedException; |
| 8 |
use Wikimedia\NormalizedException\NormalizedExceptionTrait; |
| 9 |
|
| 10 |
class SettingsBuilderException extends RuntimeException implements INormalizedException { |
| 11 |
use NormalizedExceptionTrait; |
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
public function __construct( |
| 20 |
string $normalizedMessage = '', |
| 21 |
array $messageContext = [], |
| 22 |
int $code = 0, |
| 23 |
?Throwable $previous = null |
| 24 |
) { |
| 25 |
$this->normalizedMessage = $normalizedMessage; |
| 26 |
$this->messageContext = $messageContext; |
| 27 |
parent::__construct( |
| 28 |
self::getMessageFromNormalizedMessage( $normalizedMessage, $messageContext ), |
| 29 |
$code, |
| 30 |
$previous |
| 31 |
); |
| 32 |
} |
| 33 |
} |