Merge "Add DEFAULTSORT to search index field data"
[lhc/web/wiklou.git] / includes / content / WikiTextStructure.php
index 4cf2915..55c4ad5 100644 (file)
@@ -58,50 +58,6 @@ class WikiTextStructure {
                $this->parserOutput = $parserOutput;
        }
 
-       /**
-        * Get categories in the text.
-        * @return string[]
-        */
-       public function categories() {
-               $categories = [];
-               foreach ( array_keys( $this->parserOutput->getCategories() ) as $key ) {
-                       $categories[] = Category::newFromName( $key )->getTitle()->getText();
-               }
-               return $categories;
-       }
-
-       /**
-        * Get outgoing links.
-        * @return string[]
-        */
-       public function outgoingLinks() {
-               $outgoingLinks = [];
-               foreach ( $this->parserOutput->getLinks() as $linkedNamespace => $namespaceLinks ) {
-                       foreach ( array_keys( $namespaceLinks ) as $linkedDbKey ) {
-                               $outgoingLinks[] =
-                                       Title::makeTitle( $linkedNamespace, $linkedDbKey )->getPrefixedDBkey();
-                       }
-               }
-               return $outgoingLinks;
-       }
-
-       /**
-        * Get templates in the text.
-        * @return string[]
-        */
-       public function templates() {
-               $templates = [];
-               foreach ( $this->parserOutput->getTemplates() as $tNS => $templatesInNS ) {
-                       foreach ( array_keys( $templatesInNS ) as $tDbKey ) {
-                               $templateTitle = Title::makeTitleSafe( $tNS, $tDbKey );
-                               if ( $templateTitle && $templateTitle->exists() ) {
-                                       $templates[] = $templateTitle->getPrefixedText();
-                               }
-                       }
-               }
-               return $templates;
-       }
-
        /**
         * Get headings on the page.
         * @return string[]