<?php
-
/**
- * Created on May 13, 2007
*
- * API for MediaWiki 1.8+
+ *
+ * Created on May 13, 2007
*
* Copyright © 2006 Yuri Astrakhan <Firstname><Lastname>@gmail.com
*
* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
*/
if ( !defined( 'MEDIAWIKI' ) ) {
$this->run();
}
+ public function getCacheMode( $params ) {
+ return 'public';
+ }
+
public function executeGenerator( $resultPageSet ) {
$this->run( $resultPageSet );
}
+ /**
+ * @param $resultPageSet ApiPageSet
+ * @return
+ */
private function run( $resultPageSet = null ) {
if ( $this->getPageSet()->getGoodTitleCount() == 0 ) {
return; // nothing to do
$this->addOption( 'ORDER BY', "cl_from, cl_to" );
}
- $db = $this->getDB();
$res = $this->select( __METHOD__ );
+ $count = 0;
if ( is_null( $resultPageSet ) ) {
- $count = 0;
foreach ( $res as $row ) {
if ( ++$count > $params['limit'] ) {
// We've reached the one extra which shows that
public function getDescription() {
return 'List all categories the page(s) belong to';
}
-
+
public function getPossibleErrors() {
return array_merge( parent::getPossibleErrors(), array(
array( 'show' ),