MediaWiki  REL1_23
ApiBase Class Reference

This abstract class implements many basic API functions, and is the base of all API classes. More...

Inheritance diagram for ApiBase:
Collaboration diagram for ApiBase:

List of all members.

Public Member Functions

 __construct ($mainModule, $moduleName, $modulePrefix= '')
 Constructor.
 createContext ()
 Create a new RequestContext object to use e.g.
 dieReadOnly ()
 Helper function for readonly errors.
 dieStatus ($status)
 Throw a UsageException based on the errors in the Status object.
 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.
 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.
 encodeParamName ($paramName)
 This method mangles parameter name based on the prefix supplied to the constructor.
 execute ()
 Evaluates the parameters, performs the requested query, and sets up the result.
 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.
 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.
 getErrorFromStatus ($status)
 Get error (as code, string) from a Status object.
 getFinalDescription ()
 Get final module description, 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.
 getFinalParams ($flags=0)
 Get final list of parameters, after hooks have had a chance to tweak it as needed.
 getFinalPossibleErrors ()
 Get final list of possible errors, after hooks have had a chance to tweak it as needed.
 getFinalResultProperties ()
 Get final possible result properties, after hooks have had a chance to tweak it as needed.
 getHelpUrls ()
 getMain ()
 Get the main module.
 getModuleManager ()
 Get the module manager, or null if this module has no sub-modules.
 getModuleName ()
 Get the name of the module being executed by this instance.
 getModulePrefix ()
 Get parameter prefix (usually two letters or an empty string).
 getModuleProfileName ($db=false)
 Get the name of the module as shown in the profiler log.
 getPossibleErrors ()
 Returns a list of all possible errors returned by the module.
 getProfileDBTime ()
 Total time the module used the database.
 getProfileTime ()
 Total time the module was executed.
 getRequireAtLeastOneParameterErrorMessages ($params)
 Generates the possible errors requireAtLeastOneParameter() can die with.
 getRequireMaxOneParameterErrorMessages ($params)
 Generates the possible error requireMaxOneParameter() can die with.
 getRequireOnlyOneParameterErrorMessages ($params)
 Generates the possible errors requireOnlyOneParameter() can die with.
 getResult ()
 Get the result object.
 getResultData ()
 Get the result data array (read-only)
 getTitleOrPageId ($params, $load=false)
 getTitleOrPageIdErrorMessage ()
 getTokenSalt ()
 Returns the token salt if there is one, '' if the module doesn't require a salt, else false if the module doesn't need a token You have also to override needsToken() Value is passed to User::getEditToken.
 getVersion ()
 Returns a string that identifies the version of the extending class.
 getWatchlistUser ($params)
 Gets the user for whom to get the watchlist.
 isMain ()
 Returns true if this module is the main module ($this === $this->mMainModule), false otherwise.
 isReadMode ()
 Indicates whether this module requires read rights.
 isWriteMode ()
 Indicates whether this module requires write mode.
 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.
 mustBePosted ()
 Indicates whether this module must be called with a POST request.
 needsToken ()
 Returns whether this module requires a token to execute It is used to show possible errors in action=paraminfo see bug 25248.
 parseErrors ($errors)
 Parses a list of errors into a standardised format.
 parseMsg ($error)
 Return the error message related to a certain array.
 profileDBIn ()
 Start module profiling.
 profileDBOut ()
 End database profiling.
 profileIn ()
 Start module profiling.
 profileOut ()
 End module profiling.
 requireAtLeastOneParameter ($params)
 Die if none of a certain set of parameters is set and not false.
 requireMaxOneParameter ($params)
 Die if more than one of a certain set of parameters is set and not false.
 requireOnlyOneParameter ($params)
 Die if none or more than one of a certain set of parameters is set and not false.
 safeProfileOut ()
 When modules crash, sometimes it is needed to do a profileOut() regardless of the profiling state the module was in.
 setWarning ($warning)
 Set warning section for this module.
 shouldCheckMaxlag ()
 Indicates if this module needs maxlag to be checked.
 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'.

Static Public Member Functions

static debugPrint ($value, $name= 'unknown', $backtrace=false)
 Debugging function that prints a value and an optional backtrace.
static truncateArray (&$arr, $limit)
 Truncate an array to a certain length.

Public Attributes

 $mDBTime = 0
 $mModuleName
 $mModulePrefix
 $mModuleTime = 0
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
const PROP_LIST = 'LIST'
const PROP_NULLABLE = 1
const PROP_ROOT = 'ROOT'
const PROP_TYPE = 0

Static Public Attributes

static $messageMap
 Array that maps message keys to error messages.

Protected Member Functions

 dieContinueUsageIf ($condition)
 Die with the $prefix.
 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.
 getDB ()
 Gets a default slave database connection object.
 getDescription ()
 Returns the description string for this module.
 getExamples ()
 Returns usage examples for this module.
 getParamDescription ()
 Returns an array of parameter descriptions.
 getParameter ($paramName, $parseLimit=true)
 Get a value for the given parameter.
 getParameterFromSettings ($paramName, $paramSettings, $parseLimit)
 Using the settings determine the value for the given parameter.
 getResultProperties ()
 Returns possible properties in the result, grouped by the value of the prop parameter that shows them.
 getWatchlistValue ($watchlist, $titleObj, $userOption=null)
 Return true if we're to watch the page, false if not, null if no change.
 makeHelpArrayToString ($prefix, $title, $input)
 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.
 setWatch ($watch, $titleObj, $userOption=null)
 Set a watch (or unwatch) based the based on a watchlist parameter.

Static Protected Member Functions

static addTokenProperties (&$props, $tokenFunctions)
 Add token properties to the array used by getResultProperties, based on a token functions mapping.
static dieDebug ($method, $message)
 Internal code errors should be reported with this method.

Private Member Functions

 indentExampleText ($item)
 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'.
 warnOrDie ($msg, $enforceLimits=false)
 Adds a warning to the output, else dies.

Private Attributes

 $mDBTimeIn = 0
 Profiling: database execution time.
 $mMainModule
 $mParamCache = array()
 $mSlaveDB = null
 $mTimeIn = 0
 Profiling: total module execution time.

Detailed Description

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.


Constructor & Destructor Documentation

ApiBase::__construct ( mainModule,
moduleName,
modulePrefix = '' 
)

Constructor.

Parameters:
$mainModuleApiMain object
string$moduleNameName of this module
string$modulePrefixPrefix to use for parameter names

Reimplemented in ApiQueryImageInfo.

Definition at line 100 of file ApiBase.php.

References isMain(), and ContextSource\setContext().


Member Function Documentation

static ApiBase::addTokenProperties ( &$  props,
tokenFunctions 
) [static, protected]

Add token properties to the array used by getResultProperties, based on a token functions mapping.

Definition at line 647 of file ApiBase.php.

References array(), as, PROP_NULLABLE, and PROP_TYPE.

Referenced by ApiTokens\getResultProperties(), ApiQueryUsers\getResultProperties(), ApiQueryRecentChanges\getResultProperties(), ApiQueryRevisions\getResultProperties(), and ApiQueryInfo\getResultProperties().

Create a new RequestContext object to use e.g.

for calls to other parts the software. The object will have the WebRequest and the User object set to the ones used in this instance.

Deprecated:
since 1.19 use getContext to get the current context
Returns:
DerivativeContext

