From: Sam Reed Date: Sat, 19 Feb 2011 22:08:26 +0000 (+0000) Subject: More function documentation X-Git-Tag: 1.31.0-rc.0~31872 X-Git-Url: http://git.cyclocoop.org/%22.%28%24lien.?a=commitdiff_plain;h=fb79ce2e32a01387b2b30320b3c6fe959bcc6189;p=lhc%2Fweb%2Fwiklou.git More function documentation --- diff --git a/includes/revisiondelete/RevisionDelete.php b/includes/revisiondelete/RevisionDelete.php index 5a2b043562..c331ec6162 100644 --- a/includes/revisiondelete/RevisionDelete.php +++ b/includes/revisiondelete/RevisionDelete.php @@ -292,6 +292,10 @@ class RevDel_FileList extends RevDel_List { var $authorNameField = 'oi_user_text'; var $storeBatch, $deleteBatch, $cleanupBatch; + /** + * @param $db DatabaseBase + * @return mixed + */ public function doQuery( $db ) { $archiveNames = array(); foreach( $this->ids as $timestamp ) { @@ -515,7 +519,11 @@ class RevDel_ArchivedFileList extends RevDel_FileList { var $dateField = 'fa_timestamp'; var $authorIdField = 'fa_user'; var $authorNameField = 'fa_user_text'; - + + /** + * @param $db DatabaseBase + * @return mixed + */ public function doQuery( $db ) { $ids = array_map( 'intval', $this->ids ); return $db->select( 'filearchive', '*', @@ -593,6 +601,10 @@ class RevDel_LogList extends RevDel_List { var $authorIdField = 'log_user'; var $authorNameField = 'log_user_text'; + /** + * @param $db DatabaseBase + * @return mixed + */ public function doQuery( $db ) { $ids = array_map( 'intval', $this->ids ); return $db->select( 'logging', '*', diff --git a/includes/revisiondelete/RevisionDeleter.php b/includes/revisiondelete/RevisionDeleter.php index 5caba11e71..2450bb8f36 100644 --- a/includes/revisiondelete/RevisionDeleter.php +++ b/includes/revisiondelete/RevisionDeleter.php @@ -125,10 +125,17 @@ class RevisionDeleter { return null; } } - - // Checks if a revision still exists in the revision table. - // If it doesn't, returns the corresponding ar_timestamp field - // so that this key can be used instead. + + /** + * Checks if a revision still exists in the revision table. + * If it doesn't, returns the corresponding ar_timestamp field + * so that this key can be used instead. + * + * @static + * @param $title Title + * @param $revid + * @return bool|mixed + */ public static function checkRevisionExistence( $title, $revid ) { $dbr = wfGetDB( DB_SLAVE ); $exists = $dbr->selectField( 'revision', '1', @@ -145,8 +152,17 @@ class RevisionDeleter { return $timestamp; } - - // Creates utility links for log entries. + + /** + * Creates utility links for log entries. + * + * @static + * @param $title Title + * @param $paramArray Array + * @param $skin Skin + * @param $messages + * @return String + */ public static function getLogLinks( $title, $paramArray, $skin, $messages ) { global $wgLang; @@ -215,7 +231,7 @@ class RevisionDeleter { } // View/modify link... - if ( count($undeletedRevisions) ) { + if ( count( $undeletedRevisions ) ) { // FIXME THIS IS A HORRIBLE HORRIBLE HACK AND SHOULD DIE // It's not possible to pass a list of both deleted and // undeleted revisions to SpecialRevisionDelete, so we're @@ -229,7 +245,7 @@ class RevisionDeleter { array( 'target' => $title->getPrefixedText(), 'type' => $originalKey, - 'ids' => implode(',', $undeletedRevisions), + 'ids' => implode( ',', $undeletedRevisions ), ), array( 'known', 'noclasses' ) );