From: Alexandre Emsenhuber Date: Sat, 23 Jan 2010 20:07:17 +0000 (+0000) Subject: * Document a bit X-Git-Tag: 1.31.0-rc.0~38136 X-Git-Url: http://git.cyclocoop.org/url?a=commitdiff_plain;h=85e870b711e1dda41aa3f8eacff398d2337e8c13;p=lhc%2Fweb%2Fwiklou.git * Document a bit * Fix some doxygen warnings * Use spaces instead of tabs in the middle of lines --- diff --git a/includes/ImageQueryPage.php b/includes/ImageQueryPage.php index 3ab0b858a5..180201a2f2 100644 --- a/includes/ImageQueryPage.php +++ b/includes/ImageQueryPage.php @@ -13,12 +13,12 @@ class ImageQueryPage extends QueryPage { * Format and output report results using the given information plus * OutputPage * - * @param OutputPage $out OutputPage to print to - * @param Skin $skin User skin to use - * @param Database $dbr Database (read) connection to use - * @param int $res Result pointer - * @param int $num Number of available result rows - * @param int $offset Paging offset + * @param $out OutputPage to print to + * @param $skin Skin: user skin to use + * @param $dbr Database (read) connection to use + * @param $res Integer: result pointer + * @param $num Integer: number of available result rows + * @param $offset Integer: paging offset */ protected function outputResults( $out, $skin, $dbr, $res, $num, $offset ) { if( $num > 0 ) { @@ -41,7 +41,7 @@ class ImageQueryPage extends QueryPage { /** * Prepare an image object given a result row * - * @param object $row Result row + * @param $row Object: result row * @return Image */ private function prepareImage( $row ) { @@ -55,8 +55,8 @@ class ImageQueryPage extends QueryPage { /** * Get additional HTML to be shown in a results' cell * - * @param object $row Result row - * @return string + * @param $row Object: result row + * @return String */ protected function getCellHtml( $row ) { return ''; diff --git a/includes/QueryPage.php b/includes/QueryPage.php index a50c882ee1..827264be8e 100644 --- a/includes/QueryPage.php +++ b/includes/QueryPage.php @@ -22,36 +22,36 @@ $wgQueryPages = array( array( 'DisambiguationsPage', 'Disambiguations' ), array( 'DoubleRedirectsPage', 'DoubleRedirects' ), array( 'LinkSearchPage', 'LinkSearch' ), - array( 'ListredirectsPage', 'Listredirects' ), + array( 'ListredirectsPage', 'Listredirects' ), array( 'LonelyPagesPage', 'Lonelypages' ), array( 'LongPagesPage', 'Longpages' ), array( 'MostcategoriesPage', 'Mostcategories' ), array( 'MostimagesPage', 'Mostimages' ), array( 'MostlinkedCategoriesPage', 'Mostlinkedcategories' ), - array( 'SpecialMostlinkedtemplates', 'Mostlinkedtemplates' ), + array( 'SpecialMostlinkedtemplates', 'Mostlinkedtemplates' ), array( 'MostlinkedPage', 'Mostlinked' ), array( 'MostrevisionsPage', 'Mostrevisions' ), array( 'FewestrevisionsPage', 'Fewestrevisions' ), array( 'ShortPagesPage', 'Shortpages' ), array( 'UncategorizedCategoriesPage', 'Uncategorizedcategories' ), array( 'UncategorizedPagesPage', 'Uncategorizedpages' ), - array( 'UncategorizedImagesPage', 'Uncategorizedimages' ), - array( 'UncategorizedTemplatesPage', 'Uncategorizedtemplates' ), + array( 'UncategorizedImagesPage', 'Uncategorizedimages' ), + array( 'UncategorizedTemplatesPage', 'Uncategorizedtemplates' ), array( 'UnusedCategoriesPage', 'Unusedcategories' ), array( 'UnusedimagesPage', 'Unusedimages' ), array( 'WantedCategoriesPage', 'Wantedcategories' ), array( 'WantedFilesPage', 'Wantedfiles' ), array( 'WantedPagesPage', 'Wantedpages' ), - array( 'WantedTemplatesPage', 'Wantedtemplates' ), + array( 'WantedTemplatesPage', 'Wantedtemplates' ), array( 'UnwatchedPagesPage', 'Unwatchedpages' ), - array( 'UnusedtemplatesPage', 'Unusedtemplates' ), - array( 'WithoutInterwikiPage', 'Withoutinterwiki' ), + array( 'UnusedtemplatesPage', 'Unusedtemplates' ), + array( 'WithoutInterwikiPage', 'Withoutinterwiki' ), ); wfRunHooks( 'wgQueryPages', array( &$wgQueryPages ) ); global $wgDisableCounters; if ( !$wgDisableCounters ) - $wgQueryPages[] = array( 'PopularPagesPage', 'Popularpages' ); + $wgQueryPages[] = array( 'PopularPagesPage', 'Popularpages' ); /** @@ -79,7 +79,7 @@ class QueryPage { /** * A mutator for $this->listoutput; * - * @param bool $bool + * @param $bool Boolean */ function setListoutput( $bool ) { $this->listoutput = $bool; @@ -89,6 +89,8 @@ class QueryPage { * Subclasses return their name here. Make sure the name is also * specified in SpecialPage.php and in Language.php as a language message * param. + * + * @return String */ function getName() { return ''; @@ -124,6 +126,8 @@ class QueryPage { /** * Override to sort by increasing values + * + * @return Boolean */ function sortDescending() { return true; @@ -138,8 +142,10 @@ class QueryPage { * Is this query expensive (for some definition of expensive)? Then we * don't let it run in miser mode. $wgDisableQueryPages causes all query * pages to be declared expensive. Some query pages are always expensive. + * + * @return Boolean */ - function isExpensive( ) { + function isExpensive() { global $wgDisableQueryPages; return $wgDisableQueryPages; } @@ -148,7 +154,7 @@ class QueryPage { * Whether or not the output of the page in question is retrived from * the database cache. * - * @return bool + * @return Boolean */ function isCached() { global $wgMiserMode; @@ -158,6 +164,8 @@ class QueryPage { /** * Sometime we dont want to build rss / atom feeds. + * + * @return Boolean */ function isSyndicated() { return true; @@ -168,6 +176,9 @@ class QueryPage { * skin; you can use it for making links. The result is a single row of * result data. You should be able to grab SQL results off of it. * If the function return "false", the line output will be skipped. + * + * @param $skin Skin object + * @param $result Object: database row */ function formatResult( $skin, $result ) { return ''; @@ -175,8 +186,10 @@ class QueryPage { /** * The content returned by this function will be output before any result + * + * @return String */ - function getPageHeader( ) { + function getPageHeader() { return ''; } @@ -184,7 +197,8 @@ class QueryPage { * If using extra form wheely-dealies, return a set of parameters here * as an associative array. They will be encoded and added to the paging * links (prev/next/lengths). - * @return array + * + * @return Array */ function linkParameters() { return array(); @@ -196,12 +210,15 @@ class QueryPage { * Setting this to return true, will call one more time wfFormatResult to * be sure that the very last result is formatted and shown. */ - function tryLastResult( ) { + function tryLastResult() { return false; } /** * Clear the cache and save new results + * + * @param $limit Integer: limit for SQL statement + * @param $ignoreErrors Boolean: whether to ignore database errors */ function recache( $limit, $ignoreErrors = true ) { $fname = get_class( $this ) . '::recache'; @@ -376,12 +393,12 @@ class QueryPage { * Format and output report results using the given information plus * OutputPage * - * @param OutputPage $out OutputPage to print to - * @param Skin $skin User skin to use - * @param Database $dbr Database (read) connection to use - * @param int $res Result pointer - * @param int $num Number of available result rows - * @param int $offset Paging offset + * @param $out OutputPage to print to + * @param $skin Skin: user skin to use + * @param $dbr Database (read) connection to use + * @param $res Integer: result pointer + * @param $num Integer: number of available result rows + * @param $offset Integer: paging offset */ protected function outputResults( $out, $skin, $dbr, $res, $num, $offset ) { global $wgContLang;