Definition at line 233 of file ApiBase.php.

References ContextSource\getContext(), and wfDeprecated().

static ApiBase::debugPrint ( value,
name = 'unknown',
backtrace = false 
) [static]

Debugging function that prints a value and an optional backtrace.

Parameters:
$valuemixed Value to print
string$nameDescription of the printed value
bool$backtraceIf true, print a backtrace

Definition at line 2329 of file ApiBase.php.

References $value, print, and wfBacktrace().

Helper function for readonly errors.

Definition at line 1920 of file ApiBase.php.

References array(), dieUsage(), parseMsg(), and wfReadOnlyReason().

Referenced by ApiEditPage\execute().

ApiBase::dieStatus ( status)

Throw a UsageException based on the errors in the Status object.

Since:
1.22
Parameters:
Status$statusStatus object
Exceptions:
MWException

Definition at line 1420 of file ApiBase.php.

References dieUsage(), getErrorFromStatus(), and list.

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.

Parameters:
string$descriptionOne-line human-readable description of the error condition, e.g., "The API requires a valid action parameter"
string$errorCodeBrief, arbitrary, stable string to allow easy automated identification of the error, e.g., 'unknown_action'
int$httpRespCodeHTTP response code
array$extradataData to add to the "<error>" element; array in ApiResult format
Exceptions:
UsageException

Definition at line 1364 of file ApiBase.php.

References encodeParamName(), and Profiler\instance().

Referenced by ApiQuerySiteinfo\appendDbReplLagInfo(), dieContinueUsageIf(), dieReadOnly(), dieStatus(), dieUsageMsg(), ApiComparePages\execute(), ApiCreateAccount\execute(), ApiQueryStashImageInfo\execute(), ApiRevisionDelete\execute(), ApiEditPage\execute(), ApiWatch\execute(), ApiUpload\execute(), ApiHelp\execute(), ApiPatrol\execute(), ApiSetNotificationTimestamp\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(), getParameterFromSettings(), ApiQueryImageInfo\getScale(), getTitleOrPageId(), getWatchlistUser(), ApiQueryImageInfo\mergeThumbParams(), parseMultiValue(), ApiQueryContributions\prepareQuery(), ApiQueryBase\prepareUrlQuerySearchString(), ApiQueryContributions\prepareUsername(), ApiQueryBlocks\prepareUsername(), requireAtLeastOneParameter(), requireMaxOneParameter(), requireOnlyOneParameter(), ApiComparePages\revisionOrTitleOrId(), ApiQueryCategoryMembers\run(), ApiQueryWatchlist\run(), ApiQuerySearch\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryAllLinks\run(), ApiQueryRecentChanges\run(), validateTimestamp(), validateUser(), and warnOrDie().

Will only set a warning instead of failing if the global $wgDebugAPI is set to true.

Otherwise behaves exactly as dieUsageMsg().

Parameters:
$error(array|string) Element of a getUserPermissionsErrors()-style array
Since:
1.21

Definition at line 1946 of file ApiBase.php.

References $error, array(), dieUsageMsg(), global, parseMsg(), and setWarning().

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

Parameters:
string$paramNameParameter name
Returns:
string Prefixed parameter name

Reimplemented in ApiQueryGeneratorBase.

Definition at line 675 of file ApiBase.php.

Referenced by dieUsage(), ApiQueryLogEvents\execute(), getParameterFromSettings(), makeHelpMsgParameters(), ApiQueryBase\setContinueEnumParameter(), and validateLimit().

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, ApiFormatFeedWrapper, ApiMain, ApiQueryInfo, ApiQuery, ApiPageSet, ApiQueryRecentChanges, ApiQueryAllLinks, ApiQueryBacklinks, ApiQueryRevisions, ApiQueryORM, ApiQueryUsers, ApiQueryLinks, ApiFormatJson, ApiFormatRaw, ApiFeedWatchlist, ApiQueryAllImages, ApiImageRotate, ApiFormatXml, ApiLogin, ApiOpenSearch, ApiQueryAllUsers, ApiQueryContributors, ApiQueryQueryPage, ApiQueryImageInfo, ApiQuerySearch, ApiQueryTags, ApiQueryFileRepoInfo, ApiQueryLogEvents, ApiQueryPagePropNames, ApiQueryContributions, ApiFeedRecentChanges, ApiQueryBlocks, ApiBlock, ApiDelete, ApiFeedContributions, ApiParamInfo, ApiFormatDbg, ApiFormatDump, ApiFormatTxt, ApiQueryFilearchive, ApiQueryPageProps, ApiQueryRandom, ApiQueryUserInfo, ApiRollback, ApiDisabled, ApiQueryAllCategories, ApiQueryCategoryInfo, ApiQueryDisabled, ApiQueryImages, ApiQueryIWLinks, ApiQueryPagesWithProp, ApiQueryRedirects, ApiQueryWatchlist, ApiQueryWatchlistRaw, ApiPurge, ApiQueryAllMessages, ApiQueryAllPages, ApiQueryCategories, ApiQueryCategoryMembers, ApiQueryDeletedrevs, ApiQueryDuplicateFiles, ApiQueryExternalLinks, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryLangLinks, ApiQueryProtectedTitles, ApiQuerySiteinfo, ApiUnblock, ApiFileRevert, ApiFormatNone, ApiFormatPhp, ApiFormatWddx, ApiOptions, ApiExpandTemplates, ApiHelp, ApiParse, ApiPatrol, ApiQueryExtLinksUsage, ApiSetNotificationTimestamp, ApiEditPage, ApiLogout, ApiUpload, ApiUserrights, ApiWatch, ApiImport, ApiQueryStashImageInfo, ApiRevisionDelete, ApiRsd, ApiEmailUser, ApiMove, ApiTokens, ApiUndelete, 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.

Parameters:
$parseLimitBoolean: true by default
Returns:
array

Definition at line 688 of file ApiBase.php.

References $params, array(), as, getFinalParams(), and getParameterFromSettings().

Referenced by ApiQuerySiteinfo\appendInterwikiMap(), ApiQuerySiteinfo\appendLanguages(), ApiComparePages\execute(), ApiCreateAccount\execute(), ApiProtect\execute(), ApiTokens\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiEmailUser\execute(), ApiImport\execute(), ApiQueryStashImageInfo\execute(), ApiRevisionDelete\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiUserrights\execute(), ApiWatch\execute(), ApiSetNotificationTimestamp\execute(), ApiPatrol\execute(), ApiExpandTemplates\execute(), ApiHelp\execute(), ApiOptions\execute(), ApiQuerySiteinfo\execute(), ApiQueryDeletedrevs\execute(), ApiQueryExternalLinks\execute(), ApiUnblock\execute(), ApiQueryLangLinks\execute(), ApiPurge\execute(), ApiQueryAllMessages\execute(), ApiQueryCategoryInfo\execute(), ApiQueryIWLinks\execute(), ApiQueryUserInfo\execute(), ApiRollback\execute(), ApiQueryFilearchive\execute(), ApiQueryPageProps\execute(), ApiFeedContributions\execute(), ApiDelete\execute(), ApiParamInfo\execute(), ApiBlock\execute(), ApiQueryBlocks\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(), ApiQueryUsers\execute(), ApiQueryRevisions\execute(), ApiQueryInfo\execute(), ApiOpenSearch\getCustomPrinter(), ApiFormatJson\getMimeType(), ApiQueryORM\getParams(), ApiUserrights\getUrUser(), ApiQueryPrefixSearch\run(), ApiQueryIWBacklinks\run(), ApiQueryLangBacklinks\run(), ApiQueryImages\run(), ApiQueryProtectedTitles\run(), ApiQueryRedirects\run(), ApiQueryWatchlistRaw\run(), ApiQueryExtLinksUsage\run(), ApiQueryDuplicateFiles\run(), ApiQueryCategories\run(), ApiQueryAllCategories\run(), ApiQueryCategoryMembers\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQuerySearch\run(), ApiQueryQueryPage\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryLinks\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.

Returns:
array|bool

Reimplemented in ApiMain, ApiQueryInfo, ApiQuerySiteinfo, ApiQueryRevisions, ApiUpload, ApiParse, ApiQueryRecentChanges, ApiQueryImageInfo, ApiEditPage, ApiQueryWatchlist, ApiQueryContributions, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryAllUsers, ApiParamInfo, ApiQueryAllImages, ApiQueryUsers, ApiQueryBlocks, ApiQueryCategoryMembers, ApiQueryAllLinks, ApiQuerySearch, ApiQueryFilearchive, ApiQueryORM, ApiFormatXml, ApiQueryAllPages, ApiQueryContributors, ApiQueryRedirects, ApiQueryAllMessages, ApiQueryUserInfo, ApiQueryLinks, ApiMove, ApiCreateAccount, ApiDelete, ApiQueryCategories, ApiLogin, ApiQueryProtectedTitles, ApiRevisionDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiFeedContributions, ApiQueryDuplicateFiles, ApiQueryAllCategories, ApiQueryRandom, ApiBlock, ApiQueryExtLinksUsage, ApiQueryQueryPage, ApiProtect, ApiQueryImages, ApiQueryIWLinks, ApiQueryLangLinks, ApiQueryTags, ApiHelp, ApiOptions, ApiQueryWatchlistRaw, ApiQueryPagesWithProp, ApiQueryPageProps, ApiFileRevert, ApiFeedRecentChanges, ApiComparePages, ApiQueryExternalLinks, ApiQueryCategoryInfo, ApiImport, ApiUndelete, ApiUserrights, ApiEmailUser, ApiUnblock, ApiQueryPagePropNames, ApiRollback, ApiQueryPrefixSearch, ApiExpandTemplates, ApiPatrol, ApiQueryStashImageInfo, ApiFormatJson, ApiTokens, ApiOpenSearch, ApiQueryFileRepoInfo, ApiRsd, ApiLogout, ApiDisabled, ApiQueryDisabled, and MockApi.

Definition at line 566 of file ApiBase.php.

Referenced by getFinalParams().

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.

Returns:
mixed instance of a derived class of ApiFormatBase, or null

Reimplemented in ApiQuery, ApiRsd, ApiFeedWatchlist, ApiFeedContributions, ApiOpenSearch, and ApiFeedRecentChanges.

Definition at line 279 of file ApiBase.php.

ApiBase::getDB ( ) [protected]

Gets a default slave database connection object.

Returns:
DatabaseBase

Reimplemented in ApiPageSet, ApiQueryBase, and ApiQueryAllImages.

Definition at line 2313 of file ApiBase.php.

References profileDBIn(), profileDBOut(), and wfGetDB().

Referenced by ApiProtect\execute(), and ApiBlock\execute().

ApiBase::getDescription ( ) [protected]

Returns the description string for this module.

Returns:
mixed string or array of strings

Reimplemented in ApiMain, ApiQueryInfo, ApiQueryRecentChanges, ApiQueryImageInfo, ApiQueryRevisions, ApiQuerySiteinfo, ApiParse, ApiUpload, ApiQuery, ApiQueryWatchlist, ApiQueryContributions, ApiQueryLogEvents, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiEditPage, ApiQueryAllUsers, ApiQueryBlocks, ApiQueryCategoryMembers, ApiQuerySearch, ApiQueryAllImages, ApiQueryUsers, ApiQueryFilearchive, ApiParamInfo, ApiQueryAllLinks, ApiQueryAllPages, ApiFormatBase, ApiQueryUserInfo, ApiQueryAllMessages, ApiQueryProtectedTitles, ApiQueryContributors, ApiMove, ApiSetNotificationTimestamp, ApiFeedWatchlist, ApiQueryExtLinksUsage, ApiLogin, ApiQueryCategories, ApiQueryRedirects, ApiFormatXml, ApiDelete, ApiQueryLinks, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryAllCategories, ApiBlock, ApiRevisionDelete, ApiQueryLangLinks, ApiProtect, ApiWatch, ApiFeedContributions, ApiQueryWatchlistRaw, ApiImageRotate, ApiQueryDuplicateFiles, ApiQueryQueryPage, ApiFeedRecentChanges, ApiQueryTags, ApiOptions, ApiQueryIWLinks, ApiQueryRandom, ApiPurge, ApiQueryImages, ApiQueryPagesWithProp, ApiCreateAccount, ApiFileRevert, ApiComparePages, ApiHelp, ApiQueryExternalLinks, ApiImport, ApiQueryCategoryInfo, ApiQueryPageProps, ApiUndelete, ApiRollback, ApiUnblock, ApiEmailUser, ApiQueryStashImageInfo, ApiUserrights, ApiPatrol, ApiQueryPrefixSearch, ApiExpandTemplates, ApiFormatWddx, ApiOpenSearch, ApiQueryFileRepoInfo, ApiQueryPagePropNames, ApiTokens, ApiFormatJson, ApiRsd, ApiLogout, ApiDisabled, ApiQueryDisabled, ApiFormatDump, ApiFormatDbg, ApiFormatTxt, ApiFormatPhp, ApiFormatNone, and ApiFormatYaml.

Definition at line 542 of file ApiBase.php.

Referenced by getFinalDescription().

Get error (as code, string) from a Status object.

Since:
1.23
Parameters:
Status$statusStatus object
Returns:
array of code and error string

Definition at line 1381 of file ApiBase.php.

References $messageMap, array(), and wfMessage().

Referenced by dieStatus(), and ApiWatch\watchTitle().

ApiBase::getExamples ( ) [protected]

Returns usage examples for this module.

Return false if no examples are available.

Returns:
bool|string|array

