break;
}
- $vals = array();
+ $vals = [];
$vals['propname'] = $row->pp_propname;
- $fit = $result->addValue( array( 'query', $this->getModuleName() ), null, $vals );
+ $fit = $result->addValue( [ 'query', $this->getModuleName() ], null, $vals );
if ( !$fit ) {
$this->setContinueEnumParameter( 'continue', $row->pp_propname );
break;
}
}
- $result->setIndexedTagName_internal( array( 'query', $this->getModuleName() ), 'p' );
+ $result->addIndexedTagName( [ 'query', $this->getModuleName() ], 'p' );
}
public function getAllowedParams() {
- return array(
- 'continue' => null,
- 'limit' => array(
+ return [
+ 'continue' => [
+ ApiBase::PARAM_HELP_MSG => 'api-help-param-continue',
+ ],
+ 'limit' => [
ApiBase::PARAM_TYPE => 'limit',
ApiBase::PARAM_DFLT => 10,
ApiBase::PARAM_MIN => 1,
ApiBase::PARAM_MAX => ApiBase::LIMIT_BIG1,
ApiBase::PARAM_MAX2 => ApiBase::LIMIT_BIG2
- ),
- );
+ ],
+ ];
}
- public function getParamDescription() {
- return array(
- 'continue' => 'When more results are available, use this to continue',
- 'limit' => 'The maximum number of pages to return',
- );
- }
-
- public function getDescription() {
- return 'List all page prop names in use on the wiki.';
- }
-
- public function getExamples() {
- return array(
- 'api.php?action=query&list=pagepropnames' => 'Get first 10 prop names',
- );
+ protected function getExamplesMessages() {
+ return [
+ 'action=query&list=pagepropnames'
+ => 'apihelp-query+pagepropnames-example-simple',
+ ];
}
public function getHelpUrls() {