r95587 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r95586‎ | r95587 | r95588 >
Date:23:50, 26 August 2011
Author:johnduhart
Status:ok
Tags:
Comment:
API get* functions should be public
Modified paths:
  • /trunk/extensions/CentralAuth/ApiQueryGlobalUserInfo.php (modified) (history)
  • /trunk/extensions/EmailCapture/api/ApiEmailCapture.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/actions/ApiReview.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/actions/ApiReviewActivity.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/actions/ApiStabilize.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/reports/ApiFlagConfig.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/reports/ApiQueryConfiguredPages.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/reports/ApiQueryFlagged.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/reports/ApiQueryOldreviewedpages.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/reports/ApiQueryReviewedpages.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/api/reports/ApiQueryUnreviewedpages.php (modified) (history)
  • /trunk/extensions/Gadgets/ApiQueryGadgetCategories.php (modified) (history)
  • /trunk/extensions/Gadgets/ApiQueryGadgets.php (modified) (history)
  • /trunk/extensions/GlobalBlocking/ApiQueryGlobalBlocks.php (modified) (history)
  • /trunk/extensions/GlobalUsage/ApiQueryGlobalUsage.php (modified) (history)
  • /trunk/extensions/LiquidThreads/api/ApiFeedLQTThreads.php (modified) (history)
  • /trunk/extensions/LiquidThreads/api/ApiQueryLQTThreads.php (modified) (history)
  • /trunk/extensions/ProofreadPage/ApiQueryProofread.php (modified) (history)
  • /trunk/extensions/SiteMatrix/SiteMatrixApi.php (modified) (history)
  • /trunk/extensions/TitleBlacklist/api/ApiQueryTitleBlacklist.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CentralAuth/ApiQueryGlobalUserInfo.php