Reimplemented in ApiQueryRevisions, ApiQueryRecentChanges, ApiQueryInfo, ApiQueryImageInfo, ApiUpload, ApiParse, ApiQuerySiteinfo, ApiQuery, ApiQueryWatchlist, ApiEditPage, ApiQueryContributions, ApiQueryLogEvents, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryAllImages, ApiQueryAllUsers, ApiQueryBlocks, ApiQueryCategoryMembers, ApiQuerySearch, ApiQueryUsers, ApiQueryFilearchive, ApiQueryAllLinks, ApiQueryAllPages, ApiParamInfo, ApiFormatBase, ApiCreateAccount, ApiQueryUserInfo, ApiMove, ApiSetNotificationTimestamp, ApiLogin, ApiQueryAllMessages, ApiQueryProtectedTitles, ApiQueryContributors, ApiFeedWatchlist, ApiQueryExtLinksUsage, ApiDelete, ApiQueryCategories, ApiQueryRedirects, ApiBlock, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiProtect, ApiRevisionDelete, ApiQueryLinks, ApiQueryAllCategories, ApiQueryLangLinks, ApiImageRotate, ApiWatch, ApiQueryWatchlistRaw, ApiFeedContributions, ApiOptions, ApiQueryQueryPage, ApiFeedRecentChanges, ApiQueryDuplicateFiles, ApiRollback, ApiQueryRandom, ApiQueryIWLinks, ApiPurge, ApiQueryTags, ApiFileRevert, ApiQueryImages, ApiQueryPagesWithProp, ApiComparePages, ApiImport, ApiUndelete, ApiQueryExternalLinks, ApiHelp, ApiUnblock, ApiEmailUser, ApiQueryCategoryInfo, ApiQueryPageProps, ApiPatrol, ApiUserrights, ApiQueryStashImageInfo, ApiExpandTemplates, ApiQueryPrefixSearch, ApiOpenSearch, ApiQueryFileRepoInfo, ApiQueryPagePropNames, ApiTokens, ApiRsd, ApiLogout, ApiDisabled, and ApiQueryDisabled.

Definition at line 550 of file ApiBase.php.

Referenced by makeHelpMsg().

Get final module description, after hooks have had a chance to tweak it as needed.

Returns:
array|bool False on no parameters

Definition at line 662 of file ApiBase.php.

References array(), getDescription(), and wfRunHooks().

Referenced by makeHelpMsg().

Get final parameter descriptions, after hooks have had a chance to tweak it as needed.

Returns:
array|bool False on no parameter descriptions

Definition at line 603 of file ApiBase.php.

References array(), getParamDescription(), and wfRunHooks().

Referenced by makeHelpMsgParameters().

ApiBase::getFinalParams ( flags = 0)

Get final list of parameters, after hooks have had a chance to tweak it as needed.

Parameters:
int$flagsZero or more flags like GET_VALUES_FOR_HELP
Returns:
array|Bool False on no parameters
Since:
1.21 $flags param added

Definition at line 590 of file ApiBase.php.

References $flags, $params, array(), getAllowedParams(), and wfRunHooks().

Referenced by extractRequestParams(), getParameter(), getPossibleErrors(), and makeHelpMsgParameters().

Get final list of possible errors, after hooks have had a chance to tweak it as needed.

Returns:
array
Since:
1.22

Definition at line 2168 of file ApiBase.php.

References array(), getPossibleErrors(), and wfRunHooks().

Referenced by ApiPurge\getPossibleErrors(), and ApiQuery\getPossibleErrors().

Get final possible result properties, after hooks have had a chance to tweak it as needed.

Returns:
array

Definition at line 636 of file ApiBase.php.

References array(), getResultProperties(), and wfRunHooks().

Get the module manager, or null if this module has no sub-modules.

Since:
1.21
Returns:
ApiModuleManager

Reimplemented in ApiMain, and ApiQuery.

Definition at line 158 of file ApiBase.php.

Get the name of the module being executed by this instance.

Returns:
string

Definition at line 149 of file ApiBase.php.

Referenced by ApiQueryBase\addPageSubItem(), ApiQueryBase\addPageSubItems(), ApiQueryTags\doTag(), ApiComparePages\execute(), ApiProtect\execute(), ApiUndelete\execute(), ApiTokens\execute(), ApiEmailUser\execute(), ApiMove\execute(), ApiQueryStashImageInfo\execute(), ApiImport\execute(), ApiRevisionDelete\execute(), ApiUpload\execute(), ApiUserrights\execute(), ApiEditPage\execute(), ApiWatch\execute(), ApiPatrol\execute(), ApiExpandTemplates\execute(), ApiHelp\execute(), ApiSetNotificationTimestamp\execute(), ApiOptions\execute(), ApiQueryDeletedrevs\execute(), ApiPurge\execute(), ApiQueryAllMessages\execute(), ApiUnblock\execute(), ApiQueryFilearchive\execute(), ApiRollback\execute(), ApiQueryUserInfo\execute(), ApiParamInfo\execute(), ApiBlock\execute(), ApiDelete\execute(), ApiQueryBlocks\execute(), ApiQueryContributions\execute(), ApiQueryLogEvents\execute(), ApiQueryPagePropNames\execute(), ApiQueryTags\execute(), ApiQueryAllUsers\execute(), ApiImageRotate\execute(), ApiQueryUsers\execute(), ApiQueryRevisions\execute(), ApiQueryLinks\getExamples(), ApiFormatBase\getExamples(), ApiQueryAllLinks\getExamples(), ApiQueryAllLinks\getHelpUrls(), getParameterFromSettings(), ApiQueryAllLinks\getPossibleErrors(), getPossibleErrors(), ApiQueryPrefixSearch\run(), ApiQueryIWBacklinks\run(), ApiQueryLangBacklinks\run(), ApiQueryProtectedTitles\run(), ApiQueryWatchlistRaw\run(), ApiQueryExtLinksUsage\run(), ApiQueryCategoryMembers\run(), ApiQueryAllCategories\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQuerySearch\run(), ApiQueryQueryPage\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryRandom\run(), ApiQueryAllLinks\run(), ApiQueryRecentChanges\run(), ApiQueryRandom\runQuery(), ApiQueryBase\setContinueEnumParameter(), and setWarning().

Get parameter prefix (usually two letters or an empty string).

Returns:
string

Definition at line 166 of file ApiBase.php.

Referenced by ApiQueryBase\addPageSubItem(), ApiQueryBase\addPageSubItems(), ApiQueryStashImageInfo\execute(), ApiWatch\execute(), ApiQueryDeletedrevs\getDescription(), ApiQueryAllLinks\getExamples(), 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(), ApiQueryDeletedrevs\getParamDescription(), ApiQueryContributions\getParamDescription(), ApiQueryLogEvents\getParamDescription(), ApiQueryWatchlist\getParamDescription(), ApiEditPage\getParamDescription(), ApiQueryImageInfo\getParamDescription(), ApiQueryRecentChanges\getParamDescription(), ApiQueryRevisions\getParamDescription(), ApiQuerySiteinfo\getParamDescription(), ApiQueryAllImages\getPossibleErrors(), ApiQueryImageInfo\getPossibleErrors(), getRequireAtLeastOneParameterErrorMessages(), getRequireMaxOneParameterErrorMessages(), getRequireOnlyOneParameterErrorMessages(), ApiQueryImageInfo\getScale(), ApiQueryImageInfo\mergeThumbParams(), requireAtLeastOneParameter(), requireMaxOneParameter(), requireOnlyOneParameter(), ApiQueryPrefixSearch\run(), ApiQueryProtectedTitles\run(), ApiQueryExtLinksUsage\run(), ApiQueryAllImages\run(), and ApiQueryAllLinks\run().

Get the name of the module as shown in the profiler log.

Parameters:
$dbDatabaseBase|bool
Returns:
string

Definition at line 177 of file ApiBase.php.

Referenced by profileDBIn(), profileDBOut(), profileIn(), and profileOut().

Returns an array of parameter descriptions.

Don't call this function directly: use getFinalParamDescription() to allow hooks to modify descriptions as needed.

Returns:
array|bool False on no parameter descriptions

Reimplemented in ApiPageSet, ApiMain, ApiQueryInfo, ApiQuerySiteinfo, ApiQueryRevisions, ApiUpload, ApiParse, ApiQueryRecentChanges, ApiQuery, ApiQueryImageInfo, ApiEditPage, ApiQueryWatchlist, ApiQueryLogEvents, ApiQueryContributions, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryAllUsers, ApiQueryAllImages, ApiQueryCategoryMembers, ApiParamInfo, ApiQueryBlocks, ApiQuerySearch, ApiQueryAllLinks, ApiQueryUsers, ApiQueryAllPages, ApiQueryFilearchive, ApiQueryORM, ApiFeedWatchlist, ApiQueryContributors, ApiQueryAllMessages, ApiFormatXml, ApiQueryRedirects, ApiQueryProtectedTitles, ApiMove, ApiSetNotificationTimestamp, ApiQueryUserInfo, ApiQueryCategories, ApiDelete, ApiQueryLinks, ApiQueryExtLinksUsage, ApiCreateAccount, ApiRevisionDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiImageRotate, ApiFeedContributions, ApiQueryAllCategories, ApiWatch, ApiLogin, ApiQueryDuplicateFiles, ApiProtect, ApiQueryLangLinks, ApiQueryWatchlistRaw, ApiFeedRecentChanges, ApiOptions, ApiBlock, ApiQueryRandom, ApiQueryImages, ApiQueryIWLinks, ApiQueryPagesWithProp, ApiQueryQueryPage, ApiQueryTags, ApiHelp, ApiPurge, ApiFileRevert, ApiQueryPageProps, ApiComparePages, ApiQueryExternalLinks, ApiImport, ApiUndelete, ApiUserrights, ApiQueryStashImageInfo, ApiRollback, ApiQueryCategoryInfo, ApiEmailUser, ApiQueryPrefixSearch, ApiOpenSearch, ApiQueryPagePropNames, ApiUnblock, ApiTokens, ApiExpandTemplates, ApiPatrol, ApiQueryFileRepoInfo, ApiFormatJson, ApiRsd, ApiLogout, ApiDisabled, and ApiQueryDisabled.

Definition at line 578 of file ApiBase.php.

Referenced by getFinalParamDescription().

ApiBase::getParameter ( paramName,
parseLimit = true 
) [protected]

Get a value for the given parameter.

Parameters:
string$paramNameParameter name
bool$parseLimitsee extractRequestParams()
Returns:
mixed Parameter value

Definition at line 712 of file ApiBase.php.

References $params, getFinalParams(), and getParameterFromSettings().

Referenced by ApiFeedRecentChanges\execute(), and ApiMain\sendCacheHeaders().

ApiBase::getParameterFromSettings ( paramName,
paramSettings,
parseLimit 
) [protected]

Using the settings determine the value for the given parameter.

Parameters:
string$paramNameparameter name
array | mixed$paramSettingsdefault value or an array of settings using PARAM_* constants.
$parseLimitBoolean: parse limit?
Returns:
mixed Parameter value

Definition at line 971 of file ApiBase.php.

References $key, $value, array(), as, dieDebug(), dieUsage(), dieUsageMsg(), encodeParamName(), getMain(), getModuleName(), getResult(), MWNamespace\getValidNamespaces(), PARAM_ALLOW_DUPLICATES, PARAM_DEPRECATED, PARAM_DFLT, PARAM_ISMULTI, PARAM_MAX, PARAM_MAX2, PARAM_MIN, PARAM_RANGE_ENFORCE, PARAM_REQUIRED, PARAM_TYPE, parseMultiValue(), setWarning(), validateLimit(), validateTimestamp(), and validateUser().

Referenced by extractRequestParams(), and getParameter().

Returns a list of all possible errors returned by the module.

Don't call this function directly: use getFinalPossibleErrors() to allow hooks to modify parameters as needed.

Returns:
array in the format of array( key, param1, param2, ... ) or array( 'code' => ..., 'info' => ... )

Reimplemented in ApiMain, ApiPageSet, ApiQueryRecentChanges, ApiQueryRevisions, ApiQueryImageInfo, ApiQuerySiteinfo, ApiParse, ApiUpload, ApiQuery, ApiQueryWatchlist, ApiQueryContributions, ApiQueryLogEvents, ApiQueryBase, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiEditPage, ApiQueryAllUsers, ApiQueryBlocks, ApiQueryCategoryMembers, ApiQuerySearch, ApiQueryAllImages, ApiQueryFilearchive, ApiQueryAllLinks, ApiQueryAllPages, ApiSetNotificationTimestamp, ApiMove, ApiFeedWatchlist, ApiQueryContributors, ApiLogin, ApiQueryExtLinksUsage, ApiQueryAllMessages, ApiQueryCategories, ApiCreateAccount, ApiDelete, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiBlock, ApiRevisionDelete, ApiQueryLangLinks, ApiProtect, ApiImageRotate, ApiWatch, ApiFeedContributions, ApiQueryWatchlistRaw, ApiQueryQueryPage, ApiFeedRecentChanges, ApiOptions, ApiQueryIWLinks, ApiPurge, ApiFileRevert, ApiComparePages, ApiImport, ApiQueryExternalLinks, ApiUndelete, ApiRollback, ApiUnblock, ApiEmailUser, ApiPatrol, and ApiExpandTemplates.

Definition at line 2114 of file ApiBase.php.

References $params, $ret, array(), as, getFinalParams(), getModuleName(), isReadMode(), isWriteMode(), mustBePosted(), needsToken(), and PARAM_REQUIRED.

Referenced by getFinalPossibleErrors().

Total time the module used the database.

Returns:
float

Definition at line 2301 of file ApiBase.php.

References dieDebug().

Total time the module was executed.

Returns:
float

Definition at line 2247 of file ApiBase.php.

References dieDebug().

Generates the possible errors requireAtLeastOneParameter() can die with.

Since:
1.23
Parameters:
$paramsarray Array of parameter key names
Returns:
array

Definition at line 834 of file ApiBase.php.

References $params, array(), and getModulePrefix().

Generates the possible errors requireOnlyOneParameter() can die with.

Parameters:
$paramsarray
Returns:
array

Definition at line 749 of file ApiBase.php.

References $params, array(), and getModulePrefix().

Referenced by ApiMove\getPossibleErrors(), ApiSetNotificationTimestamp\getPossibleErrors(), ApiUpload\getPossibleErrors(), and getTitleOrPageIdErrorMessage().

Get the result object.

Returns:
ApiResult

Reimplemented in ApiMain.

Definition at line 206 of file ApiBase.php.

References dieDebug(), getMain(), and isMain().

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(), ApiProtect\execute(), ApiCreateAccount\execute(), ApiTokens\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiEmailUser\execute(), ApiImport\execute(), ApiQueryStashImageInfo\execute(), ApiRevisionDelete\execute(), ApiRsd\execute(), ApiEditPage\execute(), ApiUpload\execute(), ApiUserrights\execute(), ApiWatch\execute(), ApiExpandTemplates\execute(), ApiPatrol\execute(), ApiSetNotificationTimestamp\execute(), ApiHelp\execute(), ApiOptions\execute(), ApiQueryDeletedrevs\execute(), ApiUnblock\execute(), ApiPurge\execute(), ApiQueryAllMessages\execute(), ApiQueryPageProps\execute(), ApiQueryFilearchive\execute(), ApiQueryUserInfo\execute(), ApiRollback\execute(), ApiBlock\execute(), ApiParamInfo\execute(), ApiFeedContributions\execute(), ApiDelete\execute(), ApiQueryBlocks\execute(), ApiFeedRecentChanges\execute(), ApiQueryFileRepoInfo\execute(), ApiQueryContributions\execute(), ApiQueryLogEvents\execute(), ApiQueryPagePropNames\execute(), ApiQueryImageInfo\execute(), ApiQueryTags\execute(), ApiQueryContributors\execute(), ApiOpenSearch\execute(), ApiQueryAllUsers\execute(), ApiLogin\execute(), ApiImageRotate\execute(), ApiFeedWatchlist\execute(), ApiQueryUsers\execute(), ApiQueryRevisions\execute(), ApiQueryInfo\execute(), ApiQueryInfo\extractPageInfo(), ApiQueryWatchlist\extractRowInfo(), ApiQueryContributions\extractRowInfo(), ApiQueryLogEvents\extractRowInfo(), ApiQueryRecentChanges\extractRowInfo(), ApiQueryRevisions\extractRowInfo(), ApiRevisionDelete\extractStatusInfo(), ApiRsd\formatRsdApiList(), ApiRevisionDelete\formatStatusMessages(), ApiQueryUserInfo\getCurrentUserInfo(), getParameterFromSettings(), getResultData(), ApiQueryPrefixSearch\run(), ApiQueryLangBacklinks\run(), ApiQueryIWBacklinks\run(), ApiQueryProtectedTitles\run(), ApiQueryWatchlistRaw\run(), ApiQueryExtLinksUsage\run(), ApiQueryAllCategories\run(), ApiQueryCategoryMembers\run(), ApiQueryPagesWithProp\run(), ApiQueryWatchlist\run(), ApiQueryQueryPage\run(), ApiQuerySearch\run(), ApiQueryAllPages\run(), ApiQueryAllImages\run(), ApiQueryRandom\run(), ApiQueryAllLinks\run(), ApiQueryRecentChanges\run(), ApiQueryRandom\runQuery(), ApiQueryBase\setContinueEnumParameter(), ApiQueryORM\setIndexedTagNames(), setWarning(), and ApiUpload\transformWarnings().

Returns possible properties in the result, grouped by the value of the prop parameter that shows them.

Properties that are shown always are in a group with empty string as a key. Properties that can be shown by several values of prop are included multiple times. If some properties are part of a list and some are on the root object (see ApiQueryQueryPage), those on the root object are under the key PROP_ROOT. The array can also contain a boolean under the key PROP_LIST, indicating whether the result is a list.

Don't call this function directly: use getFinalResultProperties() to allow hooks to modify descriptions as needed.

Returns:
array|bool False on no properties

Reimplemented in ApiQueryImageInfo, ApiQueryInfo, ApiQueryRevisions, ApiQueryRecentChanges, ApiUpload, ApiEditPage, ApiQueryWatchlist, ApiQueryContributions, ApiQueryLogEvents, ApiQueryBacklinks, ApiQueryDeletedrevs, ApiQueryAllUsers, ApiQueryAllImages, ApiQueryCategoryMembers, ApiQueryBlocks, ApiQuerySearch, ApiQueryAllLinks, ApiQueryAllPages, ApiQueryUsers, ApiQueryFilearchive, ApiQueryAllMessages, ApiQueryProtectedTitles, ApiMove, ApiQueryExtLinksUsage, ApiQueryUserInfo, ApiQueryCategories, ApiSetNotificationTimestamp, ApiDelete, ApiCreateAccount, ApiQueryLinks, ApiQueryIWBacklinks, ApiQueryLangBacklinks, ApiQueryAllCategories, ApiProtect, ApiWatch, ApiLogin, ApiQueryLangLinks, ApiQueryWatchlistRaw, ApiQueryDuplicateFiles, ApiBlock, ApiQueryRandom, ApiQueryIWLinks, ApiQueryImages, ApiQueryTags, ApiQueryQueryPage, ApiOptions, ApiPurge, ApiFileRevert, ApiQueryExternalLinks, ApiComparePages, ApiImport, ApiUndelete, ApiQueryStashImageInfo, ApiRollback, ApiQueryCategoryInfo, ApiEmailUser, ApiUnblock, ApiExpandTemplates, ApiPatrol, ApiTokens, and ApiLogout.

Definition at line 626 of file ApiBase.php.

Referenced by getFinalResultProperties().

ApiBase::getTitleOrPageId ( params,
load = false 
)
Parameters:
$paramsarray
bool | string$loadWhether load the object's state from the database:
  • false: don't load (if the pageid is given, it will still be loaded)
  • 'fromdb': load from a slave database
  • 'fromdbmaster': load from the master database
Returns:
WikiPage

Definition at line 854 of file ApiBase.php.

References $params, array(), dieUsage(), dieUsageMsg(), WikiPage\factory(), WikiPage\newFromID(), Title\newFromText(), and requireOnlyOneParameter().

Referenced by ApiProtect\execute(), ApiEditPage\execute(), ApiDelete\execute(), and ApiQueryCategoryMembers\run().

Returns the token salt if there is one, '' if the module doesn't require a salt, else false if the module doesn't need a token You have also to override needsToken() Value is passed to User::getEditToken.

Returns:
bool|string|array

Reimplemented in ApiUpload, ApiEditPage, ApiMove, ApiDelete, ApiBlock, ApiProtect, ApiRevisionDelete, ApiImageRotate, ApiOptions, ApiSetNotificationTimestamp, ApiFileRevert, ApiImport, ApiWatch, ApiUndelete, ApiRollback, ApiUnblock, ApiEmailUser, ApiPatrol, and ApiUserrights.

Definition at line 2061 of file ApiBase.php.

Returns a string that identifies the version of the extending class.

Typically includes the class name, the svn revision, timestamp, and last author. Usually done with SVN's Id keyword

Returns:
string
Deprecated:
since 1.21, version string is no longer supported

Reimplemented in MockApi, and MockApiQueryBase.

Definition at line 139 of file ApiBase.php.

References wfDeprecated().

Gets the user for whom to get the watchlist.

Parameters:
$paramsarray
Returns:
User

Definition at line 2071 of file ApiBase.php.

References $params, $user, dieUsage(), ContextSource\getUser(), and User\newFromName().

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.

Parameters:
string$watchlistValid values: 'watch', 'unwatch', 'preferences', 'nochange'
$titleObjTitle the page under consideration
string$userOptionThe user option to consider when $watchlist=preferences. If not set will use watchdefault always and watchcreations if $titleObj doesn't exist.
Returns:
bool

Definition at line 914 of file ApiBase.php.

References ContextSource\getUser(), and WatchedItem\IGNORE_USER_RIGHTS.

Referenced by ApiEditPage\execute(), and setWatch().

ApiBase::indentExampleText ( item) [private]
Parameters:
$itemstring
Returns:
string

Definition at line 355 of file ApiBase.php.

Returns true if this module is the main module ($this === $this->mMainModule), false otherwise.

Returns:
bool

Definition at line 198 of file ApiBase.php.

Referenced by __construct(), and getResult().

Indicates whether this module requires read rights.

Returns:
bool

Reimplemented in ApiMain, ApiParamInfo, ApiCreateAccount, ApiLogin, ApiHelp, ApiLogout, and ApiDisabled.

