Wikibase
MediaWiki Wikibase extension
Wikibase\Repo\Api\CombinedEntitySearchHelper Class Reference

Helper class to search for entities by ID. More...

+ Inheritance diagram for Wikibase\Repo\Api\CombinedEntitySearchHelper:
+ Collaboration diagram for Wikibase\Repo\Api\CombinedEntitySearchHelper:

Public Member Functions

 __construct (array $searchHelpers)
 
 getRankedSearchResults ( $text, $languageCode, $entityType, $limit, $strictLanguage)
 Get entities matching the search term. More...
 

Private Member Functions

 mergeSearchResults (array $searchResults, array $newSearchResults, $limit)
 

Private Attributes

 $searchHelpers
 

Detailed Description

Helper class to search for entities by ID.

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\Api\CombinedEntitySearchHelper::__construct ( array  $searchHelpers)
Parameters
array$searchHelpersordered array of EntitySearchHelpers to be used.

Member Function Documentation

◆ getRankedSearchResults()

Wikibase\Repo\Api\CombinedEntitySearchHelper::getRankedSearchResults (   $text,
  $languageCode,
  $entityType,
  $limit,
  $strictLanguage 
)

Get entities matching the search term.

Parameters
string$text
string$languageCode
string$entityType
int$limit
bool$strictLanguage
Returns
TermSearchResult[] Key: string Serialized EntityId

Implements Wikibase\Repo\Api\EntitySearchHelper.

◆ mergeSearchResults()

Wikibase\Repo\Api\CombinedEntitySearchHelper::mergeSearchResults ( array  $searchResults,
array  $newSearchResults,
  $limit 
)
private
Parameters
TermSearchResult[]$searchResults
TermSearchResult[]$newSearchResults
int$limit
Returns
TermSearchResult[]

Member Data Documentation

◆ $searchHelpers

Wikibase\Repo\Api\CombinedEntitySearchHelper::$searchHelpers
private

The documentation for this class was generated from the following file: