MediaWiki REL1_34
|
Public Member Functions | |
__construct (PermissionManager $permissionManager, RequestInterface $request, UserIdentity $user) | |
getUploadedFile ( $name, array $options) | |
Fetch data for a file upload. | |
getValue ( $name, $default, array $options) | |
Fetch a value from the request. | |
hasParam ( $name, array $options) | |
Test if a parameter exists in the request. | |
hasUpload ( $name, array $options) | |
Test if a parameter exists as an upload in the request. | |
recordCondition (ValidationException $condition, array $options) | |
Record non-fatal conditions. | |
useHighLimits (array $options) | |
Indicate whether "high limits" should be used. | |
Private Member Functions | |
getParamsFromSource ( $source) | |
Get the raw parameters from a source in the request. | |
Private Attributes | |
PermissionManager | $permissionManager |
RequestInterface | $request |
UserIdentity | $user |
Definition at line 13 of file ParamValidatorCallbacks.php.
MediaWiki\Rest\Validator\ParamValidatorCallbacks::__construct | ( | PermissionManager | $permissionManager, |
RequestInterface | $request, | ||
UserIdentity | $user | ||
) |
|
private |
Get the raw parameters from a source in the request.
string | $source | 'path', 'query', or 'post' |
Definition at line 39 of file ParamValidatorCallbacks.php.
References $source.
Referenced by MediaWiki\Rest\Validator\ParamValidatorCallbacks\getValue(), and MediaWiki\Rest\Validator\ParamValidatorCallbacks\hasParam().
MediaWiki\Rest\Validator\ParamValidatorCallbacks::getUploadedFile | ( | $name, | |
array | $options | ||
) |
Fetch data for a file upload.
string | $name | Parameter name of the upload |
array | $options | Options array |
Implements Wikimedia\ParamValidator\Callbacks.
Definition at line 75 of file ParamValidatorCallbacks.php.
Referenced by MediaWiki\Rest\Validator\ParamValidatorCallbacks\hasUpload().
MediaWiki\Rest\Validator\ParamValidatorCallbacks::getValue | ( | $name, | |
$default, | |||
array | $options | ||
) |
Fetch a value from the request.
Return $default
for file-upload parameters.
string | $name | Parameter name to fetch |
mixed | $default | Default value to return if the parameter is unset. |
array | $options | Options array |
Implements Wikimedia\ParamValidator\Callbacks.
Definition at line 60 of file ParamValidatorCallbacks.php.
References MediaWiki\Rest\Validator\ParamValidatorCallbacks\getParamsFromSource().
MediaWiki\Rest\Validator\ParamValidatorCallbacks::hasParam | ( | $name, | |
array | $options | ||
) |
Test if a parameter exists in the request.
string | $name | Parameter name |
array | $options | Options array |
Implements Wikimedia\ParamValidator\Callbacks.
Definition at line 55 of file ParamValidatorCallbacks.php.
References MediaWiki\Rest\Validator\ParamValidatorCallbacks\getParamsFromSource().
MediaWiki\Rest\Validator\ParamValidatorCallbacks::hasUpload | ( | $name, | |
array | $options | ||
) |
Test if a parameter exists as an upload in the request.
string | $name | Parameter name |
array | $options | Options array |
Implements Wikimedia\ParamValidator\Callbacks.
Definition at line 68 of file ParamValidatorCallbacks.php.
References MediaWiki\Rest\Validator\ParamValidatorCallbacks\getUploadedFile().
MediaWiki\Rest\Validator\ParamValidatorCallbacks::recordCondition | ( | ValidationException | $condition, |
array | $options | ||
) |
Record non-fatal conditions.
ValidationException | $condition | |
array | $options | Options array |
Implements Wikimedia\ParamValidator\Callbacks.
Definition at line 83 of file ParamValidatorCallbacks.php.
MediaWiki\Rest\Validator\ParamValidatorCallbacks::useHighLimits | ( | array | $options | ) |
Indicate whether "high limits" should be used.
Some settings have multiple limits, one for "normal" users and a higher one for "privileged" users. This is used to determine which class the current user is in when necessary.
array | $options | Options array |
Implements Wikimedia\ParamValidator\Callbacks.
Definition at line 87 of file ParamValidatorCallbacks.php.
|
private |
Definition at line 16 of file ParamValidatorCallbacks.php.
Referenced by MediaWiki\Rest\Validator\ParamValidatorCallbacks\__construct().
|
private |
Definition at line 19 of file ParamValidatorCallbacks.php.
Referenced by MediaWiki\Rest\Validator\ParamValidatorCallbacks\__construct().
|
private |
Definition at line 22 of file ParamValidatorCallbacks.php.
Referenced by MediaWiki\Rest\Validator\ParamValidatorCallbacks\__construct().