Definition at line 2023 of file ApiBase.php.

Referenced by getPossibleErrors(), and makeHelpMsg().

ApiBase::makeHelpArrayToString ( prefix,
title,
input 
) [protected]
Parameters:
string$prefixText to split output items
string$titleWhat is being output
$inputstring|array
Returns:
string

Definition at line 365 of file ApiBase.php.

References $title, and array().

Referenced by makeHelpMsg().

Generates help message for this module, or false if there is no description.

Returns:
mixed string or false

Reimplemented in ApiMain, and ApiQuery.

Definition at line 287 of file ApiBase.php.

References array(), as, getExamples(), getFinalDescription(), getHelpUrls(), isReadMode(), isWriteMode(), makeHelpArrayToString(), makeHelpMsgParameters(), and mustBePosted().

Generates the parameter descriptions for this module, to be displayed in the module's help.

Returns:
string or false

Definition at line 392 of file ApiBase.php.

References $params, $s, $t, array(), as, encodeParamName(), GET_VALUES_FOR_HELP, getFinalParamDescription(), getFinalParams(), MWNamespace\getValidNamespaces(), PARAM_DFLT, PARAM_ISMULTI, and PARAM_TYPE.

Referenced by makeHelpMsg().

Returns whether this module requires a token to execute It is used to show possible errors in action=paraminfo see bug 25248.

Returns:
bool

Reimplemented in ApiUpload, ApiEditPage, ApiMove, ApiDelete, ApiBlock, ApiProtect, ApiRevisionDelete, ApiImageRotate, ApiOptions, ApiSetNotificationTimestamp, ApiFileRevert, ApiImport, ApiWatch, ApiUndelete, ApiRollback, ApiUnblock, ApiEmailUser, ApiPatrol, and ApiUserrights.

Definition at line 2049 of file ApiBase.php.

Referenced by getPossibleErrors().

ApiBase::parameterNotEmpty ( x) [private]

Callback function used in requireOnlyOneParameter to check whether required parameters are set.

Parameters:
$xobject Parameter to check is not null/false
Returns:
bool

Definition at line 902 of file ApiBase.php.

ApiBase::parseErrors ( errors)

Parses a list of errors into a standardised format.

Parameters:
array$errorsList of errors. Items can be in the for array( key, param1, param2, ... ) or array( 'code' => ..., 'info' => ... )
Returns:
array Parsed list of errors with items in the form array( 'code' => ..., 'info' => ... )

Definition at line 2181 of file ApiBase.php.

References $ret, array(), as, and parseMsg().

ApiBase::parseMsg ( error)

Return the error message related to a certain array.

Parameters:
array$errorElement of a getUserPermissionsErrors()-style array
Returns:
array('code' => code, 'info' => info)

Definition at line 1979 of file ApiBase.php.

References $error, $key, array(), and wfMsgReplaceArgs().

Referenced by ApiImageRotate\checkPermissions(), dieReadOnly(), dieUsageMsg(), dieUsageMsgOrDebug(), ApiMove\execute(), ApiPurge\execute(), ApiMove\moveSubpages(), and parseErrors().

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.

Parameters:
string$valueNameThe name of the parameter (for error reporting)
$valuemixed The value being parsed
bool$allowMultipleCan $value contain more than one value separated by '|'?
$allowedValuesmixed An array of values to check against. If null, all values are accepted.
Returns:
mixed (allowMultiple ? an_array_of_values : a_single_value)

Definition at line 1190 of file ApiBase.php.

References $s, $value, array(), dieUsage(), LIMIT_SML1, and setWarning().

Referenced by getParameterFromSettings().

Start module profiling.

Definition at line 2263 of file ApiBase.php.

References dieDebug(), getModuleProfileName(), and wfProfileIn().

Referenced by ApiQueryBase\checkRowCount(), getDB(), and ApiQueryBase\select().

Start module profiling.

Definition at line 2203 of file ApiBase.php.

References dieDebug(), getModuleProfileName(), and wfProfileIn().

End module profiling.

Definition at line 2214 of file ApiBase.php.

References dieDebug(), getModuleProfileName(), and wfProfileOut().

Referenced by safeProfileOut().

Die if none of a certain set of parameters is set and not false.

Since:
1.23
Parameters:
array$paramsUser provided set of parameters
string... List of parameter names to check

Definition at line 811 of file ApiBase.php.

References $params, array(), dieUsage(), and getModulePrefix().

Die if more than one of a certain set of parameters is set and not false.

Parameters:
$paramsarray

Definition at line 770 of file ApiBase.php.

References $params, array(), dieUsage(), and getModulePrefix().

Referenced by ApiSetNotificationTimestamp\execute(), ApiQueryLangLinks\execute(), ApiQueryBlocks\execute(), and ApiQueryContributors\execute().

Die if none or more than one of a certain set of parameters is set and not false.

Parameters:
array$paramsof parameter names

Definition at line 723 of file ApiBase.php.

References $params, array(), dieUsage(), and getModulePrefix().

Referenced by ApiMove\execute(), ApiPatrol\execute(), getTitleOrPageId(), 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 2234 of file ApiBase.php.

References profileDBOut(), and profileOut().

ApiBase::setWatch ( watch,
titleObj,
userOption = null 
) [protected]

Set a watch (or unwatch) based the based on a watchlist parameter.

Parameters:
string$watchValid values: 'watch', 'unwatch', 'preferences', 'nochange'
$titleObjTitle the article's title to change
string$userOptionThe user option to consider when $watch=preferences

Definition at line 953 of file ApiBase.php.

References $value, WatchAction\doWatchOrUnwatch(), ContextSource\getUser(), and getWatchlistValue().

Referenced by ApiProtect\execute(), ApiUndelete\execute(), ApiMove\execute(), ApiRollback\execute(), and ApiDelete\execute().

Indicates if this module needs maxlag to be checked.

Returns:
bool

Reimplemented in ApiQuery, and ApiHelp.

Definition at line 2015 of file ApiBase.php.

static ApiBase::truncateArray ( &$  arr,
limit 
) [static]

Truncate an array to a certain length.

Parameters:
array$arrArray to truncate
int$limitMaximum length
Returns:
bool True if the array was truncated, false otherwise

Definition at line 1342 of file ApiBase.php.

References $limit.

ApiBase::validateLimit ( paramName,
&$  value,
min,
max,
botMax = null,
enforceLimits = false 
)

Validate the value against the minimum and user/bot maximum limits.

Prints usage info on failure.

Parameters:
string$paramNameParameter name
int$valueParameter value
int | null$minMinimum value
int | null$maxMaximum value for users
int$botMaxMaximum value for sysops/bots
$enforceLimitsBoolean Whether to enforce (die) if value is outside limits

Definition at line 1254 of file ApiBase.php.

References $value, encodeParamName(), getMain(), and warnOrDie().

Referenced by ApiQueryDeletedrevs\execute(), ApiQueryRevisions\execute(), and getParameterFromSettings().

ApiBase::validateTimestamp ( value,
encParamName 
)

Validate and normalize of parameters of type 'timestamp'.

Parameters:
string$valueParameter value
string$encParamNameParameter name
Returns:
string Validated and normalized parameter

Definition at line 1292 of file ApiBase.php.

References $value, dieUsage(), and wfTimestamp().

Referenced by getParameterFromSettings().

ApiBase::validateUser ( value,
encParamName 
) [private]

