MediaWiki
1.34.0
|
A set of SearchEngine results. More...
Public Member Functions | |
augmentResult (SearchResult $result) | |
Returns extra data for specific result and store it in SearchResult object. More... | |
extractResults () | |
Extract all the results in the result set as array. More... | |
extractTitles () | |
Extract all the titles in the result set. More... | |
getInterwikiResults ( $type=self::SECONDARY_RESULTS) | |
Return a result set of hits on other (multiple) wikis associated with this one. More... | |
getOffset () | |
getQueryAfterRewrite () | |
getQueryAfterRewriteSnippet () | |
getSuggestionQuery () | |
getSuggestionSnippet () | |
getTotalHits () | |
Some search modes return a total hit count for the query in the entire article database. More... | |
hasInterwikiResults ( $type=self::SECONDARY_RESULTS) | |
Check if there are results on other wikis. More... | |
hasMoreResults () | |
hasRewrittenQuery () | |
Some search modes will run an alternative query that it thinks gives a better result than the provided search. More... | |
hasSuggestion () | |
Some search modes return a suggested alternate term if there are no exact hits. More... | |
numRows () | |
searchContainedSyntax () | |
Did the search contain search syntax? If so, Special:Search won't offer the user a link to a create a page named by the search string because the name would contain the search syntax. More... | |
setAugmentedData ( $name, $data) | |
Sets augmented data for result set. More... | |
shrink ( $limit) | |
Public Attributes | |
const | INLINE_RESULTS = 1 |
Identifier for interwiki results that can be displayed even if no existing main wiki results exist. More... | |
const | SECONDARY_RESULTS = 0 |
Identifier for interwiki results that are displayed only together with existing main wiki results. More... | |
A set of SearchEngine results.
Must not be directly implemented by extension, please extend BaseSearchResultSet instead. This interface must only be used for type hinting.
Definition at line 11 of file ISearchResultSet.php.
ISearchResultSet::augmentResult | ( | SearchResult | $result | ) |
Returns extra data for specific result and store it in SearchResult object.
SearchResult | $result |
Referenced by SqlSearchResultSet\extractResults().
ISearchResultSet::extractResults | ( | ) |
Extract all the results in the result set as array.
Implemented in SearchResultSet, and SqlSearchResultSet.
Referenced by PerRowAugmentor\augmentAll().
ISearchResultSet::extractTitles | ( | ) |
Extract all the titles in the result set.
Implemented in SearchResultSet.
Referenced by AugmentPageProps\augmentAll().
ISearchResultSet::getInterwikiResults | ( | $type = self::SECONDARY_RESULTS | ) |
Return a result set of hits on other (multiple) wikis associated with this one.
int | $type |
Implemented in SearchResultSet.
ISearchResultSet::getOffset | ( | ) |
ISearchResultSet::getQueryAfterRewrite | ( | ) |
Implemented in SearchResultSet.
Referenced by MediaWiki\Widget\Search\DidYouMeanWidget\rewrittenHtml().
ISearchResultSet::getQueryAfterRewriteSnippet | ( | ) |
Implemented in SearchResultSet.
Referenced by MediaWiki\Widget\Search\DidYouMeanWidget\rewrittenHtml().
ISearchResultSet::getSuggestionQuery | ( | ) |
Implemented in SearchResultSet.
Referenced by MediaWiki\Widget\Search\DidYouMeanWidget\suggestionHtml().
ISearchResultSet::getSuggestionSnippet | ( | ) |
Implemented in SearchResultSet.
Referenced by MediaWiki\Widget\Search\DidYouMeanWidget\suggestionHtml().
ISearchResultSet::getTotalHits | ( | ) |
Some search modes return a total hit count for the query in the entire article database.
This may include pages in namespaces that would not be matched on the given settings.
Return null if no total hits number is supported.
Implemented in SearchResultSet, and SqlSearchResultSet.
ISearchResultSet::hasInterwikiResults | ( | $type = self::SECONDARY_RESULTS | ) |
Check if there are results on other wikis.
int | $type |
Implemented in SearchResultSet.
ISearchResultSet::hasMoreResults | ( | ) |
Implemented in SearchResultSet.
ISearchResultSet::hasRewrittenQuery | ( | ) |
Some search modes will run an alternative query that it thinks gives a better result than the provided search.
Returns true if this has occurred.
Implemented in SearchResultSet.
Referenced by MediaWiki\Widget\Search\DidYouMeanWidget\render().
ISearchResultSet::hasSuggestion | ( | ) |
Some search modes return a suggested alternate term if there are no exact hits.
Returns true if there is one on this set.
Implemented in SearchResultSet.
Referenced by MediaWiki\Widget\Search\DidYouMeanWidget\render().
ISearchResultSet::numRows | ( | ) |
Implemented in SearchResultSet, SqlSearchResultSet, and SearchNearMatchResultSet.
ISearchResultSet::searchContainedSyntax | ( | ) |
Did the search contain search syntax? If so, Special:Search won't offer the user a link to a create a page named by the search string because the name would contain the search syntax.
Implemented in SearchResultSet.
ISearchResultSet::setAugmentedData | ( | $name, | |
$data | |||
) |
Sets augmented data for result set.
string | $name | Extra data item name |
array[] | $data | Extra data as PAGEID => data |
Referenced by SearchEngine\augmentSearchResults().
ISearchResultSet::shrink | ( | $limit | ) |
int | $limit | Shrink result set to $limit and flag if more results are available. |
Implemented in SearchResultSet.
const ISearchResultSet::INLINE_RESULTS = 1 |
Identifier for interwiki results that can be displayed even if no existing main wiki results exist.
Definition at line 22 of file ISearchResultSet.php.
Referenced by MediaWiki\Widget\Search\BasicSearchResultSetWidget\render(), ApiQuerySearch\run(), and SpecialSearch\showResults().
const ISearchResultSet::SECONDARY_RESULTS = 0 |
Identifier for interwiki results that are displayed only together with existing main wiki results.
Definition at line 16 of file ISearchResultSet.php.
Referenced by MediaWiki\Widget\Search\BasicSearchResultSetWidget\render(), ApiQuerySearch\run(), and SpecialSearch\showResults().