From 4c81a710fa22cd8596f7f8586c489873b4068597 Mon Sep 17 00:00:00 2001 From: umherirrender Date: Sat, 15 Mar 2014 21:13:54 +0100 Subject: [PATCH] Fix formatting of some php docs php docs of functions should have newline in it and not in one line. Change-Id: If4a29aefb46a7f73d75593814e597fdb792d5470 --- includes/Category.php | 20 +++++++++++++++----- includes/FormOptions.php | 18 ++++++++++++++---- includes/HistoryBlob.php | 4 +++- includes/Skin.php | 4 +++- includes/WatchedItem.php | 16 +++++++++++++--- maintenance/purgeList.php | 8 ++++++-- tests/parser/ParserTestResult.php | 5 ++++- 7 files changed, 58 insertions(+), 17 deletions(-) diff --git a/includes/Category.php b/includes/Category.php index 126b8fee40..df5ad7dca5 100644 --- a/includes/Category.php +++ b/includes/Category.php @@ -195,27 +195,37 @@ class Category { return $cat; } - /** @return mixed DB key name, or false on failure */ + /** + * @return mixed DB key name, or false on failure + */ public function getName() { return $this->getX( 'mName' ); } - /** @return mixed Category ID, or false on failure */ + /** + * @return mixed Category ID, or false on failure + */ public function getID() { return $this->getX( 'mID' ); } - /** @return mixed Total number of member pages, or false on failure */ + /** + * @return mixed Total number of member pages, or false on failure + */ public function getPageCount() { return $this->getX( 'mPages' ); } - /** @return mixed Number of subcategories, or false on failure */ + /** + * @return mixed Number of subcategories, or false on failure + */ public function getSubcatCount() { return $this->getX( 'mSubcats' ); } - /** @return mixed Number of member files, or false on failure */ + /** + * @return mixed Number of member files, or false on failure + */ public function getFileCount() { return $this->getX( 'mFiles' ); } diff --git a/includes/FormOptions.php b/includes/FormOptions.php index cd6e207231..a8da67e5ef 100644 --- a/includes/FormOptions.php +++ b/includes/FormOptions.php @@ -373,22 +373,32 @@ class FormOptions implements ArrayAccess { * @see http://php.net/manual/en/class.arrayaccess.php */ /* @{ */ - /** Whether the option exists. */ + /** + * Whether the option exists. + * @return bool + */ public function offsetExists( $name ) { return isset( $this->options[$name] ); } - /** Retrieve an option value. */ + /** + * Retrieve an option value. + * @return mixed + */ public function offsetGet( $name ) { return $this->getValue( $name ); } - /** Set an option to given value. */ + /** + * Set an option to given value. + */ public function offsetSet( $name, $value ) { $this->setValue( $name, $value ); } - /** Delete the option. */ + /** + * Delete the option. + */ public function offsetUnset( $name ) { $this->delete( $name ); } diff --git a/includes/HistoryBlob.php b/includes/HistoryBlob.php index 9c50895b08..a3ed7009e5 100644 --- a/includes/HistoryBlob.php +++ b/includes/HistoryBlob.php @@ -78,7 +78,9 @@ class ConcatenatedGzipHistoryBlob implements HistoryBlob public $mMaxSize = 10000000; public $mMaxCount = 100; - /** Constructor */ + /** + * Constructor + */ public function __construct() { if ( !function_exists( 'gzdeflate' ) ) { throw new MWException( "Need zlib support to read or write this kind of history object (ConcatenatedGzipHistoryBlob)\n" ); diff --git a/includes/Skin.php b/includes/Skin.php index 6722ccabd1..5fa01ae954 100644 --- a/includes/Skin.php +++ b/includes/Skin.php @@ -182,7 +182,9 @@ abstract class Skin extends ContextSource { return $skin; } - /** @return string skin name */ + /** + * @return string skin name + */ public function getSkinName() { return $this->skinname; } diff --git a/includes/WatchedItem.php b/includes/WatchedItem.php index fe9784381e..a6e75162e3 100644 --- a/includes/WatchedItem.php +++ b/includes/WatchedItem.php @@ -70,16 +70,26 @@ class WatchedItem { return $this->mTitle; } - /** Helper to retrieve the title namespace */ + /** + * Helper to retrieve the title namespace + * @return int + */ protected function getTitleNs() { return $this->getTitle()->getNamespace(); } - /** Helper to retrieve the title DBkey */ + /** + * Helper to retrieve the title DBkey + * @return string + */ protected function getTitleDBkey() { return $this->getTitle()->getDBkey(); } - /** Helper to retrieve the user id */ + + /** + * Helper to retrieve the user id + * @return int + */ protected function getUserId() { return $this->mUser->getId(); } diff --git a/maintenance/purgeList.php b/maintenance/purgeList.php index 2f89520189..85a125f622 100644 --- a/maintenance/purgeList.php +++ b/maintenance/purgeList.php @@ -51,7 +51,9 @@ class PurgeList extends Maintenance { $this->output( "Done!\n" ); } - /** Purge URL coming from stdin */ + /** + * Purge URL coming from stdin + */ private function doPurge() { $stdin = $this->getStdin(); $urls = array(); @@ -78,7 +80,9 @@ class PurgeList extends Maintenance { $this->sendPurgeRequest( $urls ); } - /** Purge a namespace or all pages */ + /** + * Purge a namespace or all pages + */ private function purgeNamespace( $namespace = false ) { $dbr = wfGetDB( DB_SLAVE ); $startId = 0; diff --git a/tests/parser/ParserTestResult.php b/tests/parser/ParserTestResult.php index d9ad773d94..7b0fc4430e 100644 --- a/tests/parser/ParserTestResult.php +++ b/tests/parser/ParserTestResult.php @@ -35,7 +35,10 @@ class ParserTestResult { $this->description = $description; } - /** Whether the test passed */ + /** + * Whether the test passed + * @return bool + */ public function isSuccess() { return $this->expected === $this->actual; } -- 2.20.1