Validate and normalize of parameters of type 'user'.

Parameters:
string$valueParameter value
string$encParamNameParameter name
Returns:
string Validated and normalized parameter

Definition at line 1310 of file ApiBase.php.

References $title, $value, dieUsage(), and Title\makeTitleSafe().

Referenced by getParameterFromSettings().

ApiBase::warnOrDie ( msg,
enforceLimits = false 
) [private]

Adds a warning to the output, else dies.

Parameters:
$msgString Message to show as a warning, or error message if dying
$enforceLimitsBoolean Whether this is an enforce (die)

Definition at line 1328 of file ApiBase.php.

References dieUsage(), and setWarning().

Referenced by validateLimit().


Member Data Documentation

ApiBase::$mDBTime = 0

Definition at line 2258 of file ApiBase.php.

ApiBase::$mDBTimeIn = 0 [private]

Profiling: database execution time.

Definition at line 2258 of file ApiBase.php.

ApiBase::$messageMap [static]

Array that maps message keys to error messages.

$1 and friends are replaced.

Definition at line 1430 of file ApiBase.php.

Referenced by getErrorFromStatus().

ApiBase::$mMainModule [private]

Definition at line 90 of file ApiBase.php.

ApiBase::$mModuleName

Definition at line 90 of file ApiBase.php.

ApiBase::$mModulePrefix

Definition at line 90 of file ApiBase.php.

ApiBase::$mModuleTime = 0

Definition at line 2198 of file ApiBase.php.

ApiBase::$mParamCache = array() [private]

Definition at line 92 of file ApiBase.php.

ApiBase::$mSlaveDB = null [private]

Definition at line 91 of file ApiBase.php.

ApiBase::$mTimeIn = 0 [private]

Profiling: total module execution time.

Definition at line 2198 of file ApiBase.php.

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

Since:
1.21

Definition at line 88 of file ApiBase.php.

Referenced by ApiQueryLogEvents\getAllowedParams(), ApiPageSet\getAllowedParams(), and makeHelpMsgParameters().

Definition at line 46 of file ApiBase.php.

Referenced by ApiQueryFileRepoInfo\getAllowedParams(), ApiOpenSearch\getAllowedParams(), ApiTokens\getAllowedParams(), ApiQueryStashImageInfo\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiUserrights\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiOptions\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiFeedContributions\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiRevisionDelete\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiDelete\getAllowedParams(), ApiCreateAccount\getAllowedParams(), ApiMove\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryUserInfo\getAllowedParams(), ApiQueryAllMessages\getAllowedParams(), ApiQueryRedirects\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiEditPage\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiUpload\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), ApiQuerySiteinfo\getAllowedParams(), ApiQueryInfo\getAllowedParams(), getParameterFromSettings(), and makeHelpMsgParameters().

Definition at line 48 of file ApiBase.php.

Referenced by ApiQueryFileRepoInfo\getAllowedParams(), ApiOpenSearch\getAllowedParams(), ApiTokens\getAllowedParams(), ApiQueryStashImageInfo\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiUserrights\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPageProps\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiHelp\getAllowedParams(), ApiOptions\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiFeedContributions\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiRevisionDelete\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryUserInfo\getAllowedParams(), ApiQueryAllMessages\getAllowedParams(), ApiQueryRedirects\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQuery\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), ApiQuerySiteinfo\getAllowedParams(), ApiQueryInfo\getAllowedParams(), ApiPageSet\getAllowedParams(), getParameterFromSettings(), and makeHelpMsgParameters().

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(), ApiQueryLangLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryRedirects\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), and getParameterFromSettings().

Definition at line 54 of file ApiBase.php.

Referenced by ApiOpenSearch\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryRedirects\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), and getParameterFromSettings().

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(), ApiQueryLangLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\getAllowedParams(), ApiQueryRandom\getAllowedParams(), ApiQueryAllCategories\getAllowedParams(), ApiQueryDuplicateFiles\getAllowedParams(), ApiQueryLangBacklinks\getAllowedParams(), ApiQueryIWBacklinks\getAllowedParams(), ApiQueryProtectedTitles\getAllowedParams(), ApiQueryCategories\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryRedirects\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), and getParameterFromSettings().

Since:
1.17

Definition at line 66 of file ApiBase.php.

Referenced by getParameterFromSettings().

Definition at line 50 of file ApiBase.php.

Referenced by ApiQueryFileRepoInfo\getAllowedParams(), ApiOpenSearch\getAllowedParams(), ApiTokens\getAllowedParams(), ApiPatrol\getAllowedParams(), ApiQueryStashImageInfo\getAllowedParams(), ApiExpandTemplates\getAllowedParams(), ApiQueryPrefixSearch\getAllowedParams(), ApiQueryPagePropNames\getAllowedParams(), ApiUnblock\getAllowedParams(), ApiEmailUser\getAllowedParams(), ApiUserrights\getAllowedParams(), ApiUndelete\getAllowedParams(), ApiImport\getAllowedParams(), ApiQueryExternalLinks\getAllowedParams(), ApiComparePages\getAllowedParams(), ApiFeedRecentChanges\getAllowedParams(), ApiQueryPagesWithProp\getAllowedParams(), ApiQueryWatchlistRaw\getAllowedParams(), ApiOptions\getAllowedParams(), ApiQueryTags\getAllowedParams(), ApiQueryLangLinks\getAllowedParams(), ApiQueryImages\getAllowedParams(), ApiQueryIWLinks\getAllowedParams(), ApiProtect\getAllowedParams(), ApiQueryQueryPage\getAllowedParams(), ApiQueryExtLinksUsage\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(), ApiDelete\getAllowedParams(), ApiCreateAccount\getAllowedParams(), ApiMove\getAllowedParams(), ApiQueryLinks\getAllowedParams(), ApiQueryUserInfo\getAllowedParams(), ApiSetNotificationTimestamp\getAllowedParams(), ApiQueryAllMessages\getAllowedParams(), ApiQueryRedirects\getAllowedParams(), ApiQueryContributors\getAllowedParams(), ApiFeedWatchlist\getAllowedParams(), ApiQueryAllPages\getAllowedParams(), ApiQueryORM\getAllowedParams(), ApiQueryFilearchive\getAllowedParams(), ApiQuerySearch\getAllowedParams(), ApiQueryAllLinks\getAllowedParams(), ApiQueryCategoryMembers\getAllowedParams(), ApiQueryBlocks\getAllowedParams(), ApiQueryUsers\getAllowedParams(), ApiQueryAllImages\getAllowedParams(), ApiQueryAllUsers\getAllowedParams(), ApiQueryDeletedrevs\getAllowedParams(), ApiQueryContributions\getAllowedParams(), ApiQueryLogEvents\getAllowedParams(), ApiQueryWatchlist\getAllowedParams(), ApiEditPage\getAllowedParams(), ApiQueryImageInfo\getAllowedParams(), ApiQuery\getAllowedParams(), ApiQueryRecentChanges\getAllowedParams(), ApiUpload\getAllowedParams(), ApiQueryRevisions\getAllowedParams(), ApiQuerySiteinfo\getAllowedParams(), ApiQueryInfo\getAllowedParams(), ApiPageSet\getAllowedParams(), getParameterFromSettings(), and makeHelpMsgParameters().


The documentation for this class was generated from the following file: