@@ -293,6 +293,9 @@ discard block |
||
293 | 293 | ); |
294 | 294 | } |
295 | 295 | |
296 | + /** |
|
297 | + * @param FormOptions $opts |
|
298 | + */ |
|
296 | 299 | protected function runMainQueryHook( &$tables, &$fields, &$conds, &$query_options, |
297 | 300 | &$join_conds, $opts |
298 | 301 | ) { |
@@ -516,6 +519,9 @@ discard block |
||
516 | 519 | $this->setBottomText( $opts ); |
517 | 520 | } |
518 | 521 | |
522 | + /** |
|
523 | + * @param FormOptions $options |
|
524 | + */ |
|
519 | 525 | function cutoffselector( $options ) { |
520 | 526 | // Cast everything to strings immediately, so that we know all of the values have the same |
521 | 527 | // precision, and can be compared with '==='. 2/24 has a few more decimal places than its |
@@ -625,7 +631,7 @@ discard block |
||
625 | 631 | * Count the number of items on a user's watchlist |
626 | 632 | * |
627 | 633 | * @param IDatabase $dbr A database connection |
628 | - * @return int |
|
634 | + * @return double |
|
629 | 635 | */ |
630 | 636 | protected function countItems( $dbr ) { |
631 | 637 | # Fetch the raw count |
@@ -303,10 +303,17 @@ discard block |
||
303 | 303 | } |
304 | 304 | } |
305 | 305 | |
306 | + /** |
|
307 | + * @param integer $level |
|
308 | + */ |
|
306 | 309 | protected function listStart( $level ) { |
307 | 310 | return Xml::openElement( 'ul', ( $level ? array() : array( 'id' => 'mw-whatlinkshere-list' ) ) ); |
308 | 311 | } |
309 | 312 | |
313 | + /** |
|
314 | + * @param Title $nt |
|
315 | + * @param Title $target |
|
316 | + */ |
|
310 | 317 | protected function listItem( $row, $nt, $target, $notClose = false ) { |
311 | 318 | $dirmark = $this->getLanguage()->getDirMark(); |
312 | 319 | |
@@ -405,6 +412,9 @@ discard block |
||
405 | 412 | return $this->getLanguage()->pipeList( $links ); |
406 | 413 | } |
407 | 414 | |
415 | + /** |
|
416 | + * @param string $text |
|
417 | + */ |
|
408 | 418 | function makeSelfLink( $text, $query ) { |
409 | 419 | return Linker::linkKnown( |
410 | 420 | $this->selfTitle, |
@@ -414,6 +424,9 @@ discard block |
||
414 | 424 | ); |
415 | 425 | } |
416 | 426 | |
427 | + /** |
|
428 | + * @param integer $prevId |
|
429 | + */ |
|
417 | 430 | function getPrevNext( $prevId, $nextId ) { |
418 | 431 | $currentLimit = $this->opts->getValue( 'limit' ); |
419 | 432 | $prev = $this->msg( 'whatlinkshere-prev' )->numParams( $currentLimit )->escaped(); |
@@ -147,7 +147,7 @@ discard block |
||
147 | 147 | * Add an error, do not set fatal flag |
148 | 148 | * This can be used for non-fatal errors |
149 | 149 | * |
150 | - * @param string|Message $message Message name or object |
|
150 | + * @param string|false $message Message name or object |
|
151 | 151 | */ |
152 | 152 | public function error( $message /*, parameters... */ ) { |
153 | 153 | call_user_func_array( array( $this->sv, 'error' ), func_get_args() ); |
@@ -400,7 +400,7 @@ discard block |
||
400 | 400 | /** |
401 | 401 | * Returns true if the specified message is present as a warning or error |
402 | 402 | * |
403 | - * @param string|Message $message Message key or object to search for |
|
403 | + * @param string $message Message key or object to search for |
|
404 | 404 | * |
405 | 405 | * @return bool |
406 | 406 | */ |
@@ -415,8 +415,8 @@ discard block |
||
415 | 415 | * Note, due to the lack of tools for comparing Message objects, this |
416 | 416 | * function will not work when using a Message object as the search parameter. |
417 | 417 | * |
418 | - * @param Message|string $source Message key or object to search for |
|
419 | - * @param Message|string $dest Replacement message key or object |
|
418 | + * @param string $source Message key or object to search for |
|
419 | + * @param string $dest Replacement message key or object |
|
420 | 420 | * @return bool Return true if the replacement was done, false otherwise. |
421 | 421 | */ |
422 | 422 | public function replaceMessage( $source, $dest ) { |
@@ -161,7 +161,7 @@ discard block |
||
161 | 161 | * Avoid usage of this singleton by using TitleValue |
162 | 162 | * and the associated services when possible. |
163 | 163 | * |
164 | - * @return TitleParser |
|
164 | + * @return string |
|
165 | 165 | */ |
166 | 166 | private static function getTitleParser() { |
167 | 167 | global $wgContLang, $wgLocalInterwikis; |
@@ -370,7 +370,7 @@ discard block |
||
370 | 370 | * objects or LinkCache entries. Uses $wgContentHandlerUseDB to determine |
371 | 371 | * whether to include page_content_model. |
372 | 372 | * |
373 | - * @return array |
|
373 | + * @return string[] |
|
374 | 374 | */ |
375 | 375 | protected static function getSelectFields() { |
376 | 376 | global $wgContentHandlerUseDB; |
@@ -610,7 +610,7 @@ discard block |
||
610 | 610 | * Get the prefixed DB key associated with an ID |
611 | 611 | * |
612 | 612 | * @param int $id The page_id of the article |
613 | - * @return Title|null An object representing the article, or null if no such article was found |
|
613 | + * @return null|string An object representing the article, or null if no such article was found |
|
614 | 614 | */ |
615 | 615 | public static function nameOf( $id ) { |
616 | 616 | $dbr = wfGetDB( DB_SLAVE ); |
@@ -896,7 +896,7 @@ discard block |
||
896 | 896 | * (e.g. TitleValues cannot represent page-local links that have a |
897 | 897 | * fragment but no title text). |
898 | 898 | * |
899 | - * @return TitleValue|null |
|
899 | + * @return TitleValue |
|
900 | 900 | */ |
901 | 901 | public function getTitleValue() { |
902 | 902 | if ( $this->mTitleValue === null ) { |
@@ -1127,7 +1127,6 @@ discard block |
||
1127 | 1127 | /** |
1128 | 1128 | * Returns true if the title is inside one of the specified namespaces. |
1129 | 1129 | * |
1130 | - * @param int $namespaces,... The namespaces to check for |
|
1131 | 1130 | * @return bool |
1132 | 1131 | * @since 1.19 |
1133 | 1132 | */ |
@@ -1916,7 +1915,7 @@ discard block |
||
1916 | 1915 | * - quick : does cheap permission checks from slaves (usable for GUI creation) |
1917 | 1916 | * - full : does cheap and expensive checks possibly from a slave |
1918 | 1917 | * - secure : does cheap and expensive checks, using the master as needed |
1919 | - * @param array $ignoreErrors Array of Strings Set this to a list of message keys |
|
1918 | + * @param string[] $ignoreErrors Array of Strings Set this to a list of message keys |
|
1920 | 1919 | * whose corresponding errors may be ignored. |
1921 | 1920 | * @return array Array of arrays of the arguments to wfMessage to explain permissions problems. |
1922 | 1921 | */ |
@@ -2017,7 +2016,7 @@ discard block |
||
2017 | 2016 | * Add the resulting error code to the errors array |
2018 | 2017 | * |
2019 | 2018 | * @param array $errors List of current errors |
2020 | - * @param array $result Result of errors |
|
2019 | + * @param string $result Result of errors |
|
2021 | 2020 | * |
2022 | 2021 | * @return array List of errors |
2023 | 2022 | */ |
@@ -2408,7 +2407,7 @@ discard block |
||
2408 | 2407 | * |
2409 | 2408 | * @param string $action The action to check |
2410 | 2409 | * @param bool $short Short circuit on first error |
2411 | - * @return array List of errors |
|
2410 | + * @return string[] List of errors |
|
2412 | 2411 | */ |
2413 | 2412 | private function missingPermissionError( $action, $short ) { |
2414 | 2413 | // We avoid expensive display logic for quickUserCan's and such |
@@ -3932,7 +3931,7 @@ discard block |
||
3932 | 3931 | * |
3933 | 3932 | * @param int $revId Revision ID. Get the revision that was before this one. |
3934 | 3933 | * @param int $flags Title::GAID_FOR_UPDATE |
3935 | - * @return int|bool Old revision ID, or false if none exists |
|
3934 | + * @return integer Old revision ID, or false if none exists |
|
3936 | 3935 | */ |
3937 | 3936 | public function getPreviousRevisionID( $revId, $flags = 0 ) { |
3938 | 3937 | $db = ( $flags & self::GAID_FOR_UPDATE ) ? wfGetDB( DB_MASTER ) : wfGetDB( DB_SLAVE ); |
@@ -4072,8 +4071,8 @@ discard block |
||
4072 | 4071 | * Get the number of revisions between the given revision. |
4073 | 4072 | * Used for diffs and other things that really need it. |
4074 | 4073 | * |
4075 | - * @param int|Revision $old Old revision or rev ID (first before range) |
|
4076 | - * @param int|Revision $new New revision or rev ID (first after range) |
|
4074 | + * @param Revision $old Old revision or rev ID (first before range) |
|
4075 | + * @param Revision $new New revision or rev ID (first after range) |
|
4077 | 4076 | * @param int|null $max Limit of Revisions to count, will be incremented to detect truncations |
4078 | 4077 | * @return int Number of revisions between these revisions. |
4079 | 4078 | */ |
@@ -4185,9 +4184,9 @@ discard block |
||
4185 | 4184 | * Used for diffs and other things that really need it. |
4186 | 4185 | * |
4187 | 4186 | * @param int|Revision $old Old revision or rev ID (first before range by default) |
4188 | - * @param int|Revision $new New revision or rev ID (first after range by default) |
|
4187 | + * @param Revision $new New revision or rev ID (first after range by default) |
|
4189 | 4188 | * @param int $limit Maximum number of authors |
4190 | - * @param string|array $options (Optional): Single option, or an array of options: |
|
4189 | + * @param string $options (Optional): Single option, or an array of options: |
|
4191 | 4190 | * 'include_old' Include $old in the range; $new is excluded. |
4192 | 4191 | * 'include_new' Include $new in the range; $old is excluded. |
4193 | 4192 | * 'include_both' Include both $old and $new in the range. |
@@ -4343,7 +4342,7 @@ discard block |
||
4343 | 4342 | /** |
4344 | 4343 | * Get the default message text or false if the message doesn't exist |
4345 | 4344 | * |
4346 | - * @return string|bool |
|
4345 | + * @return false|string |
|
4347 | 4346 | */ |
4348 | 4347 | public function getDefaultMessageText() { |
4349 | 4348 | global $wgContLang; |
@@ -4747,7 +4746,7 @@ discard block |
||
4747 | 4746 | } |
4748 | 4747 | |
4749 | 4748 | /** |
4750 | - * @return array |
|
4749 | + * @return string[] |
|
4751 | 4750 | */ |
4752 | 4751 | public function __sleep() { |
4753 | 4752 | return array( |
@@ -32,6 +32,9 @@ |
||
32 | 32 | |
33 | 33 | public $current; |
34 | 34 | |
35 | + /** |
|
36 | + * @param ResultWrapper $res |
|
37 | + */ |
|
35 | 38 | function __construct( $res ) { |
36 | 39 | $this->res = $res; |
37 | 40 | $this->key = 0; |
@@ -265,7 +265,7 @@ discard block |
||
265 | 265 | |
266 | 266 | /** |
267 | 267 | * @param string $srcPath The source path |
268 | - * @return string|bool The real path if it was a virtual URL Returns false on failure |
|
268 | + * @return string|false The real path if it was a virtual URL Returns false on failure |
|
269 | 269 | */ |
270 | 270 | function getRealPath( $srcPath ) { |
271 | 271 | $repo = RepoGroup::singleton()->getLocalRepo(); |
@@ -1513,7 +1513,6 @@ discard block |
||
1513 | 1513 | * Check a block of CSS or CSS fragment for anything that looks like |
1514 | 1514 | * it is bringing in remote code. |
1515 | 1515 | * @param string $value a string of CSS |
1516 | - * @param bool $propOnly only check css properties (start regex with :) |
|
1517 | 1516 | * @return bool true if the CSS contains an illegal string, false if otherwise |
1518 | 1517 | */ |
1519 | 1518 | private static function checkCssFragment( $value ) { |
@@ -1887,7 +1886,7 @@ discard block |
||
1887 | 1886 | * format, presumably. |
1888 | 1887 | * |
1889 | 1888 | * @param ApiResult $result |
1890 | - * @return array Image info |
|
1889 | + * @return User Image info |
|
1891 | 1890 | */ |
1892 | 1891 | public function getImageInfo( $result ) { |
1893 | 1892 | $file = $this->getLocalFile(); |
@@ -333,6 +333,9 @@ |
||
333 | 333 | return $storeStatus; |
334 | 334 | } |
335 | 335 | |
336 | + /** |
|
337 | + * @param integer $index |
|
338 | + */ |
|
336 | 339 | private function getChunkFileKey( $index = null ) { |
337 | 340 | if ( $index === null ) { |
338 | 341 | $index = $this->getChunkIndex(); |
@@ -40,7 +40,7 @@ |
||
40 | 40 | private $repo; |
41 | 41 | |
42 | 42 | /** |
43 | - * @param User|bool $user Default: false |
|
43 | + * @param User $user Default: false |
|
44 | 44 | * @param UploadStash|bool $stash Default: false |
45 | 45 | * @param FileRepo|bool $repo Default: false |
46 | 46 | */ |
@@ -170,7 +170,7 @@ discard block |
||
170 | 170 | * Getter for file metadata. |
171 | 171 | * |
172 | 172 | * @param string $key Key under which file information is stored |
173 | - * @return array |
|
173 | + * @return string |
|
174 | 174 | */ |
175 | 175 | public function getMetadata( $key ) { |
176 | 176 | $this->getFile( $key ); |
@@ -200,7 +200,7 @@ discard block |
||
200 | 200 | * @throws UploadStashBadPathException |
201 | 201 | * @throws UploadStashFileException |
202 | 202 | * @throws UploadStashNotLoggedInException |
203 | - * @return UploadStashFile|null File, or null on failure |
|
203 | + * @return UploadStashFile File, or null on failure |
|
204 | 204 | */ |
205 | 205 | public function stashFile( $path, $sourceType = null ) { |
206 | 206 | if ( !is_file( $path ) ) { |