From 4277fc9f203d1f65d45b49dfcf914448166b0799 Mon Sep 17 00:00:00 2001 From: Reedy Date: Mon, 2 Sep 2013 16:49:22 +0100 Subject: Add method parameter type documentation Cleanup returns Change-Id: Ic559c86883e5ead549fa5827853c7ca7a42b79ca --- maintenance/cleanupTable.inc | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'maintenance/cleanupTable.inc') diff --git a/maintenance/cleanupTable.inc b/maintenance/cleanupTable.inc index 410a55cb23b8..48bb53ebd155 100644 --- a/maintenance/cleanupTable.inc +++ b/maintenance/cleanupTable.inc @@ -41,6 +41,8 @@ class TableCleanup extends Maintenance { public $batchSize = 100; public $reportInterval = 100; + protected $processed, $updated, $count, $startTime, $table; + public function __construct() { parent::__construct(); $this->addOption( 'dry-run', 'Perform a dry run' ); @@ -66,6 +68,9 @@ class TableCleanup extends Maintenance { $this->table = $table; } + /** + * @param int $updated + */ protected function progress( $updated ) { $this->updated += $updated; $this->processed++; @@ -96,6 +101,10 @@ class TableCleanup extends Maintenance { flush(); } + /** + * @param array $params + * @throws MWException + */ public function runTable( $params ) { $dbr = wfGetDB( DB_SLAVE ); @@ -156,6 +165,10 @@ class TableCleanup extends Maintenance { $this->output( "Finished $table... $this->updated of $this->processed rows updated\n" ); } + /** + * @param array $matches + * @return string + */ protected function hexChar( $matches ) { return sprintf( "\\x%02x", ord( $matches[1] ) ); } -- cgit v1.2.3