@@ -408,7 +408,7 @@ discard block |
||
408 | 408 | * Returning true will generate errors indicating that the API module needs |
409 | 409 | * updating. |
410 | 410 | * |
411 | - * @return string|false |
|
411 | + * @return boolean |
|
412 | 412 | */ |
413 | 413 | public function needsToken() { |
414 | 414 | return false; |
@@ -421,7 +421,7 @@ discard block |
||
421 | 421 | * |
422 | 422 | * @since 1.24 |
423 | 423 | * @param array $params All supplied parameters for the module |
424 | - * @return string|array|null |
|
424 | + * @return string |
|
425 | 425 | */ |
426 | 426 | protected function getWebUITokenSalt( array $params ) { |
427 | 427 | return null; |
@@ -437,7 +437,7 @@ discard block |
||
437 | 437 | * RFC 7232 § 2.2 for semantics. |
438 | 438 | * - etag: Return an entity-tag representing the state of all resources involved |
439 | 439 | * in the request. Quotes must be included. See RFC 7232 § 2.3 for semantics. |
440 | - * @return string|bool|null As described above, or null if no value is available. |
|
440 | + * @return string As described above, or null if no value is available. |
|
441 | 441 | */ |
442 | 442 | public function getConditionalRequestData( $condition ) { |
443 | 443 | return null; |
@@ -486,7 +486,7 @@ discard block |
||
486 | 486 | /** |
487 | 487 | * Get the parent of this module |
488 | 488 | * @since 1.25 |
489 | - * @return ApiBase|null |
|
489 | + * @return ApiMain |
|
490 | 490 | */ |
491 | 491 | public function getParent() { |
492 | 492 | return $this->isMain() ? null : $this->getMain(); |
@@ -621,6 +621,7 @@ discard block |
||
621 | 621 | /** |
622 | 622 | * Set the continuation manager |
623 | 623 | * @param ApiContinuationManager|null |
624 | + * @param ApiContinuationManager|null $manager |
|
624 | 625 | */ |
625 | 626 | public function setContinuationManager( $manager ) { |
626 | 627 | // Main module has setContinuationManager() method overridden |
@@ -704,6 +705,7 @@ discard block |
||
704 | 705 | * |
705 | 706 | * @param array $params User provided set of parameters, as from $this->extractRequestParams() |
706 | 707 | * @param string $required,... Names of parameters of which exactly one must be set |
708 | + * @param string $required |
|
707 | 709 | */ |
708 | 710 | public function requireOnlyOneParameter( $params, $required /*...*/ ) { |
709 | 711 | $required = func_get_args(); |
@@ -730,6 +732,7 @@ discard block |
||
730 | 732 | * |
731 | 733 | * @param array $params User provided set of parameters, as from $this->extractRequestParams() |
732 | 734 | * @param string $required,... Names of parameters of which at most one must be set |
735 | + * @param string $required |
|
733 | 736 | */ |
734 | 737 | public function requireMaxOneParameter( $params, $required /*...*/ ) { |
735 | 738 | $required = func_get_args(); |
@@ -753,6 +756,7 @@ discard block |
||
753 | 756 | * @since 1.23 |
754 | 757 | * @param array $params User provided set of parameters, as from $this->extractRequestParams() |
755 | 758 | * @param string $required,... Names of parameters of which at least one must be set |
759 | + * @param string $required |
|
756 | 760 | */ |
757 | 761 | public function requireAtLeastOneParameter( $params, $required /*...*/ ) { |
758 | 762 | $required = func_get_args(); |
@@ -2531,7 +2535,7 @@ discard block |
||
2531 | 2535 | * "apihelp-{$this->getModulePath()}-description". |
2532 | 2536 | * |
2533 | 2537 | * @deprecated since 1.25 |
2534 | - * @return Message|string|array |
|
2538 | + * @return boolean |
|
2535 | 2539 | */ |
2536 | 2540 | protected function getDescription() { |
2537 | 2541 | return false; |
@@ -2567,7 +2571,7 @@ discard block |
||
2567 | 2571 | * that value, and boolean false means "no examples". |
2568 | 2572 | * |
2569 | 2573 | * @deprecated since 1.25, use getExamplesMessages() instead |
2570 | - * @return bool|string|array |
|
2574 | + * @return boolean |
|
2571 | 2575 | */ |
2572 | 2576 | protected function getExamples() { |
2573 | 2577 | return false; |
@@ -2576,7 +2580,7 @@ discard block |
||
2576 | 2580 | /** |
2577 | 2581 | * Generates help message for this module, or false if there is no description |
2578 | 2582 | * @deprecated since 1.25 |
2579 | - * @return string|bool |
|
2583 | + * @return string |
|
2580 | 2584 | */ |
2581 | 2585 | public function makeHelpMsg() { |
2582 | 2586 | wfDeprecated( __METHOD__, '1.25' ); |
@@ -2686,7 +2690,7 @@ discard block |
||
2686 | 2690 | * Generates the parameter descriptions for this module, to be displayed in the |
2687 | 2691 | * module's help. |
2688 | 2692 | * @deprecated since 1.25 |
2689 | - * @return string|bool |
|
2693 | + * @return string|false |
|
2690 | 2694 | */ |
2691 | 2695 | public function makeHelpMsgParameters() { |
2692 | 2696 | wfDeprecated( __METHOD__, '1.25' ); |
@@ -2877,7 +2881,7 @@ discard block |
||
2877 | 2881 | |
2878 | 2882 | /** |
2879 | 2883 | * @deprecated since 1.25, always returns 0 |
2880 | - * @return float |
|
2884 | + * @return integer |
|
2881 | 2885 | */ |
2882 | 2886 | public function getProfileTime() { |
2883 | 2887 | wfDeprecated( __METHOD__, '1.25' ); |
@@ -2900,7 +2904,7 @@ discard block |
||
2900 | 2904 | |
2901 | 2905 | /** |
2902 | 2906 | * @deprecated since 1.25, always returns 0 |
2903 | - * @return float |
|
2907 | + * @return integer |
|
2904 | 2908 | */ |
2905 | 2909 | public function getProfileDBTime() { |
2906 | 2910 | wfDeprecated( __METHOD__, '1.25' ); |
@@ -423,7 +423,7 @@ discard block |
||
423 | 423 | /** |
424 | 424 | * Return the list of revision fields that should be selected to create |
425 | 425 | * a new revision. |
426 | - * @return array |
|
426 | + * @return string[] |
|
427 | 427 | */ |
428 | 428 | public static function selectFields() { |
429 | 429 | global $wgContentHandlerUseDB; |
@@ -454,7 +454,7 @@ discard block |
||
454 | 454 | /** |
455 | 455 | * Return the list of revision fields that should be selected to create |
456 | 456 | * a new revision from an archive row. |
457 | - * @return array |
|
457 | + * @return string[] |
|
458 | 458 | */ |
459 | 459 | public static function selectArchiveFields() { |
460 | 460 | global $wgContentHandlerUseDB; |
@@ -485,7 +485,7 @@ discard block |
||
485 | 485 | /** |
486 | 486 | * Return the list of text fields that should be selected to read the |
487 | 487 | * revision text |
488 | - * @return array |
|
488 | + * @return string[] |
|
489 | 489 | */ |
490 | 490 | public static function selectTextFields() { |
491 | 491 | return [ |
@@ -496,7 +496,7 @@ discard block |
||
496 | 496 | |
497 | 497 | /** |
498 | 498 | * Return the list of page fields that should be selected from page table |
499 | - * @return array |
|
499 | + * @return string[] |
|
500 | 500 | */ |
501 | 501 | public static function selectPageFields() { |
502 | 502 | return [ |
@@ -511,7 +511,7 @@ discard block |
||
511 | 511 | |
512 | 512 | /** |
513 | 513 | * Return the list of user fields that should be selected from user table |
514 | - * @return array |
|
514 | + * @return string[] |
|
515 | 515 | */ |
516 | 516 | public static function selectUserFields() { |
517 | 517 | return [ 'user_name' ]; |
@@ -756,7 +756,7 @@ discard block |
||
756 | 756 | /** |
757 | 757 | * Returns the base36 sha1 of the text in this revision, or null if unknown. |
758 | 758 | * |
759 | - * @return string|null |
|
759 | + * @return string |
|
760 | 760 | */ |
761 | 761 | public function getSha1() { |
762 | 762 | return $this->mSha1; |
@@ -838,7 +838,7 @@ discard block |
||
838 | 838 | /** |
839 | 839 | * Fetch revision's user id without regard for the current user's permissions |
840 | 840 | * |
841 | - * @return string |
|
841 | + * @return integer |
|
842 | 842 | * @deprecated since 1.25, use getUser( Revision::RAW ) |
843 | 843 | */ |
844 | 844 | public function getRawUser() { |
@@ -1758,7 +1758,7 @@ discard block |
||
1758 | 1758 | * |
1759 | 1759 | * @param Title $title |
1760 | 1760 | * @param int $id |
1761 | - * @return string|bool False if not found |
|
1761 | + * @return string|false False if not found |
|
1762 | 1762 | */ |
1763 | 1763 | static function getTimestampFromId( $title, $id, $flags = 0 ) { |
1764 | 1764 | $db = ( $flags & self::READ_LATEST ) |
@@ -1814,7 +1814,7 @@ discard block |
||
1814 | 1814 | * @since 1.20 |
1815 | 1815 | * @deprecated since 1.24 |
1816 | 1816 | * |
1817 | - * @param IDatabase|int $db The Database to perform the check on. May be given as a |
|
1817 | + * @param integer $db The Database to perform the check on. May be given as a |
|
1818 | 1818 | * Database object or a database identifier usable with wfGetDB. |
1819 | 1819 | * @param int $pageId The ID of the page in question |
1820 | 1820 | * @param int $userId The ID of the user in question |
@@ -130,6 +130,11 @@ |
||
130 | 130 | } |
131 | 131 | } |
132 | 132 | |
133 | + /** |
|
134 | + * @param string $code |
|
135 | + * |
|
136 | + * @return string |
|
137 | + */ |
|
133 | 138 | protected function getFileName( $code ) { |
134 | 139 | if ( strval( $code ) === '' || strpos( $code, '/' ) !== false ) { |
135 | 140 | throw new MWException( __METHOD__ . ": Invalid language \"$code\"" ); |
@@ -691,7 +691,7 @@ |
||
691 | 691 | * |
692 | 692 | * @param string $code |
693 | 693 | * @param array $deps |
694 | - * @return array |
|
694 | + * @return string |
|
695 | 695 | */ |
696 | 696 | protected function readSourceFilesAndRegisterDeps( $code, &$deps ) { |
697 | 697 | global $IP; |
@@ -260,6 +260,7 @@ discard block |
||
260 | 260 | * Wrap the body text with language information and identifiable element |
261 | 261 | * |
262 | 262 | * @param Title $title |
263 | + * @param string $html |
|
263 | 264 | * @return string html |
264 | 265 | */ |
265 | 266 | protected function wrapHTML( $title, $html ) { |
@@ -766,6 +767,9 @@ discard block |
||
766 | 767 | 'primary' => true ]; |
767 | 768 | } |
768 | 769 | |
770 | + /** |
|
771 | + * @param string $name |
|
772 | + */ |
|
769 | 773 | function makeTalkUrlDetails( $name, $urlaction = '' ) { |
770 | 774 | $title = Title::newFromText( $name ); |
771 | 775 | if ( !is_object( $title ) ) { |
@@ -35,6 +35,9 @@ |
||
35 | 35 | */ |
36 | 36 | protected $mNavigationBar; |
37 | 37 | |
38 | + /** |
|
39 | + * @param string|null $target |
|
40 | + */ |
|
38 | 41 | function __construct( IContextSource $context, $target, $namespace = false ) { |
39 | 42 | parent::__construct( $context ); |
40 | 43 | $msgs = [ 'deletionlog', 'undeleteviewlink', 'diff' ]; |
@@ -32,6 +32,9 @@ |
||
32 | 32 | */ |
33 | 33 | protected $mForm; |
34 | 34 | |
35 | + /** |
|
36 | + * @param SpecialNewpages $form |
|
37 | + */ |
|
35 | 38 | function __construct( $form, FormOptions $opts ) { |
36 | 39 | parent::__construct( $form->getContext() ); |
37 | 40 | $this->mForm = $form; |
@@ -128,7 +128,7 @@ |
||
128 | 128 | /** |
129 | 129 | * Generates the subheading with links |
130 | 130 | * @param User $userObj User object for the target |
131 | - * @return string Appropriately-escaped HTML to be output literally |
|
131 | + * @return Message Appropriately-escaped HTML to be output literally |
|
132 | 132 | * @todo FIXME: Almost the same as contributionsSub in SpecialContributions.php. Could be combined. |
133 | 133 | */ |
134 | 134 | function getSubTitle( $userObj ) { |
@@ -39,6 +39,9 @@ discard block |
||
39 | 39 | parent::__construct( 'Newpages' ); |
40 | 40 | } |
41 | 41 | |
42 | + /** |
|
43 | + * @param string $par |
|
44 | + */ |
|
42 | 45 | protected function setup( $par ) { |
43 | 46 | // Options |
44 | 47 | $opts = new FormOptions(); |
@@ -457,6 +460,9 @@ discard block |
||
457 | 460 | } |
458 | 461 | } |
459 | 462 | |
463 | + /** |
|
464 | + * @return string |
|
465 | + */ |
|
460 | 466 | protected function feedItemAuthor( $row ) { |
461 | 467 | return isset( $row->rc_user_text ) ? $row->rc_user_text : ''; |
462 | 468 | } |