MediaWiki
REL1_24
|
This abstract class implements many basic API functions, and is the base of all API classes. More...
Public Member Functions | |
__construct (ApiMain $mainModule, $moduleName, $modulePrefix= '') | |
Public Attributes | |
string | $mModulePrefix |
const | GET_VALUES_FOR_HELP = 1 |
getAllowedParams() flag: When set, the result could take longer to generate, but should be more thorough. | |
const | LIMIT_BIG1 = 500 |
const | LIMIT_BIG2 = 5000 |
const | LIMIT_SML1 = 50 |
const | LIMIT_SML2 = 500 |
const | PARAM_ALLOW_DUPLICATES = 6 |
const | PARAM_DEPRECATED = 7 |
const | PARAM_DFLT = 0 |
const | PARAM_ISMULTI = 1 |
const | PARAM_MAX = 3 |
const | PARAM_MAX2 = 4 |
const | PARAM_MIN = 5 |
const | PARAM_RANGE_ENFORCE = 9 |
const | PARAM_REQUIRED = 8 |
const | PARAM_TYPE = 2 |
Private Attributes | |
ApiMain | $mMainModule |
* | |
string | $mModuleName |
* | |
$mParamCache = array() | |
$mSlaveDB = null | |
Methods to implement | |
execute () | |
Evaluates the parameters, performs the requested query, and sets up the result. | |
getModuleManager () | |
Get the module manager, or null if this module has no sub-modules. | |
getCustomPrinter () | |
If the module may only be used with a certain format module, it should override this method to return an instance of that formatter. | |
getHelpUrls () | |
shouldCheckMaxlag () | |
Indicates if this module needs maxlag to be checked. | |
isReadMode () | |
Indicates whether this module requires read rights. | |
isWriteMode () | |
Indicates whether this module requires write mode. | |
mustBePosted () | |
Indicates whether this module must be called with a POST request. | |
needsToken () | |
Returns the token type this module requires in order to execute. | |
getDescription () | |
Returns the description string for this module. | |
getExamples () | |
Returns usage examples for this module. | |
getAllowedParams () | |
Returns an array of allowed parameters (parameter name) => (default value) or (parameter name) => (array with PARAM_* constants as keys) Don't call this function directly: use getFinalParams() to allow hooks to modify parameters as needed. | |
getParamDescription () | |
Returns an array of parameter descriptions. | |
getWebUITokenSalt (array $params) | |
Fetch the salt used in the Web UI corresponding to this module. | |
Data access methods | |
getModuleName () | |
Get the name of the module being executed by this instance. | |
getModulePrefix () | |
Get parameter prefix (usually two letters or an empty string). | |
getMain () | |
Get the main module. | |
isMain () | |
Returns true if this module is the main module ($this === $this->mMainModule), false otherwise. | |
getResult () | |
Get the result object. | |
getResultData () | |
Get the result data array (read-only) | |
getFinalDescription () | |
Get final module description, after hooks have had a chance to tweak it as needed. | |
getFinalParams ($flags=0) | |
Get final list of parameters, after hooks have had a chance to tweak it as needed. | |
getFinalParamDescription () | |
Get final parameter descriptions, after hooks have had a chance to tweak it as needed. | |
getDB () | |
Gets a default slave database connection object. | |
Parameter handling | |
encodeParamName ($paramName) | |
This method mangles parameter name based on the prefix supplied to the constructor. | |
extractRequestParams ($parseLimit=true) | |
Using getAllowedParams(), this function makes an array of the values provided by the user, with key being the name of the variable, and value - validated value from user or default. | |
requireOnlyOneParameter ($params, $required) | |
Die if none or more than one of a certain set of parameters is set and not false. | |
requireMaxOneParameter ($params, $required) | |
Die if more than one of a certain set of parameters is set and not false. | |
requireAtLeastOneParameter ($params, $required) | |
Die if none of a certain set of parameters is set and not false. | |
getTitleOrPageId ($params, $load=false) | |
Get a WikiPage object from a title or pageid param, if possible. | |
validateToken ($token, array $params) | |
Validate the supplied token. | |
getParameter ($paramName, $parseLimit=true) | |
Get a value for the given parameter. | |
getWatchlistValue ($watchlist, $titleObj, $userOption=null) | |
Return true if we're to watch the page, false if not, null if no change. | |
getParameterFromSettings ($paramName, $paramSettings, $parseLimit) | |
Using the settings determine the value for the given parameter. | |
parseMultiValue ($valueName, $value, $allowMultiple, $allowedValues) | |
Return an array of values that were given in a 'a|b|c' notation, after it optionally validates them against the list allowed values. | |
validateLimit ($paramName, &$value, $min, $max, $botMax=null, $enforceLimits=false) | |
Validate the value against the minimum and user/bot maximum limits. | |
validateTimestamp ($value, $encParamName) | |
Validate and normalize of parameters of type 'timestamp'. | |
parameterNotEmpty ($x) | |
Callback function used in requireOnlyOneParameter to check whether required parameters are set. | |
validateUser ($value, $encParamName) | |
Validate and normalize of parameters of type 'user'. | |
Utility methods | |
getWatchlistUser ($params) | |
Gets the user for whom to get the watchlist. | |
setWatch ($watch, $titleObj, $userOption=null) | |
Set a watch (or unwatch) based the based on a watchlist parameter. | |
static | truncateArray (&$arr, $limit) |
Truncate an array to a certain length. | |
Warning and error reporting | |
static | $messageMap |
Array that maps message keys to error messages. | |
setWarning ($warning) | |
Set warning section for this module. | |
dieUsage ($description, $errorCode, $httpRespCode=0, $extradata=null) | |
Throw a UsageException, which will (if uncaught) call the main module's error handler and die with an error message. | |
getErrorFromStatus ($status) | |
Get error (as code, string) from a Status object. | |
dieStatus ($status) | |
Throw a UsageException based on the errors in the Status object. | |
dieReadOnly () | |
Helper function for readonly errors. | |
dieUsageMsg ($error) | |
Output the error message related to a certain array. | |
dieUsageMsgOrDebug ($error) | |
Will only set a warning instead of failing if the global $wgDebugAPI is set to true. | |
parseMsg ($error) | |
Return the error message related to a certain array. | |
dieContinueUsageIf ($condition) | |
Die with the $prefix. | |
warnOrDie ($msg, $enforceLimits=false) | |
Adds a warning to the output, else dies. | |
static | dieDebug ($method, $message) |
Internal code errors should be reported with this method. | |
Help message generation | |
makeHelpMsg () | |
Generates help message for this module, or false if there is no description. | |
makeHelpMsgParameters () | |
Generates the parameter descriptions for this module, to be displayed in the module's help. | |
makeHelpArrayToString ($prefix, $title, $input) | |
indentExampleText ($item) | |
Profiling | |
$mModuleTime = 0 | |
Profiling: total module execution time. | |
$mDBTime = 0 | |
Profiling: total module execution time. | |
$mTimeIn = 0 | |
Profiling: total module execution time. | |
$mDBTimeIn = 0 | |
Profiling: database execution time. | |
getModuleProfileName ($db=false) | |
Get the name of the module as shown in the profiler log. | |
profileIn () | |
Start module profiling. | |
profileOut () | |
End module profiling. | |
safeProfileOut () | |
When modules crash, sometimes it is needed to do a profileOut() regardless of the profiling state the module was in. | |
getProfileTime () | |
Total time the module was executed. | |
profileDBIn () | |
Start module profiling. | |
profileDBOut () | |
End database profiling. | |
getProfileDBTime () | |
Total time the module used the database. | |
logFeatureUsage ($feature) | |
Write logging information for API features to a debug log, for usage analysis. | |
Deprecated | |
const | PROP_ROOT = 'ROOT' |
const | PROP_LIST = 'LIST' |
const | PROP_TYPE = 0 |
const | PROP_NULLABLE = 1 |
getVersion () | |
Formerly returned a string that identifies the version of the extending class. | |
getFinalResultProperties () | |
getRequireOnlyOneParameterErrorMessages ($params) | |
getRequireMaxOneParameterErrorMessages ($params) | |
getRequireAtLeastOneParameterErrorMessages ($params) | |
getTitleOrPageIdErrorMessage () | |
getPossibleErrors () | |
This formerly attempted to return a list of all possible errors returned by the module. | |
getFinalPossibleErrors () | |
parseErrors ($errors) | |
getResultProperties () | |
Formerly used to fetch a list of possible properites in the result, somehow organized with respect to the prop parameter that causes them to be returned. | |
static | addTokenProperties (&$props, $tokenFunctions) |
This abstract class implements many basic API functions, and is the base of all API classes.
The class functions are divided into several areas of functionality:
Module parameters: Derived classes can define getAllowedParams() to specify which parameters to expect, how to parse and validate them.
Profiling: various methods to allow keeping tabs on various tasks and their time costs
Self-documentation: code to allow the API to document its own state
Definition at line 42 of file ApiBase.php.
ApiBase::__construct | ( | ApiMain $ | mainModule, |
$ | moduleName, | ||
$ | modulePrefix = '' |
||
) |
ApiMain | $mainModule | |
string | $moduleName | Name of this module |
string | $modulePrefix | Prefix to use for parameter names |
Definition at line 90 of file ApiBase.php.
static ApiBase::addTokenProperties | ( | &$ | props, |
$ | tokenFunctions | ||
) | [static, protected] |
Definition at line 2287 of file ApiBase.php.
ApiBase::dieContinueUsageIf | ( | $ | condition | ) | [protected] |
Die with the $prefix.
'badcontinue' error. This call is common enough to make it into the base method.
bool | $condition | Will only die if this value is true |
Definition at line 1767 of file ApiBase.php.
Referenced by ApiResult\beginContinuation(), ApiQueryLangLinks\execute(), ApiQueryDeletedrevs\execute(), ApiQueryIWLinks\execute(), ApiQueryFilearchive\execute(), ApiQueryBlocks\execute(), ApiQueryLogEvents\execute(), ApiQueryPagePropNames\execute(), ApiQueryImageInfo\execute(), ApiQueryContributors\execute(), ApiQueryRevisions\execute(), ApiQueryInfo\execute(), ApiQueryContributions\prepareQuery(), ApiQueryIWBacklinks\run(), ApiQueryImages\run(), ApiQueryLangBacklinks\run(), ApiQueryProtectedTitles\run(), ApiQueryWatchlistRaw\run(), ApiQueryCategories\run(), ApiQueryDuplicateFiles\run(), ApiQueryCategoryMembers\run(), ApiQueryAllCategories\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQueryAllPages\run(), ApiQueryLinks\run(), ApiQueryAllImages\run(), ApiQueryBacklinksprop\run(), ApiQueryAllLinks\run(), and ApiQueryRecentChanges\run().
static ApiBase::dieDebug | ( | $ | method, |
$ | message | ||
) | [static, protected] |
Internal code errors should be reported with this method.
string | $method | Method or function name |
string | $message | Error message |
MWException |
Definition at line 1808 of file ApiBase.php.
Referenced by ApiQueryLinks\__construct(), ApiQueryAllLinks\__construct(), ApiQueryBase\addJoinConds(), ApiQueryBase\addTables(), ApiQuerySiteinfo\appendInterwikiMap(), ApiQuerySiteinfo\execute(), ApiQueryAllUsers\execute(), ApiLogin\execute(), ApiFormatRaw\execute(), ApiFormatFeedWrapper\execute(), ApiQueryRevisions\execute(), ApiResult\execute(), ApiFormatRaw\getMimeType(), ApiFormatXml\recXmlPrint(), ApiQueryWatchlist\run(), ApiQueryRecentChanges\run(), ApiResult\setContent(), ApiResult\setElement(), ApiQueryGeneratorBase\setGeneratorMode(), ApiResult\setIndexedTagName(), ApiResult\setSubelements(), and ApiFormatWddx\slowWddxPrinter().
Helper function for readonly errors.
Definition at line 1723 of file ApiBase.php.
Referenced by ApiEditPage\execute().
ApiBase::dieStatus | ( | $ | status | ) |
Throw a UsageException based on the errors in the Status object.
Status | $status |
MWException |
Definition at line 1215 of file ApiBase.php.
Referenced by ApiCreateAccount\execute(), ApiProtect\execute(), ApiImport\execute(), ApiDelete\execute(), ApiUserrights\getUrUser(), and ApiWatch\watchTitle().
ApiBase::dieUsage | ( | $ | description, |
$ | errorCode, | ||
$ | httpRespCode = 0 , |
||
$ | extradata = null |
||
) |
Throw a UsageException, which will (if uncaught) call the main module's error handler and die with an error message.
string | $description | One-line human-readable description of the error condition, e.g., "The API requires a valid action parameter" |
string | $errorCode | Brief, arbitrary, stable string to allow easy automated identification of the error, e.g., 'unknown_action' |
int | $httpRespCode | HTTP response code |
array | $extradata | Data to add to the "<error>" element; array in ApiResult format |
UsageException |
Definition at line 1159 of file ApiBase.php.
Referenced by ApiQuerySiteinfo\appendDbReplLagInfo(), ApiQueryImageInfo\checkParameterNormalise(), ApiComparePages\execute(), ApiCreateAccount\execute(), ApiQueryStashImageInfo\execute(), ApiRevisionDelete\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiWatch\execute(), ApiHelp\execute(), ApiSetNotificationTimestamp\execute(), ApiPatrol\execute(), ApiOptions\execute(), ApiQueryDeletedrevs\execute(), ApiQueryAllMessages\execute(), ApiDisabled\execute(), ApiQueryFilearchive\execute(), ApiFeedContributions\execute(), ApiQueryBlocks\execute(), ApiFeedRecentChanges\execute(), ApiQueryLogEvents\execute(), ApiQueryContributions\execute(), ApiQueryAllUsers\execute(), ApiFeedWatchlist\execute(), ApiQueryRevisions\execute(), ApiQueryAllPages\executeGenerator(), ApiQueryAllImages\executeGenerator(), ApiQueryRevisions\extractRowInfo(), ApiQueryImageInfo\mergeThumbParams(), ApiQueryContributions\prepareQuery(), ApiQueryBase\prepareUrlQuerySearchString(), ApiQueryContributions\prepareUsername(), ApiQueryBlocks\prepareUsername(), ApiComparePages\revisionOrTitleOrId(), ApiQueryCategoryMembers\run(), ApiQueryWatchlist\run(), ApiQuerySearch\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryAllLinks\run(), and ApiQueryRecentChanges\run().
ApiBase::dieUsageMsg | ( | $ | error | ) |
Output the error message related to a certain array.
array | string | $error | Element of a getUserPermissionsErrors()-style array |
Definition at line 1733 of file ApiBase.php.
Referenced by ApiCreateAccount\execute(), ApiProtect\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiEmailUser\execute(), ApiImport\execute(), ApiRevisionDelete\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiWatch\execute(), ApiPatrol\execute(), ApiExpandTemplates\execute(), ApiOptions\execute(), ApiUnblock\execute(), ApiQueryLangLinks\execute(), ApiQueryAllMessages\execute(), ApiQueryIWLinks\execute(), ApiRollback\execute(), ApiDelete\execute(), ApiBlock\execute(), ApiQueryBlocks\execute(), ApiQueryRevisions\execute(), ApiFeedRecentChanges\getFeedObject(), ApiQueryBase\keyToTitle(), ApiQueryContributions\prepareQuery(), ApiComparePages\revisionOrTitleOrId(), ApiQueryIWBacklinks\run(), ApiQueryLangBacklinks\run(), ApiQueryWatchlistRaw\run(), ApiQueryCategories\run(), ApiQueryWatchlist\run(), ApiQueryQueryPage\run(), ApiQueryBacklinksprop\run(), ApiQueryRecentChanges\run(), ApiQueryBase\titlePartToKey(), and ApiQueryBase\titleToKey().
ApiBase::dieUsageMsgOrDebug | ( | $ | error | ) |
Will only set a warning instead of failing if the global $wgDebugAPI is set to true.
Otherwise behaves exactly as dieUsageMsg().
array | string | $error | Element of a getUserPermissionsErrors()-style array |
Definition at line 1749 of file ApiBase.php.
ApiBase::encodeParamName | ( | $ | paramName | ) |
This method mangles parameter name based on the prefix supplied to the constructor.
Override this method to change parameter name during runtime
string | $paramName | Parameter name |
Reimplemented in ApiQueryGeneratorBase.
Definition at line 417 of file ApiBase.php.
Referenced by ApiQueryLogEvents\execute(), ApiResult\setContinueParam(), and ApiResult\setGeneratorContinueParam().
ApiBase::execute | ( | ) | [abstract] |
Evaluates the parameters, performs the requested query, and sets up the result.
Concrete implementations of ApiBase must override this method to provide whatever functionality their module offers. Implementations must not produce any output on their own and are not expected to handle any errors.
The execute() method will be invoked directly by ApiMain immediately before the result of the module is output. Aside from the constructor, implementations should assume that no other methods will be called externally on the module before the result is processed.
The result data should be stored in the ApiResult object available through getResult().
Reimplemented in ApiResult, ApiMain, ApiQueryInfo, ApiQuery, ApiQueryRecentChanges, ApiPageSet, ApiQueryAllLinks, ApiQueryBacklinks, ApiQueryUsers, ApiQueryRevisions, ApiQueryBacklinksprop, ApiFormatFeedWrapper, ApiQueryORM, ApiQueryLinks, ApiFormatJson, ApiFormatRaw, ApiQueryAllImages, ApiFeedWatchlist, ApiImageRotate, ApiFormatXml, ApiLogin, ApiOpenSearch, ApiQueryAllUsers, ApiQueryContributors, ApiQueryQueryPage, ApiQueryImageInfo, ApiQuerySearch, ApiQueryTags, ApiQueryFileRepoInfo, ApiQueryLogEvents, ApiQueryPagePropNames, ApiQueryContributions, ApiFeedRecentChanges, ApiQueryBlocks, ApiQueryUserInfo, ApiBlock, ApiDelete, ApiFeedContributions, ApiFormatDbg, ApiFormatDump, ApiFormatTxt, ApiParamInfo, ApiQueryFilearchive, ApiQueryPageProps, ApiQueryRandom, ApiRollback, ApiDisabled, ApiQueryAllCategories, ApiQueryCategoryInfo, ApiQueryDisabled, ApiQueryImages, ApiQueryIWLinks, ApiQueryPagesWithProp, ApiQueryWatchlist, ApiQueryWatchlistRaw, ApiFormatWddx, ApiFormatYaml, ApiPurge, ApiQueryAllMessages, ApiQueryAllPages, ApiQueryCategories, ApiQueryCategoryMembers, ApiQueryDeletedrevs, ApiQueryDuplicateFiles, ApiQueryExternalLinks, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryLangLinks, ApiQueryProtectedTitles, ApiQuerySiteinfo, ApiUnblock, ApiFileRevert, ApiFormatNone, ApiFormatPhp, ApiOptions, ApiExpandTemplates, ApiHelp, ApiParse, ApiPatrol, ApiQueryExtLinksUsage, ApiQueryTokens, ApiSetNotificationTimestamp, ApiEditPage, ApiLogout, ApiUpload, ApiUserrights, ApiWatch, ApiImport, ApiQueryStashImageInfo, ApiRevisionDelete, ApiRsd, ApiEmailUser, ApiMove, ApiTokens, ApiUndelete, ApiClearHasMsg, ApiCreateAccount, ApiProtect, ApiQueryPrefixSearch, ApiComparePages, MockApi, and MockApiQueryBase.
ApiBase::extractRequestParams | ( | $ | parseLimit = true | ) |
Using getAllowedParams(), this function makes an array of the values provided by the user, with key being the name of the variable, and value - validated value from user or default.
limits will not be parsed if $parseLimit is set to false; use this when the max limit is not definitive yet, e.g. when getting revisions.
bool | $parseLimit | True by default |
Definition at line 430 of file ApiBase.php.
Referenced by ApiQuerySiteinfo\appendInterwikiMap(), ApiQuerySiteinfo\appendLanguages(), ApiComparePages\execute(), ApiCreateAccount\execute(), ApiProtect\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiTokens\execute(), ApiEmailUser\execute(), ApiImport\execute(), ApiQueryStashImageInfo\execute(), ApiRevisionDelete\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiUserrights\execute(), ApiWatch\execute(), ApiPatrol\execute(), ApiQueryTokens\execute(), ApiSetNotificationTimestamp\execute(), ApiExpandTemplates\execute(), ApiHelp\execute(), ApiOptions\execute(), ApiQuerySiteinfo\execute(), ApiQueryDeletedrevs\execute(), ApiUnblock\execute(), ApiQueryExternalLinks\execute(), ApiPurge\execute(), ApiQueryLangLinks\execute(), ApiQueryAllMessages\execute(), ApiQueryCategoryInfo\execute(), ApiQueryIWLinks\execute(), ApiRollback\execute(), ApiQueryFilearchive\execute(), ApiQueryPageProps\execute(), ApiFeedContributions\execute(), ApiDelete\execute(), ApiParamInfo\execute(), ApiBlock\execute(), ApiQueryBlocks\execute(), ApiQueryUserInfo\execute(), ApiFeedRecentChanges\execute(), ApiQueryContributions\execute(), ApiQueryFileRepoInfo\execute(), ApiQueryLogEvents\execute(), ApiQueryPagePropNames\execute(), ApiQueryTags\execute(), ApiQueryImageInfo\execute(), ApiQueryContributors\execute(), ApiOpenSearch\execute(), ApiQueryAllUsers\execute(), ApiLogin\execute(), ApiFormatXml\execute(), ApiImageRotate\execute(), ApiFeedWatchlist\execute(), ApiFormatJson\execute(), ApiQueryRevisions\execute(), ApiQueryUsers\execute(), ApiQueryInfo\execute(), ApiOpenSearch\getCustomPrinter(), ApiFormatJson\getMimeType(), ApiQueryORM\getParams(), ApiQueryPrefixSearch\run(), ApiQueryImages\run(), ApiQueryLangBacklinks\run(), ApiQueryIWBacklinks\run(), ApiQueryProtectedTitles\run(), ApiQueryWatchlistRaw\run(), ApiQueryExtLinksUsage\run(), ApiQueryCategories\run(), ApiQueryDuplicateFiles\run(), ApiQueryAllCategories\run(), ApiQueryCategoryMembers\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQuerySearch\run(), ApiQueryQueryPage\run(), ApiQueryAllPages\run(), ApiQueryLinks\run(), ApiQueryAllImages\run(), ApiQueryBacklinksprop\run(), ApiQueryRandom\run(), ApiQueryAllLinks\run(), and ApiQueryRecentChanges\run().
ApiBase::getAllowedParams | ( | ) | [protected] |
Returns an array of allowed parameters (parameter name) => (default value) or (parameter name) => (array with PARAM_* constants as keys) Don't call this function directly: use getFinalParams() to allow hooks to modify parameters as needed.
Some derived classes may choose to handle an integer $flags parameter in the overriding methods. Callers of this method can pass zero or more OR-ed flags like GET_VALUES_FOR_HELP.
Reimplemented in ApiMain, ApiQueryInfo, ApiQuerySiteinfo, ApiQueryRevisions, ApiUpload, ApiParse, ApiQueryImageInfo, ApiQueryRecentChanges, ApiEditPage, ApiQueryContributions, ApiQueryBacklinks, ApiQueryWatchlist, ApiQueryDeletedrevs, ApiQueryAllUsers, ApiQueryBacklinksprop, ApiQueryUsers, ApiQueryAllImages, ApiQueryCategoryMembers, ApiQueryBlocks, ApiParamInfo, ApiQueryAllLinks, ApiQuerySearch, ApiQueryFilearchive, ApiFormatXml, ApiQueryORM, ApiQueryUserInfo, ApiQueryAllPages, ApiQueryContributors, ApiQueryAllMessages, ApiMove, ApiQueryLinks, ApiDelete, ApiCreateAccount, ApiQueryCategories, ApiLogin, ApiQueryProtectedTitles, ApiRevisionDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiFeedContributions, ApiQueryDuplicateFiles, ApiQueryAllCategories, ApiQueryRandom, ApiBlock, ApiQueryIWLinks, ApiQueryExtLinksUsage, ApiProtect, ApiQueryQueryPage, ApiQueryImages, ApiQueryLangLinks, ApiExpandTemplates, ApiQueryTags, ApiHelp, ApiOptions, ApiQueryWatchlistRaw, ApiQueryPagesWithProp, ApiQueryPageProps, ApiFileRevert, ApiFeedRecentChanges, ApiComparePages, ApiQueryExternalLinks, ApiQueryCategoryInfo, ApiImport, ApiRollback, ApiUndelete, ApiEmailUser, ApiUserrights, ApiUnblock, ApiQueryPagePropNames, ApiQueryPrefixSearch, ApiQueryStashImageInfo, ApiTokens, ApiPatrol, ApiFormatJson, ApiQueryTokens, ApiOpenSearch, ApiQueryFileRepoInfo, ApiRsd, ApiLogout, ApiDisabled, ApiQueryDisabled, and MockApi.
Definition at line 179 of file ApiBase.php.
If the module may only be used with a certain format module, it should override this method to return an instance of that formatter.
A value of null means the default format will be used.
Reimplemented in ApiQuery, ApiRsd, ApiFeedWatchlist, ApiFeedContributions, ApiOpenSearch, and ApiFeedRecentChanges.
Definition at line 139 of file ApiBase.php.
ApiBase::getDB | ( | ) | [protected] |
Gets a default slave database connection object.
Reimplemented in ApiPageSet, ApiQueryBase, and ApiQueryAllImages.
Definition at line 330 of file ApiBase.php.
Referenced by ApiProtect\execute(), and ApiBlock\execute().
ApiBase::getDescription | ( | ) | [protected] |
Returns the description string for this module.
Reimplemented in ApiMain, ApiQuerySiteinfo, ApiQueryInfo, ApiQueryRevisions, ApiParse, ApiQueryImageInfo, ApiUpload, ApiQueryRecentChanges, ApiQuery, ApiQueryLogEvents, ApiQueryWatchlist, ApiQueryContributions, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiEditPage, ApiQueryBacklinksprop, ApiQueryAllUsers, ApiQueryCategoryMembers, ApiQueryAllImages, ApiQueryBlocks, ApiQuerySearch, ApiQueryUsers, ApiFormatBase, ApiQueryAllLinks, ApiQueryAllPages, ApiQueryFilearchive, ApiParamInfo, ApiQueryUserInfo, ApiQueryContributors, ApiQueryAllMessages, ApiFeedWatchlist, ApiFormatXml, ApiQueryProtectedTitles, ApiMove, ApiQueryExtLinksUsage, ApiSetNotificationTimestamp, ApiQueryCategories, ApiDelete, ApiQueryLinks, ApiRevisionDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryAllCategories, ApiFeedContributions, ApiImageRotate, ApiProtect, ApiWatch, ApiFeedRecentChanges, ApiLogin, ApiQueryIWLinks, ApiQueryLangLinks, ApiQueryWatchlistRaw, ApiQueryDuplicateFiles, ApiBlock, ApiExpandTemplates, ApiQueryPagesWithProp, ApiQueryRandom, ApiQueryImages, ApiQueryTags, ApiOptions, ApiCreateAccount, ApiQueryQueryPage, ApiHelp, ApiPurge, ApiQueryExternalLinks, ApiFileRevert, ApiQueryPageProps, ApiRollback, ApiComparePages, ApiUndelete, ApiImport, ApiQueryStashImageInfo, ApiUserrights, ApiQueryCategoryInfo, ApiEmailUser, ApiFormatWddx, ApiQueryPrefixSearch, ApiUnblock, ApiQueryFileRepoInfo, ApiOpenSearch, ApiQueryPagePropNames, ApiPatrol, ApiTokens, ApiFormatJson, ApiQueryTokens, ApiRsd, ApiLogout, ApiDisabled, ApiQueryDisabled, ApiFormatDump, ApiFormatDbg, ApiFormatTxt, ApiClearHasMsg, ApiFormatYaml, ApiFormatPhp, and ApiFormatNone.
Definition at line 147 of file ApiBase.php.
ApiBase::getErrorFromStatus | ( | $ | status | ) |
Get error (as code, string) from a Status object.
Status | $status |
Definition at line 1176 of file ApiBase.php.
Referenced by ApiWatch\watchTitle().
ApiBase::getExamples | ( | ) | [protected] |
Returns usage examples for this module.
Return false if no examples are available.
Reimplemented in ApiQuerySiteinfo, ApiQueryInfo, ApiQueryRevisions, ApiParse, ApiQueryImageInfo, ApiUpload, ApiQueryRecentChanges, ApiQuery, ApiEditPage, ApiQueryLogEvents, ApiQueryWatchlist, ApiQueryContributions, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryBacklinksprop, ApiQueryAllUsers, ApiQueryCategoryMembers, ApiQueryAllImages, ApiQueryBlocks, ApiQuerySearch, ApiQueryUsers, ApiQueryAllLinks, ApiQueryAllPages, ApiFormatBase, ApiQueryFilearchive, ApiParamInfo, ApiQueryUserInfo, ApiQueryContributors, ApiQueryAllMessages, ApiFeedWatchlist, ApiMove, ApiQueryProtectedTitles, ApiSetNotificationTimestamp, ApiQueryExtLinksUsage, ApiQueryCategories, ApiDelete, ApiQueryLinks, ApiCreateAccount, ApiRevisionDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryAllCategories, ApiFeedContributions, ApiImageRotate, ApiRollback, ApiProtect, ApiLogin, ApiWatch, ApiFeedRecentChanges, ApiQueryIWLinks, ApiQueryLangLinks, ApiBlock, ApiQueryWatchlistRaw, ApiQueryDuplicateFiles, ApiExpandTemplates, ApiOptions, ApiQueryRandom, ApiQueryPagesWithProp, ApiQueryImages, ApiQueryTags, ApiQueryQueryPage, ApiPurge, ApiHelp, ApiFileRevert, ApiUndelete, ApiQueryExternalLinks, ApiComparePages, ApiQueryPageProps, ApiImport, ApiUserrights, ApiQueryStashImageInfo, ApiEmailUser, ApiQueryCategoryInfo, ApiUnblock, ApiQueryPrefixSearch, ApiQueryFileRepoInfo, ApiOpenSearch, ApiQueryPagePropNames, ApiPatrol, ApiTokens, ApiQueryTokens, ApiRsd, ApiLogout, ApiDisabled, ApiQueryDisabled, and ApiClearHasMsg.
Definition at line 155 of file ApiBase.php.
Get final module description, after hooks have had a chance to tweak it as needed.
Definition at line 346 of file ApiBase.php.
Get final parameter descriptions, after hooks have had a chance to tweak it as needed.
Definition at line 382 of file ApiBase.php.
ApiBase::getFinalParams | ( | $ | flags = 0 | ) |
Get final list of parameters, after hooks have had a chance to tweak it as needed.
int | $flags | Zero or more flags like GET_VALUES_FOR_HELP |
Definition at line 361 of file ApiBase.php.
Definition at line 2351 of file ApiBase.php.
Definition at line 2278 of file ApiBase.php.
Reimplemented in ApiQuerySiteinfo, ApiQueryInfo, ApiQueryRevisions, ApiParse, ApiQueryImageInfo, ApiUpload, ApiQueryRecentChanges, ApiQuery, ApiEditPage, ApiQueryLogEvents, ApiQueryWatchlist, ApiQueryContributions, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryBacklinksprop, ApiQueryAllUsers, ApiQueryAllImages, ApiQueryCategoryMembers, ApiQueryBlocks, ApiQuerySearch, ApiQueryAllLinks, ApiQueryUsers, ApiQueryAllPages, ApiFormatBase, ApiQueryFilearchive, ApiParamInfo, ApiQueryUserInfo, ApiQueryContributors, ApiQueryAllMessages, ApiFeedWatchlist, ApiSetNotificationTimestamp, ApiMove, ApiQueryProtectedTitles, ApiQueryExtLinksUsage, ApiQueryCategories, ApiDelete, ApiQueryLinks, ApiRevisionDelete, ApiCreateAccount, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryAllCategories, ApiRollback, ApiProtect, ApiLogin, ApiWatch, ApiQueryIWLinks, ApiQueryLangLinks, ApiBlock, ApiQueryWatchlistRaw, ApiQueryDuplicateFiles, ApiExpandTemplates, ApiQueryRandom, ApiQueryPagesWithProp, ApiQueryImages, ApiOptions, ApiQueryTags, ApiQueryQueryPage, ApiHelp, ApiPurge, ApiUndelete, ApiQueryExternalLinks, ApiQueryPageProps, ApiImport, ApiUserrights, ApiEmailUser, ApiQueryCategoryInfo, ApiUnblock, ApiQueryPrefixSearch, ApiOpenSearch, ApiQueryPagePropNames, ApiPatrol, ApiLogout, and ApiClearHasMsg.
Definition at line 163 of file ApiBase.php.
ApiBase::getMain | ( | ) |
Get the main module.
Definition at line 291 of file ApiBase.php.
Referenced by ApiParamInfo\__construct(), ApiQueryBase\__construct(), ApiResult\endContinuation(), ApiCreateAccount\execute(), ApiUpload\execute(), ApiExpandTemplates\execute(), ApiHelp\execute(), ApiQueryTokens\execute(), ApiQueryDeletedrevs\execute(), ApiParamInfo\execute(), ApiFeedRecentChanges\execute(), ApiOpenSearch\execute(), ApiLogin\execute(), ApiFeedWatchlist\execute(), ApiQueryRevisions\execute(), ApiParamInfo\getAllowedParams(), ApiQueryUserInfo\getCurrentUserInfo(), ApiFeedRecentChanges\getCustomPrinter(), ApiOpenSearch\getCustomPrinter(), ApiFeedContributions\getCustomPrinter(), ApiFeedWatchlist\getCustomPrinter(), ApiRsd\getCustomPrinter(), ApiQueryRevisions\getTokenFunctions(), ApiQueryRecentChanges\getTokenFunctions(), ApiQueryUsers\getTokenFunctions(), ApiQueryInfo\getTokenFunctions(), ApiTokens\getTokenTypes(), ApiFeedWatchlist\getWatchlistModule(), and ApiFormatBase\initPrinter().
Get the module manager, or null if this module has no sub-modules.
Reimplemented in ApiMain, and ApiQuery.
Definition at line 129 of file ApiBase.php.
Get the name of the module being executed by this instance.
Definition at line 275 of file ApiBase.php.
Referenced by ApiQueryBase\addPageSubItem(), ApiQueryBase\addPageSubItems(), ApiQueryTags\doTag(), ApiComparePages\execute(), ApiProtect\execute(), ApiClearHasMsg\execute(), ApiUndelete\execute(), ApiTokens\execute(), ApiEmailUser\execute(), ApiMove\execute(), ApiRevisionDelete\execute(), ApiImport\execute(), ApiQueryStashImageInfo\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiUserrights\execute(), ApiWatch\execute(), ApiPatrol\execute(), ApiSetNotificationTimestamp\execute(), ApiHelp\execute(), ApiExpandTemplates\execute(), ApiQueryTokens\execute(), ApiOptions\execute(), ApiQueryDeletedrevs\execute(), ApiPurge\execute(), ApiQueryAllMessages\execute(), ApiUnblock\execute(), ApiRollback\execute(), ApiQueryFilearchive\execute(), ApiDelete\execute(), ApiBlock\execute(), ApiParamInfo\execute(), ApiQueryBlocks\execute(), ApiQueryUserInfo\execute(), ApiQueryContributions\execute(), ApiQueryLogEvents\execute(), ApiQueryPagePropNames\execute(), ApiQueryTags\execute(), ApiQueryAllUsers\execute(), ApiImageRotate\execute(), ApiQueryRevisions\execute(), ApiQueryUsers\execute(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryBacklinksprop\getDescription(), ApiQueryLinks\getExamples(), ApiFormatBase\getExamples(), ApiQueryAllLinks\getExamples(), ApiQueryBacklinksprop\getExamples(), ApiQueryAllLinks\getHelpUrls(), ApiQueryBacklinksprop\getHelpUrls(), ApiQueryBacklinksprop\getParamDescription(), ApiFormatBase\markDeprecated(), ApiQueryPrefixSearch\run(), ApiQueryIWBacklinks\run(), ApiQueryProtectedTitles\run(), ApiQueryLangBacklinks\run(), ApiQueryWatchlistRaw\run(), ApiQueryExtLinksUsage\run(), ApiQueryCategoryMembers\run(), ApiQueryAllCategories\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQueryQueryPage\run(), ApiQuerySearch\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryBacklinksprop\run(), ApiQueryRandom\run(), ApiQueryAllLinks\run(), ApiQueryRecentChanges\run(), ApiQueryRandom\runQuery(), ApiResult\setContinueParam(), and ApiResult\setGeneratorContinueParam().
Get parameter prefix (usually two letters or an empty string).
Definition at line 283 of file ApiBase.php.
Referenced by ApiQueryBase\addPageSubItem(), ApiQueryBase\addPageSubItems(), ApiQueryStashImageInfo\execute(), ApiWatch\execute(), ApiQueryDeletedrevs\execute(), ApiQueryUserInfo\getCurrentUserInfo(), ApiQueryDeletedrevs\getDescription(), ApiQueryAllLinks\getExamples(), ApiQueryBacklinksprop\getHelpUrls(), ApiUnblock\getParamDescription(), ApiQueryStashImageInfo\getParamDescription(), ApiQueryExternalLinks\getParamDescription(), ApiProtect\getParamDescription(), ApiCreateAccount\getParamDescription(), ApiQueryExtLinksUsage\getParamDescription(), ApiDelete\getParamDescription(), ApiMove\getParamDescription(), ApiQueryProtectedTitles\getParamDescription(), ApiQueryAllPages\getParamDescription(), ApiQueryAllLinks\getParamDescription(), ApiQueryBlocks\getParamDescription(), ApiQueryCategoryMembers\getParamDescription(), ApiQueryAllImages\getParamDescription(), ApiQueryBacklinksprop\getParamDescription(), ApiQueryDeletedrevs\getParamDescription(), ApiQueryWatchlist\getParamDescription(), ApiQueryContributions\getParamDescription(), ApiQueryLogEvents\getParamDescription(), ApiEditPage\getParamDescription(), ApiQueryRecentChanges\getParamDescription(), ApiQueryImageInfo\getParamDescription(), ApiQueryRevisions\getParamDescription(), ApiQuerySiteinfo\getParamDescription(), ApiQueryImageInfo\getScale(), ApiQueryImageInfo\mergeThumbParams(), ApiQueryPrefixSearch\run(), ApiQueryProtectedTitles\run(), ApiQueryExtLinksUsage\run(), ApiQueryAllImages\run(), and ApiQueryAllLinks\run().
ApiBase::getModuleProfileName | ( | $ | db = false | ) |
Get the name of the module as shown in the profiler log.
DatabaseBase | bool | $db |
Definition at line 2097 of file ApiBase.php.
ApiBase::getParamDescription | ( | ) | [protected] |
Returns an array of parameter descriptions.
Don't call this function directly: use getFinalParamDescription() to allow hooks to modify descriptions as needed.
Reimplemented in ApiPageSet, ApiMain, ApiQuerySiteinfo, ApiQueryInfo, ApiQueryRevisions, ApiQueryImageInfo, ApiUpload, ApiParse, ApiQueryRecentChanges, ApiQuery, ApiEditPage, ApiQueryLogEvents, ApiQueryContributions, ApiQueryWatchlist, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryAllUsers, ApiQueryBacklinksprop, ApiQueryAllImages, ApiQueryCategoryMembers, ApiQueryBlocks, ApiQuerySearch, ApiQueryUsers, ApiQueryAllLinks, ApiQueryAllPages, ApiParamInfo, ApiQueryFilearchive, ApiQueryORM, ApiQueryUserInfo, ApiFormatXml, ApiQueryContributors, ApiFeedWatchlist, ApiQueryAllMessages, ApiSetNotificationTimestamp, ApiQueryProtectedTitles, ApiMove, ApiQueryCategories, ApiQueryLinks, ApiDelete, ApiQueryExtLinksUsage, ApiCreateAccount, ApiRevisionDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiImageRotate, ApiFeedContributions, ApiQueryAllCategories, ApiWatch, ApiLogin, ApiQueryDuplicateFiles, ApiQueryIWLinks, ApiProtect, ApiQueryLangLinks, ApiQueryWatchlistRaw, ApiFeedRecentChanges, ApiBlock, ApiQueryRandom, ApiQueryImages, ApiExpandTemplates, ApiQueryPagesWithProp, ApiQueryQueryPage, ApiQueryTags, ApiOptions, ApiHelp, ApiPurge, ApiFileRevert, ApiQueryPageProps, ApiComparePages, ApiQueryExternalLinks, ApiRollback, ApiUndelete, ApiImport, ApiQueryStashImageInfo, ApiQueryCategoryInfo, ApiUserrights, ApiEmailUser, ApiQueryPrefixSearch, ApiQueryPagePropNames, ApiUnblock, ApiOpenSearch, ApiQueryFileRepoInfo, ApiPatrol, ApiTokens, ApiFormatJson, ApiQueryTokens, ApiRsd, ApiLogout, ApiDisabled, and ApiQueryDisabled.
Definition at line 191 of file ApiBase.php.
ApiBase::getParameter | ( | $ | paramName, |
$ | parseLimit = true |
||
) | [protected] |
Get a value for the given parameter.
string | $paramName | Parameter name |
bool | $parseLimit | See extractRequestParams() |
Definition at line 454 of file ApiBase.php.
Referenced by ApiQuerySiteinfo\appendSkins(), ApiFeedRecentChanges\execute(), and ApiMain\sendCacheHeaders().
ApiBase::getParameterFromSettings | ( | $ | paramName, |
$ | paramSettings, | ||
$ | parseLimit | ||
) | [protected] |
Using the settings determine the value for the given parameter.
string | $paramName | Parameter name |
array | mixed | $paramSettings | Default value or an array of settings using PARAM_* constants. |
bool | $parseLimit | Parse limit? |
Definition at line 632 of file ApiBase.php.
This formerly attempted to return a list of all possible errors returned by the module.
However, this was impossible to maintain in many cases since errors could come from other areas of MediaWiki and in some cases from arbitrary extension hooks. Since a partial list claiming to be comprehensive is unlikely to be useful, it was removed.
Definition at line 2341 of file ApiBase.php.
Definition at line 2316 of file ApiBase.php.
ApiBase::getRequireMaxOneParameterErrorMessages | ( | $ | params | ) |
Definition at line 2306 of file ApiBase.php.
ApiBase::getRequireOnlyOneParameterErrorMessages | ( | $ | params | ) |
Definition at line 2296 of file ApiBase.php.
Get the result object.
Reimplemented in ApiMain.
Definition at line 308 of file ApiBase.php.
Referenced by ApiQueryBase\addPageSubItem(), ApiQueryBase\addPageSubItems(), ApiQueryORM\addSerializedResults(), ApiQuerySiteinfo\appendDbReplLagInfo(), ApiQuerySiteinfo\appendDefaultOptions(), ApiQuerySiteinfo\appendExtensions(), ApiQuerySiteinfo\appendExtensionTags(), ApiQuerySiteinfo\appendFileExtensions(), ApiQuerySiteinfo\appendFunctionHooks(), ApiQuerySiteinfo\appendGeneralInfo(), ApiQuerySiteinfo\appendInterwikiMap(), ApiQuerySiteinfo\appendLanguages(), ApiQuerySiteinfo\appendMagicWords(), ApiQuerySiteinfo\appendNamespaceAliases(), ApiQuerySiteinfo\appendNamespaces(), ApiQuerySiteinfo\appendProtocols(), ApiQuerySiteinfo\appendRestrictions(), ApiQuerySiteinfo\appendRightsInfo(), ApiQuerySiteinfo\appendSkins(), ApiQuerySiteinfo\appendSpecialPageAliases(), ApiQuerySiteinfo\appendStatistics(), ApiQuerySiteinfo\appendSubscribedHooks(), ApiQuerySiteinfo\appendUserGroups(), ApiQuerySiteinfo\appendVariables(), ApiComparePages\execute(), ApiCreateAccount\execute(), ApiProtect\execute(), ApiClearHasMsg\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiTokens\execute(), ApiEmailUser\execute(), ApiQueryStashImageInfo\execute(), ApiRevisionDelete\execute(), ApiRsd\execute(), ApiImport\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiUserrights\execute(), ApiWatch\execute(), ApiExpandTemplates\execute(), ApiPatrol\execute(), ApiQueryTokens\execute(), ApiHelp\execute(), ApiSetNotificationTimestamp\execute(), ApiOptions\execute(), ApiQueryDeletedrevs\execute(), ApiUnblock\execute(), ApiPurge\execute(), ApiQueryAllMessages\execute(), ApiQueryPageProps\execute(), ApiQueryFilearchive\execute(), ApiRollback\execute(), ApiBlock\execute(), ApiFeedContributions\execute(), ApiParamInfo\execute(), ApiDelete\execute(), ApiQueryBlocks\execute(), ApiFeedRecentChanges\execute(), ApiQueryUserInfo\execute(), ApiQueryPagePropNames\execute(), ApiQueryFileRepoInfo\execute(), ApiQueryContributions\execute(), ApiQueryLogEvents\execute(), ApiQueryTags\execute(), ApiQueryImageInfo\execute(), ApiOpenSearch\execute(), ApiQueryContributors\execute(), ApiQueryAllUsers\execute(), ApiLogin\execute(), ApiImageRotate\execute(), ApiFeedWatchlist\execute(), ApiQueryRevisions\execute(), ApiQueryUsers\execute(), ApiQueryInfo\execute(), ApiQueryInfo\extractPageInfo(), ApiQueryWatchlist\extractRowInfo(), ApiQueryContributions\extractRowInfo(), ApiQueryLogEvents\extractRowInfo(), ApiQueryRecentChanges\extractRowInfo(), ApiQueryRevisions\extractRowInfo(), ApiRevisionDelete\extractStatusInfo(), ApiRsd\formatRsdApiList(), ApiRevisionDelete\formatStatusMessages(), ApiQueryUserInfo\getCurrentUserInfo(), ApiQueryPrefixSearch\run(), ApiQueryProtectedTitles\run(), ApiQueryLangBacklinks\run(), ApiQueryIWBacklinks\run(), ApiQueryWatchlistRaw\run(), ApiQueryExtLinksUsage\run(), ApiQueryAllCategories\run(), ApiQueryCategoryMembers\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQuerySearch\run(), ApiQueryQueryPage\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryRandom\run(), ApiQueryAllLinks\run(), ApiQueryRecentChanges\run(), ApiQueryRandom\runQuery(), ApiQueryBase\setContinueEnumParameter(), ApiQueryGeneratorBase\setContinueEnumParameter(), ApiQueryORM\setIndexedTagNames(), and ApiUpload\transformWarnings().
Get the result data array (read-only)
Definition at line 322 of file ApiBase.php.
Referenced by ApiFormatPhp\execute(), ApiFormatWddx\execute(), ApiFormatDbg\execute(), ApiFormatTxt\execute(), ApiFormatDump\execute(), ApiFormatXml\execute(), ApiFormatRaw\execute(), ApiFormatJson\execute(), ApiFormatFeedWrapper\execute(), and ApiFormatRaw\getMimeType().
ApiBase::getResultProperties | ( | ) | [protected] |
Formerly used to fetch a list of possible properites in the result, somehow organized with respect to the prop parameter that causes them to be returned.
The specific semantics of the return value was never specified. Since this was never possible to be accurately updated, it has been removed.
Definition at line 2268 of file ApiBase.php.
ApiBase::getTitleOrPageId | ( | $ | params, |
$ | load = false |
||
) |
Get a WikiPage object from a title or pageid param, if possible.
Can die, if no param is set or if the title or page id is not valid.
array | $params | |
bool | string | $load | Whether load the object's state from the database:
|
Definition at line 553 of file ApiBase.php.
Referenced by ApiProtect\execute(), ApiEditPage\execute(), ApiDelete\execute(), and ApiQueryCategoryMembers\run().
Definition at line 2326 of file ApiBase.php.
Formerly returned a string that identifies the version of the extending class.
Typically included the class name, the svn revision, timestamp, and last author. Usually done with SVN's Id keyword
Reimplemented in MockApi, and MockApiQueryBase.
Definition at line 2253 of file ApiBase.php.
ApiBase::getWatchlistUser | ( | $ | params | ) |
Gets the user for whom to get the watchlist.
array | $params |
Definition at line 1068 of file ApiBase.php.
Referenced by ApiQueryWatchlistRaw\run(), and ApiQueryWatchlist\run().
ApiBase::getWatchlistValue | ( | $ | watchlist, |
$ | titleObj, | ||
$ | userOption = null |
||
) | [protected] |
Return true if we're to watch the page, false if not, null if no change.
string | $watchlist | Valid values: 'watch', 'unwatch', 'preferences', 'nochange' |
Title | $titleObj | The page under consideration |
string | $userOption | The user option to consider when $watchlist=preferences. If not set will use watchdefault always and watchcreations if $titleObj doesn't exist. |
Definition at line 590 of file ApiBase.php.
Referenced by ApiEditPage\execute().
ApiBase::getWebUITokenSalt | ( | array $ | params | ) | [protected] |
Fetch the salt used in the Web UI corresponding to this module.
Only override this if the Web UI uses a token with a non-constant salt.
array | $params | All supplied parameters for the module |
Reimplemented in ApiRollback, and ApiUserrights.
Definition at line 260 of file ApiBase.php.
ApiBase::indentExampleText | ( | $ | item | ) | [private] |
ApiBase::isMain | ( | ) |
Returns true if this module is the main module ($this === $this->mMainModule), false otherwise.
Definition at line 300 of file ApiBase.php.
Indicates whether this module requires read rights.
Reimplemented in ApiMain, ApiParamInfo, ApiCreateAccount, ApiLogin, ApiHelp, ApiRsd, ApiLogout, and ApiDisabled.
Definition at line 207 of file ApiBase.php.
Indicates whether this module requires write mode.
Reimplemented in ApiUpload, ApiEditPage, ApiSetNotificationTimestamp, ApiMove, ApiDelete, ApiCreateAccount, ApiImageRotate, ApiRevisionDelete, ApiWatch, ApiBlock, ApiProtect, ApiOptions, ApiPurge, ApiFileRevert, ApiImport, ApiRollback, ApiUndelete, ApiEmailUser, ApiUserrights, ApiUnblock, ApiPatrol, and ApiClearHasMsg.
Definition at line 215 of file ApiBase.php.
ApiBase::logFeatureUsage | ( | $ | feature | ) | [protected] |
Write logging information for API features to a debug log, for usage analysis.
string | $feature | Feature being used. |
Definition at line 2219 of file ApiBase.php.
Referenced by ApiProtect\execute(), ApiMove\execute(), ApiQueryStashImageInfo\execute(), ApiUpload\execute(), ApiWatch\execute(), ApiEditPage\execute(), ApiHelp\execute(), ApiExpandTemplates\execute(), ApiQueryLangLinks\execute(), ApiQueryIWLinks\execute(), ApiDelete\execute(), ApiFormatBase\markDeprecated(), ApiQueryContributions\prepareQuery(), ApiQueryCategoryMembers\run(), and ApiQuerySearch\run().
ApiBase::makeHelpArrayToString | ( | $ | prefix, |
$ | title, | ||
$ | input | ||
) | [protected] |
string | $prefix | Text to split output items |
string | $title | What is being output |
string | array | $input |
Definition at line 1901 of file ApiBase.php.
Generates help message for this module, or false if there is no description.
Reimplemented in ApiMain, and ApiQuery.
Definition at line 1823 of file ApiBase.php.
Generates the parameter descriptions for this module, to be displayed in the module's help.
Definition at line 1928 of file ApiBase.php.
Indicates whether this module must be called with a POST request.
Reimplemented in ApiUpload, ApiEditPage, ApiSetNotificationTimestamp, ApiMove, ApiDelete, ApiImageRotate, ApiCreateAccount, ApiLogin, ApiRevisionDelete, ApiWatch, ApiBlock, ApiProtect, ApiPurge, ApiOptions, ApiFileRevert, ApiImport, ApiRollback, ApiUndelete, ApiEmailUser, ApiUserrights, ApiUnblock, ApiPatrol, and ApiClearHasMsg.
Definition at line 223 of file ApiBase.php.
Returns the token type this module requires in order to execute.
Modules are strongly encouraged to use the core 'csrf' type unless they have specialized security needs. If the token type is not one of the core types, you must use the ApiQueryTokensRegisterTypes hook to register it.
Returning a non-falsey value here will cause self::getFinalParams() to return a required string 'token' parameter and self::getFinalParamDescription() to ensure there is standardized documentation for it. Also, self::mustBePosted() must return true when tokens are used.
In previous versions of MediaWiki, true was a valid return value. Returning true will generate errors indicating that the API module needs updating.
Reimplemented in ApiUpload, ApiEditPage, ApiMove, ApiDelete, ApiRevisionDelete, ApiImageRotate, ApiProtect, ApiSetNotificationTimestamp, ApiBlock, ApiOptions, ApiWatch, ApiFileRevert, ApiRollback, ApiUndelete, ApiImport, ApiUserrights, ApiEmailUser, ApiUnblock, and ApiPatrol.
Definition at line 247 of file ApiBase.php.
ApiBase::parameterNotEmpty | ( | $ | x | ) | [private] |
Callback function used in requireOnlyOneParameter to check whether required parameters are set.
object | $x | Parameter to check is not null/false |
Definition at line 538 of file ApiBase.php.
ApiBase::parseErrors | ( | $ | errors | ) |
Definition at line 2361 of file ApiBase.php.
ApiBase::parseMsg | ( | $ | error | ) |
Return the error message related to a certain array.
array | $error | Element of a getUserPermissionsErrors()-style array |
Definition at line 1780 of file ApiBase.php.
Referenced by ApiImageRotate\checkPermissions(), ApiMove\execute(), ApiPurge\execute(), and ApiMove\moveSubpages().
ApiBase::parseMultiValue | ( | $ | valueName, |
$ | value, | ||
$ | allowMultiple, | ||
$ | allowedValues | ||
) | [protected] |
Return an array of values that were given in a 'a|b|c' notation, after it optionally validates them against the list allowed values.
string | $valueName | The name of the parameter (for error reporting) |
mixed | $value | The value being parsed |
bool | $allowMultiple | Can $value contain more than one value separated by '|'? |
string[]|null | $allowedValues An array of values to check against. If null, all values are accepted. |
Definition at line 854 of file ApiBase.php.
Start module profiling.
Definition at line 2168 of file ApiBase.php.
Referenced by ApiQueryBase\checkRowCount(), and ApiQueryBase\select().
End database profiling.
Definition at line 2185 of file ApiBase.php.
Referenced by ApiQueryBase\checkRowCount(), and ApiQueryBase\select().
Start module profiling.
Definition at line 2108 of file ApiBase.php.
End module profiling.
Definition at line 2119 of file ApiBase.php.
ApiBase::requireAtLeastOneParameter | ( | $ | params, |
$ | required | ||
) |
Die if none of a certain set of parameters is set and not false.
array | $params | User provided set of parameters, as from $this->extractRequestParams() |
string | $required,... | Names of parameters of which at least one must be set |
Definition at line 516 of file ApiBase.php.
ApiBase::requireMaxOneParameter | ( | $ | params, |
$ | required | ||
) |
Die if more than one of a certain set of parameters is set and not false.
array | $params | User provided set of parameters, as from $this->extractRequestParams() |
string | $required,... | Names of parameters of which at most one must be set |
Definition at line 493 of file ApiBase.php.
Referenced by ApiExpandTemplates\execute(), ApiSetNotificationTimestamp\execute(), ApiQueryLangLinks\execute(), ApiQueryIWLinks\execute(), ApiQueryBlocks\execute(), ApiQueryLogEvents\execute(), and ApiQueryContributors\execute().
ApiBase::requireOnlyOneParameter | ( | $ | params, |
$ | required | ||
) |
Die if none or more than one of a certain set of parameters is set and not false.
array | $params | User provided set of parameters, as from $this->extractRequestParams() |
string | $required,... | Names of parameters of which exactly one must be set |
Definition at line 467 of file ApiBase.php.
Referenced by ApiMove\execute(), ApiPatrol\execute(), and ApiUserrights\getUrUser().
When modules crash, sometimes it is needed to do a profileOut() regardless of the profiling state the module was in.
This method does such cleanup.
Definition at line 2139 of file ApiBase.php.
ApiBase::setWarning | ( | $ | warning | ) |
Set warning section for this module.
Users should monitor this section to notice any changes in API. Multiple calls to this function will result in the warning messages being separated by newlines
string | $warning | Warning message |
Definition at line 1108 of file ApiBase.php.
Referenced by ApiResult\addValue(), ApiFormatXml\addXslt(), ApiTokens\execute(), ApiQueryTokens\execute(), ApiExpandTemplates\execute(), ApiOptions\execute(), ApiPurge\execute(), ApiQueryDeletedrevs\execute(), ApiQueryDisabled\execute(), ApiQueryRevisions\execute(), ApiQueryUsers\execute(), ApiQueryInfo\extractPageInfo(), ApiQueryRecentChanges\extractRowInfo(), ApiQueryRevisions\extractRowInfo(), ApiQueryUserInfo\getCurrentUserInfo(), ApiFormatBase\markDeprecated(), ApiQueryImageInfo\mergeThumbParams(), ApiQueryImages\run(), ApiQueryCategories\run(), ApiQuerySearch\run(), and ApiQueryLinks\run().
ApiBase::setWatch | ( | $ | watch, |
$ | titleObj, | ||
$ | userOption = null |
||
) | [protected] |
Set a watch (or unwatch) based the based on a watchlist parameter.
string | $watch | Valid values: 'watch', 'unwatch', 'preferences', 'nochange' |
Title | $titleObj | The article's title to change |
string | $userOption | The user option to consider when $watch=preferences |
Definition at line 1037 of file ApiBase.php.
Referenced by ApiProtect\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiRollback\execute(), and ApiDelete\execute().
Indicates if this module needs maxlag to be checked.
Reimplemented in ApiQuery, and ApiHelp.
Definition at line 199 of file ApiBase.php.
static ApiBase::truncateArray | ( | &$ | arr, |
$ | limit | ||
) | [static] |
Truncate an array to a certain length.
array | $arr | Array to truncate |
int | $limit | Maximum length |
Definition at line 1052 of file ApiBase.php.
ApiBase::validateLimit | ( | $ | paramName, |
&$ | value, | ||
$ | min, | ||
$ | max, | ||
$ | botMax = null , |
||
$ | enforceLimits = false |
||
) | [protected] |
Validate the value against the minimum and user/bot maximum limits.
Prints usage info on failure.
string | $paramName | Parameter name |
int | $value | Parameter value |
int | null | $min | Minimum value |
int | null | $max | Maximum value for users |
int | $botMax | Maximum value for sysops/bots |
bool | $enforceLimits | Whether to enforce (die) if value is outside limits |
Definition at line 918 of file ApiBase.php.
Referenced by ApiQueryDeletedrevs\execute(), and ApiQueryRevisions\execute().
ApiBase::validateTimestamp | ( | $ | value, |
$ | encParamName | ||
) | [protected] |
Validate and normalize of parameters of type 'timestamp'.
string | $value | Parameter value |
string | $encParamName | Parameter name |
Definition at line 956 of file ApiBase.php.
ApiBase::validateToken | ( | $ | token, |
array $ | params | ||
) | [final] |
Validate the supplied token.
string | $token | Supplied token |
array | $params | All supplied parameters for the module |
Definition at line 976 of file ApiBase.php.
ApiBase::validateUser | ( | $ | value, |
$ | encParamName | ||
) | [private] |
Validate and normalize of parameters of type 'user'.
string | $value | Parameter value |
string | $encParamName | Parameter name |
Definition at line 1012 of file ApiBase.php.
ApiBase::warnOrDie | ( | $ | msg, |
$ | enforceLimits = false |
||
) | [private] |
Adds a warning to the output, else dies.
string | $msg | Message to show as a warning, or error message if dying |
bool | $enforceLimits | Whether this is an enforce (die) |
Definition at line 1139 of file ApiBase.php.
ApiBase::$mDBTime = 0 |
Profiling: total module execution time.
Definition at line 2163 of file ApiBase.php.
ApiBase::$mDBTimeIn = 0 [private] |
Profiling: database execution time.
Definition at line 2163 of file ApiBase.php.
ApiBase::$messageMap [static] |
Array that maps message keys to error messages.
$1 and friends are replaced.
Definition at line 1225 of file ApiBase.php.
ApiMain ApiBase::$mMainModule [private] |
*
Definition at line 80 of file ApiBase.php.
string ApiBase::$mModuleName [private] |
*
Definition at line 81 of file ApiBase.php.
string ApiBase::$mModulePrefix |
Definition at line 81 of file ApiBase.php.
ApiBase::$mModuleTime = 0 |
Profiling: total module execution time.
Definition at line 2088 of file ApiBase.php.
ApiBase::$mParamCache = array() [private] |
Definition at line 83 of file ApiBase.php.
ApiBase::$mSlaveDB = null [private] |
Definition at line 82 of file ApiBase.php.
ApiBase::$mTimeIn = 0 [private] |
Profiling: total module execution time.
Definition at line 2088 of file ApiBase.php.
const ApiBase::GET_VALUES_FOR_HELP = 1 |
getAllowedParams() flag: When set, the result could take longer to generate, but should be more thorough.
E.g. get the list of generators for ApiSandBox extension
Definition at line 78 of file ApiBase.php.
Referenced by ApiQueryLogEvents\getAllowedParams().
const ApiBase::LIMIT_BIG1 = 500 |
Definition at line 68 of file ApiBase.php.
Referenced by ApiQueryDeletedrevs\execute(), ApiQueryRevisions\execute(), ApiQueryPagePropNames\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), and ApiQueryRevisions\getAllowedParams().
const ApiBase::LIMIT_BIG2 = 5000 |
Definition at line 69 of file ApiBase.php.
Referenced by ApiQueryDeletedrevs\execute(), ApiQueryRevisions\execute(), ApiQueryPagePropNames\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), and ApiQueryRevisions\getAllowedParams().
const ApiBase::LIMIT_SML1 = 50 |
Definition at line 70 of file ApiBase.php.
Referenced by ApiQueryDeletedrevs\execute(), ApiQueryRevisions\execute(), and ApiQuerySearch\getAllowedParams().
const ApiBase::LIMIT_SML2 = 500 |
Definition at line 71 of file ApiBase.php.
Referenced by ApiQueryDeletedrevs\execute(), ApiQueryRevisions\execute(), and ApiQuerySearch\getAllowedParams().
const ApiBase::PARAM_ALLOW_DUPLICATES = 6 |
Definition at line 58 of file ApiBase.php.
Referenced by ApiProtect\getAllowedParams(), and ApiQueryAllMessages\getAllowedParams().
const ApiBase::PARAM_DEPRECATED = 7 |
Definition at line 60 of file ApiBase.php.
Referenced by ApiQueryStashImageInfo\getAllowedParams(), ApiHelp\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiWatch\getAllowedParams(), ApiDelete\getAllowedParams(), ApiMove\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiEditPage\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiUpload\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), and ApiQueryInfo\getAllowedParams().
const ApiBase::PARAM_DFLT = 0 |
Definition at line 46 of file ApiBase.php.
Referenced by ApiQueryFileRepoInfo\getAllowedParams(), ApiOpenSearch\getAllowedParams(), ApiQueryTokens\getAllowedParams(), ApiQueryStashImageInfo\getAllowedParams(), ApiTokens\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiUserrights\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiOptions\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiFeedContributions\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiRevisionDelete\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiCreateAccount\getAllowedParams(), ApiDelete\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiMove\getAllowedParams(), ApiQueryAllMessages\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryUserInfo\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiEditPage\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiUpload\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), ApiQuerySiteinfo\getAllowedParams(), and ApiQueryInfo\getAllowedParams().
const ApiBase::PARAM_ISMULTI = 1 |
Definition at line 48 of file ApiBase.php.
Referenced by ApiQueryFileRepoInfo\getAllowedParams(), ApiOpenSearch\getAllowedParams(), ApiQueryTokens\getAllowedParams(), ApiQueryStashImageInfo\getAllowedParams(), ApiTokens\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiUserrights\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPageProps\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiOptions\getAllowedParams(), ApiHelp\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiFeedContributions\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiRevisionDelete\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryAllMessages\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryUserInfo\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQuery\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), ApiQuerySiteinfo\getAllowedParams(), and ApiQueryInfo\getAllowedParams().
const ApiBase::PARAM_MAX = 3 |
Definition at line 52 of file ApiBase.php.
Referenced by ApiOpenSearch\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), and ApiQueryRevisions\getAllowedParams().
const ApiBase::PARAM_MAX2 = 4 |
Definition at line 54 of file ApiBase.php.
Referenced by ApiOpenSearch\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), and ApiQueryRevisions\getAllowedParams().
const ApiBase::PARAM_MIN = 5 |
Definition at line 56 of file ApiBase.php.
Referenced by ApiOpenSearch\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), and ApiQueryRevisions\getAllowedParams().
const ApiBase::PARAM_RANGE_ENFORCE = 9 |
Definition at line 66 of file ApiBase.php.
const ApiBase::PARAM_REQUIRED = 8 |
Definition at line 62 of file ApiBase.php.
Referenced by ApiQueryPrefixSearch\getAllowedParams(), ApiEmailUser\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiProtect\getAllowedParams(), ApiBlock\getAllowedParams(), ApiFeedContributions\getAllowedParams(), ApiRevisionDelete\getAllowedParams(), ApiImageRotate\getAllowedParams(), ApiCreateAccount\getAllowedParams(), ApiMove\getAllowedParams(), ApiQueryORM\getAllowedParams(), and ApiQuerySearch\getAllowedParams().
const ApiBase::PARAM_TYPE = 2 |
Definition at line 50 of file ApiBase.php.
Referenced by ApiQueryFileRepoInfo\getAllowedParams(), ApiOpenSearch\getAllowedParams(), ApiQueryTokens\getAllowedParams(), ApiPatrol\getAllowedParams(), ApiTokens\getAllowedParams(), ApiQueryStashImageInfo\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiUnblock\getAllowedParams(), ApiUserrights\getAllowedParams(), ApiEmailUser\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiImport\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiComparePages\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiOptions\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiBlock\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiFeedContributions\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiWatch\getAllowedParams(), ApiRevisionDelete\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiImageRotate\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiCreateAccount\getAllowedParams(), ApiDelete\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiMove\getAllowedParams(), ApiQueryAllMessages\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiSetNotificationTimestamp\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryUserInfo\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryBacklinksprop\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiEditPage\getAllowedParams(), ApiQuery\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiUpload\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), ApiQuerySiteinfo\getAllowedParams(), and ApiQueryInfo\getAllowedParams().
const ApiBase::PROP_LIST = 'LIST' |
Definition at line 2239 of file ApiBase.php.
const ApiBase::PROP_NULLABLE = 1 |
Definition at line 2243 of file ApiBase.php.
const ApiBase::PROP_ROOT = 'ROOT' |
Definition at line 2237 of file ApiBase.php.
const ApiBase::PROP_TYPE = 0 |
Definition at line 2241 of file ApiBase.php.