MediaWiki REL1_34
ApiDisabled.php
Go to the documentation of this file.
1<?php
33class ApiDisabled extends ApiBase {
34
35 public function execute() {
36 $this->dieWithError( [ 'apierror-moduledisabled', $this->getModuleName() ] );
37 }
38
39 public function isReadMode() {
40 return false;
41 }
42
43 protected function getSummaryMessage() {
44 return 'apihelp-disabled-summary';
45 }
46
47 protected function getExtendedDescription() {
48 return 'apihelp-disabled-extended-description';
49 }
50}
This abstract class implements many basic API functions, and is the base of all API classes.
Definition ApiBase.php:42
dieWithError( $msg, $code=null, $data=null, $httpCode=null)
Abort execution with an error.
Definition ApiBase.php:2014
getModuleName()
Get the name of the module being executed by this instance.
Definition ApiBase.php:520
API module that dies with an error immediately.
execute()
Evaluates the parameters, performs the requested query, and sets up the result.
getSummaryMessage()
Return the summary message.
getExtendedDescription()
Return the extended help text message.
isReadMode()
Indicates whether this module requires read rights.