r91132 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r91131‎ | r91132 | r91133 >
Date:22:38, 29 June 2011
Author:reedy
Status:deferred
Tags:
Comment:
Add example placeholders

Add some more parameter descriptions
Modified paths:
  • /trunk/extensions/MetricsReporting/ApiAnalyticsBase.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/ComScoreReachPercentageMetric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/ComScoreUniqueVisitorMetric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/DumpActiveEditors100Metric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/DumpActiveEditors5Metric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/DumpArticleCountMetric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/DumpBinaryCountMetric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/DumpEditsMetric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/DumpNewRegisteredEditorsMetric.php (modified) (history)
  • /trunk/extensions/MetricsReporting/metrics/SquidPageViewsMetric.php (modified) (history)

Diff [purge]

Index: trunk/extensions/MetricsReporting/ApiAnalyticsBase.php
@@ -39,7 +39,10 @@
4040
4141 public function getAllowedParams() {
4242 $params = array(
43 - 'months' => 'string',
 43+ 'months' => array(
 44+ ApiBase::PARAM_TYPE => 'string',
 45+ ApiBase::PARAM_REQUIRED => true,
 46+ ),
4447 'normalized' => 'bool',
4548 'data' => array(
4649 ApiBase::PARAM_DFLT => 'timeseries',
@@ -397,9 +400,9 @@
398401 'selectwebproperties' => '',
399402 'selectprojects' => '',
400403 'selectwikis' => '',
401 - 'selecteditors' => '',
402 - 'selectedits' => '',
403 - 'selectplatform' => '',
 404+ 'selecteditors' => 'a for anonymous, r for registered, b for bot',
 405+ 'selectedits' => 'm for manual, b for bot-induced',
 406+ 'selectplatform' => 'm for mobile, n for non-mobile',
404407 );
405408 }
406409
Index: trunk/extensions/MetricsReporting/metrics/DumpNewRegisteredEditorsMetric.php
@@ -13,6 +13,12 @@
1414 return 'All registered editors that in a certain month for the first time crossed the threshold of 10 edits since signing up';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/ComScoreReachPercentageMetric.php
@@ -13,6 +13,12 @@
1414 return 'Percentage of total unique visitors to any web property which also visited a Wikimedia wiki';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/DumpActiveEditors100Metric.php
@@ -13,6 +13,12 @@
1414 return 'All registered editors that made 100 or more edits in a certain month';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/DumpEditsMetric.php
@@ -13,6 +13,12 @@
1414 return 'All edits on articles (as defined by dumparticlecount)';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/DumpActiveEditors5Metric.php
@@ -13,6 +13,12 @@
1414 return 'All registered editors that made 5 or more edits in a certain month';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/SquidPageViewsMetric.php
@@ -14,6 +14,12 @@
1515 );
1616 }
1717
 18+ protected function getExamples() {
 19+ return array(
 20+ 'api.php?action=analytics&metric=',
 21+ );
 22+ }
 23+
1824 public function getVersion() {
1925 return __CLASS__ . ': $Id$';
2026 }
Index: trunk/extensions/MetricsReporting/metrics/ComScoreUniqueVisitorMetric.php
@@ -13,6 +13,12 @@
1414 return 'Unique persons that visited one of the Wikimedia wikis at least once in a certain month';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/DumpArticleCountMetric.php
@@ -13,6 +13,12 @@
1414 return 'All namespace 0 pages which contain an internal link minus redirect pages (for some projects extra namespaces qualify)';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }
Index: trunk/extensions/MetricsReporting/metrics/DumpBinaryCountMetric.php
@@ -13,6 +13,12 @@
1414 return 'All binary files (nearly all of which are multimedia files) available for download/article inclusion on a wiki';
1515 }
1616
 17+ protected function getExamples() {
 18+ return array(
 19+ 'api.php?action=analytics&metric=',
 20+ );
 21+ }
 22+
1723 public function getVersion() {
1824 return __CLASS__ . ': $Id$';
1925 }

Status & tagging log