Translate extension for MediaWiki
 
Loading...
Searching...
No Matches
ParsingFailure.php
1<?php
2declare( strict_types = 1 );
3
4namespace MediaWiki\Extension\Translate\PageTranslation;
5
6use RuntimeException;
7use Wikimedia\Message\MessageSpecifier;
8
19class ParsingFailure extends RuntimeException {
20 private MessageSpecifier $messageSpec;
21
22 public function __construct( string $message, MessageSpecifier $messageSpec ) {
23 parent::__construct( $message );
24 $this->messageSpec = $messageSpec;
25 }
26
27 public function getMessageSpecification(): MessageSpecifier {
28 return $this->messageSpec;
29 }
30}
Represents any kind of failure to parse a translatable page source code.