wiki.techinc.nl/includes/Rest/PathTemplateMatcher/PathSegmentException.php
Umherirrender 503bff0b04 Rest: Add missing documentation to class properties
Add doc-typehints to class properties found by the PropertyDocumentation
sniff to improve the documentation.

Once the sniff is enabled it avoids that new code is missing type
declarations. This is focused on documentation and does not change code.

Change-Id: Idf17719c875466810313f0fbbf16bc67f3e40059
2024-09-07 21:49:56 +02:00

28 lines
545 B
PHP

<?php
namespace MediaWiki\Rest\PathTemplateMatcher;
use Exception;
/**
* @newable
*/
class PathSegmentException extends Exception {
/** @var string */
public $template;
/** @var mixed */
public $userData;
/**
* @stable to call
*
* @param string $template
* @param mixed $userData
*/
public function __construct( $template, $userData ) {
$this->template = $template;
$this->userData = $userData;
parent::__construct( "Unable to add path template \"$template\" since it contains " .
"an empty path segment." );
}
}