@@ -167,7 +167,7 @@
168168 return 'Show information about a global user.';
169169 }
170170
171 - protected function getExamples() {
 171+ public function getExamples() {
172172 return array(
173173 'api.php?action=query&meta=globaluserinfo',
174174 'api.php?action=query&meta=globaluserinfo&guiuser=Catrope&guiprop=groups|merged|unattached'
Index: trunk/extensions/FlaggedRevs/api/reports/ApiQueryConfiguredPages.php
@@ -194,7 +194,7 @@
195195 return 'Enumerate all pages that have custom review configurations';
196196 }
197197
198 - protected function getExamples() {
 198+ public function getExamples() {
199199 return array(
200200 'Show a list of pages with custom review configurations',
201201 ' api.php?action=query&list=configuredpages&cpnamespace=0',
Index: trunk/extensions/FlaggedRevs/api/reports/ApiFlagConfig.php
@@ -76,7 +76,7 @@
7777 );
7878 }
7979
80 - protected function getExamples() {
 80+ public function getExamples() {
8181 return 'api.php?action=flagconfig';
8282 }
8383
Index: trunk/extensions/FlaggedRevs/api/reports/ApiQueryFlagged.php
@@ -76,7 +76,7 @@
7777 );
7878 }
7979
80 - protected function getExamples() {
 80+ public function getExamples() {
8181 return array (
8282 'api.php?action=query&prop=info|flagged&titles=Main%20Page',
8383 'api.php?action=query&generator=allpages&gapfrom=K&prop=flagged'
Index: trunk/extensions/FlaggedRevs/api/reports/ApiQueryOldreviewedpages.php
@@ -232,7 +232,7 @@
233233 ) );
234234 }
235235
236 - protected function getExamples() {
 236+ public function getExamples() {
237237 return array(
238238 'Show a list of pages with pending unreviewed changes',
239239 ' api.php?action=query&list=oldreviewedpages&ornamespace=0',
Index: trunk/extensions/FlaggedRevs/api/reports/ApiQueryReviewedpages.php
@@ -190,7 +190,7 @@
191191 return 'Enumerates pages that have a reviewed version';
192192 }
193193
194 - protected function getExamples() {
 194+ public function getExamples() {
195195 return array (
196196 'Show a list of reviewed pages',
197197 ' api.php?action=query&list=reviewedpages&rpnamespace=0&rpfilterlevel=0',
Index: trunk/extensions/FlaggedRevs/api/reports/ApiQueryUnreviewedpages.php
@@ -174,7 +174,7 @@
175175 return 'Enumerates pages that have not been reviewed to a given quality level ("filterlevel")';
176176 }
177177
178 - protected function getExamples() {
 178+ public function getExamples() {
179179 return array (
180180 'Show a list of unreviewed pages',
181181 ' api.php?action=query&list=unreviewedpages&urnamespace=0&urfilterlevel=0',
Index: trunk/extensions/FlaggedRevs/api/actions/ApiReviewActivity.php
@@ -137,7 +137,7 @@
138138 return false;
139139 }
140140
141 - protected function getExamples() {
 141+ public function getExamples() {
142142 return 'api.php?action=reviewactivity&pageid=12345&reviewing=1';
143143 }
144144
Index: trunk/extensions/FlaggedRevs/api/actions/ApiReview.php
@@ -204,7 +204,7 @@
205205 return '';
206206 }
207207
208 - protected function getExamples() {
 208+ public function getExamples() {
209209 return 'api.php?action=review&revid=12345&token=123AB&flag_accuracy=1&comment=Ok';
210210 }
211211
Index: trunk/extensions/FlaggedRevs/api/actions/ApiStabilize.php
@@ -180,7 +180,7 @@
181181 ) );
182182 }
183183
184 - protected function getExamples() {
 184+ public function getExamples() {
185185 return 'api.php?action=stabilize&title=Test&default=stable&reason=Test&token=123ABC';
186186 }
187187
@@ -266,7 +266,7 @@
267267 ) );
268268 }
269269
270 - protected function getExamples() {
 270+ public function getExamples() {
271271 return 'api.php?action=stabilize&title=Test&protectlevel=none&reason=Test&token=123ABC';
272272 }
273273
Index: trunk/extensions/EmailCapture/api/ApiEmailCapture.php
@@ -97,7 +97,7 @@
9898 ) );
9999 }
100100
101 - protected function getExamples() {
 101+ public function getExamples() {
102102 return array(
103103 'api.php?action=emailcapture'
104104 );
Index: trunk/extensions/SiteMatrix/SiteMatrixApi.php
@@ -134,7 +134,7 @@
135135 }
136136 }
137137
138 - protected function getAllowedParams() {
 138+ public function getAllowedParams() {
139139 return array(
140140 'type' => array(
141141 ApiBase::PARAM_ISMULTI => true,
@@ -157,14 +157,14 @@
158158 );
159159 }
160160
161 - protected function getParamDescription() {
 161+ public function getParamDescription() {
162162 return array(
163163 'type' => 'Filter the Site Matrix by type',
164164 'state' => 'Filter the Site Matrix by wiki state',
165165 );
166166 }
167167
168 - protected function getDescription() {
 168+ public function getDescription() {
169169 return array(
170170 'Get Wikimedia sites list',
171171 'The code is either the unique identifier for specials else, for languages, the project code',
@@ -179,7 +179,7 @@
180180 );
181181 }
182182
183 - protected function getExamples() {
 183+ public function getExamples() {
184184 return array(
185185 'api.php?action=sitematrix',
186186 );
Index: trunk/extensions/GlobalUsage/ApiQueryGlobalUsage.php
@@ -151,7 +151,7 @@
152152 ) );
153153 }
154154
155 - protected function getExamples() {
 155+ public function getExamples() {
156156 return array (
157157 "Get usage of File:Example.jpg:",
158158 " api.php?action=query&prop=globalusage&titles=File:Example.jpg",
Index: trunk/extensions/GlobalBlocking/ApiQueryGlobalBlocks.php
@@ -220,7 +220,7 @@
221221 ) );
222222 }
223223
224 - protected function getExamples() {
 224+ public function getExamples() {
225225 return array ( 'api.php?action=query&list=globalblocks',
226226 'api.php?action=query&list=globalblocks&bgip=217.121.114.116'
227227 );
Index: trunk/extensions/LiquidThreads/api/ApiFeedLQTThreads.php
@@ -242,7 +242,7 @@
243243 return 'This module returns a feed of discussion threads';
244244 }
245245
246 - protected function getExamples() {
 246+ public function getExamples() {
247247 return array (
248248 'api.php?action=feedthreads',
249249 'api.php?action=feedthreads&type=replies&thread=Thread:Foo',
Index: trunk/extensions/LiquidThreads/api/ApiQueryLQTThreads.php
@@ -376,7 +376,7 @@
377377 return 'Show details of LiquidThreads threads.';
378378 }
379379
380 - protected function getExamples() {
 380+ public function getExamples() {
381381 return array(
382382 'api.php?action=query&list=threads&thpage=Talk:Main_Page',
383383 'api.php?action=query&list=threads&thid=1|2|3|4&thprop=id|subject|modified'
Index: trunk/extensions/ProofreadPage/ApiQueryProofread.php
@@ -91,7 +91,7 @@
9292 return 'Returns information about the current proofread status of the given pages.';
9393 }
9494
95 - protected function getExamples() {
 95+ public function getExamples() {
9696 return array(
9797 'api.php?action=query&generator=allpages&gapnamespace=104&prop=proofread'
9898 );
Index: trunk/extensions/Gadgets/ApiQueryGadgets.php
@@ -184,7 +184,7 @@
185185 );
186186 }
187187
188 - protected function getExamples() {
 188+ public function getExamples() {
189189 $params = $this->getAllowedParams();
190190 $allProps = implode( '|', $params['prop'][ApiBase::PARAM_TYPE] );
191191 return array(
Index: trunk/extensions/Gadgets/ApiQueryGadgetCategories.php
@@ -104,7 +104,7 @@
105105 );
106106 }
107107
108 - protected function getExamples() {
 108+ public function getExamples() {
109109 $params = $this->getAllowedParams();
110110 $allProps = implode( '|', $params['prop'][ApiBase::PARAM_TYPE] );
111111 return array(
Index: trunk/extensions/TitleBlacklist/api/ApiQueryTitleBlacklist.php
@@ -104,7 +104,7 @@
105105 return 'Validate an article title, filename, or username against the TitleBlacklist.';
106106 }
107107
108 - protected function getExamples() {
 108+ public function getExamples() {
109109 return array(
110110 'api.php?action=titleblacklist&tbtitle=Foo',
111111 'api.php?action=titleblacklist&tbtitle=Bar&tbaction=create',

Status & tagging log