Merge "Make users API cache mode public if blockinfo is not queried"
[lhc/web/wiklou.git] / includes / search / SearchOracle.php
index e14de2c..93427d1 100644 (file)
@@ -62,7 +62,7 @@ class SearchOracle extends SearchDatabase {
        /**
         * Perform a full text search query and return a result set.
         *
-        * @param string $term raw search term
+        * @param string $term Raw search term
         * @return SqlSearchResultSet
         */
        function searchText( $term ) {
@@ -77,7 +77,7 @@ class SearchOracle extends SearchDatabase {
        /**
         * Perform a title-only search query and return a result set.
         *
-        * @param string $term raw search term
+        * @param string $term Raw search term
         * @return SqlSearchResultSet
         */
        function searchTitle( $term ) {
@@ -86,12 +86,12 @@ class SearchOracle extends SearchDatabase {
                }
 
                $resultSet = $this->db->resultObject( $this->db->query( $this->getQuery( $this->filter( $term ), false ) ) );
-               return new MySQLSearchResultSet( $resultSet, $this->searchTerms );
+               return new SqlSearchResultSet( $resultSet, $this->searchTerms );
        }
 
        /**
         * Return a partial WHERE clause to limit the search to the given namespaces
-        * @return String
+        * @return string
         */
        function queryNamespaces() {
                if ( is_null( $this->namespaces ) ) {
@@ -108,9 +108,9 @@ class SearchOracle extends SearchDatabase {
        /**
         * Return a LIMIT clause to limit results on the query.
         *
-        * @param $sql string
+        * @param string $sql
         *
-        * @return String
+        * @return string
         */
        function queryLimit( $sql ) {
                return $this->db->limitResult( $sql, $this->limit, $this->offset );
@@ -120,7 +120,7 @@ class SearchOracle extends SearchDatabase {
         * Does not do anything for generic search engine
         * subclasses may define this though
         *
-        * @return String
+        * @return string
         */
        function queryRanking( $filteredTerm, $fulltext ) {
                return ' ORDER BY score(1)';
@@ -129,9 +129,9 @@ class SearchOracle extends SearchDatabase {
        /**
         * Construct the full SQL query to do the search.
         * The guts shoulds be constructed in queryMain()
-        * @param $filteredTerm String
-        * @param $fulltext Boolean
-        * @return String
+        * @param string $filteredTerm
+        * @param bool $fulltext
+        * @return string
         */
        function getQuery( $filteredTerm, $fulltext ) {
                return $this->queryLimit( $this->queryMain( $filteredTerm, $fulltext ) . ' ' .
@@ -141,8 +141,8 @@ class SearchOracle extends SearchDatabase {
 
        /**
         * Picks which field to index on, depending on what type of query.
-        * @param $fulltext Boolean
-        * @return String
+        * @param bool $fulltext
+        * @return string
         */
        function getIndexField( $fulltext ) {
                return $fulltext ? 'si_text' : 'si_title';
@@ -151,9 +151,9 @@ class SearchOracle extends SearchDatabase {
        /**
         * Get the base part of the search query.
         *
-        * @param $filteredTerm String
-        * @param $fulltext Boolean
-        * @return String
+        * @param string $filteredTerm
+        * @param bool $fulltext
+        * @return string
         */
        function queryMain( $filteredTerm, $fulltext ) {
                $match = $this->parseQuery( $filteredTerm, $fulltext );
@@ -222,9 +222,9 @@ class SearchOracle extends SearchDatabase {
         * Create or update the search index record for the given page.
         * Title and text should be pre-processed.
         *
-        * @param $id Integer
-        * @param $title String
-        * @param $text String
+        * @param int $id
+        * @param string $title
+        * @param string $text
         */
        function update( $id, $title, $text ) {
                $dbw = wfGetDB( DB_MASTER );
@@ -251,8 +251,8 @@ class SearchOracle extends SearchDatabase {
         * Update a search index record's title only.
         * Title should be pre-processed.
         *
-        * @param $id Integer
-        * @param $title String
+        * @param int $id
+        * @param string $title
         */
        function updateTitle( $id, $title ) {
                $dbw = wfGetDB( DB_MASTER );