APIQueryInfo: Allow fetching the canonical url of a page
[lhc/web/wiklou.git] / includes / api / ApiQueryAllLinks.php
index 9324acb..903dee4 100644 (file)
@@ -39,7 +39,7 @@ class ApiQueryAllLinks extends ApiQueryGeneratorBase {
        private $useIndex = null;
        private $props = array(), $propHelp = array();
 
-       public function __construct( $query, $moduleName ) {
+       public function __construct( ApiQuery $query, $moduleName ) {
                switch ( $moduleName ) {
                        case 'alllinks':
                                $prefix = 'al';
@@ -334,34 +334,10 @@ class ApiQueryAllLinks extends ApiQueryGeneratorBase {
                return $paramDescription;
        }
 
-       public function getResultProperties() {
-               return array(
-                       'ids' => array(
-                               'fromid' => 'integer'
-                       ),
-                       'title' => array(
-                               'ns' => 'namespace',
-                               'title' => 'string'
-                       )
-               );
-       }
-
        public function getDescription() {
                return $this->description;
        }
 
-       public function getPossibleErrors() {
-               $m = $this->getModuleName();
-               $what = $this->descriptionWhat;
-
-               return array_merge( parent::getPossibleErrors(), array(
-                       array(
-                               'code' => 'params',
-                               'info' => "{$m} cannot return corresponding page ids in unique {$what}s mode"
-                       ),
-               ) );
-       }
-
        public function getExamples() {
                $p = $this->getModulePrefix();
                $name = $this->getModuleName();