MediaWiki
1.28.0
|
Format errors and warnings in the old style, for backwards compatibility. More...
Public Member Functions | |
__construct (ApiResult $result) | |
arrayFromStatus (Status $status, $type= 'error', $format=null) | |
Public Member Functions inherited from ApiErrorFormatter | |
__construct (ApiResult $result, Language $lang, $format, $useDB=false) | |
addError ($moduleName, $msg, $code=null, $data=null) | |
Add an error to the result. More... | |
addMessagesFromStatus ($moduleName, Status $status, $types=[ 'warning', 'error']) | |
Add warnings and errors from a Status object to the result. More... | |
addWarning ($moduleName, $msg, $code=null, $data=null) | |
Add a warning to the result. More... | |
arrayFromStatus (Status $status, $type= 'error', $format=null) | |
Format messages from a Status as an array. More... | |
Protected Member Functions | |
addWarningOrError ($tag, $moduleName, $msg) | |
Protected Member Functions inherited from ApiErrorFormatter | |
addWarningOrError ($tag, $moduleName, $msg) | |
Actually add the warning or error to the result. More... | |
getDummyTitle () | |
Fetch a dummy title to set on Messages. More... | |
Additional Inherited Members | |
Protected Attributes inherited from ApiErrorFormatter | |
$format = 'none' | |
Language | $lang |
ApiResult | $result |
$useDB = false | |
Format errors and warnings in the old style, for backwards compatibility.
Definition at line 236 of file ApiErrorFormatter.php.
ApiErrorFormatter_BackCompat::__construct | ( | ApiResult | $result | ) |
ApiResult | $result | Into which data will be added |
Definition at line 242 of file ApiErrorFormatter.php.
References Language\factory().
|
protected |
Definition at line 267 of file ApiErrorFormatter.php.
References $code, ApiBase\$messageMap, $path, $tag, $value, ApiResult\ADD_ON_TOP, ApiResult\NO_SIZE_CHECK, and ApiResult\OVERRIDE.
ApiErrorFormatter_BackCompat::arrayFromStatus | ( | Status | $status, |
$type = 'error' , |
|||
$format = null |
|||
) |
Definition at line 246 of file ApiErrorFormatter.php.
References ApiErrorFormatter\$result, $type, as, StatusValue\getErrorsByType(), StatusValue\isGood(), and ApiResult\setIndexedTagName().