CirrusSearch
Elasticsearch-powered search for MediaWiki
|
Parse a cirrus fulltext search query and build an elasticsearch query. More...
Public Member Functions | |
build (SearchContext $searchContext, $term) | |
Build a query for supplied term. | |
buildDegraded (SearchContext $searchContext) | |
Attempt to build a degraded query from the query already built into $context. | |
Parse a cirrus fulltext search query and build an elasticsearch query.
CirrusSearch\Query\FullTextQueryBuilder::build | ( | SearchContext | $searchContext, |
$term ) |
Build a query for supplied term.
The method will setup the query and accompanying environment within the supplied context.
TODO: right now, this code does two separate things, parsing $term and building query from parsed structure. We may want to split this into separate actions, to allow other query builders to benefit from parsing stage but override building stage.
SearchContext | $searchContext | |
string | $term | term to search |
Implemented in CirrusSearch\Query\FullTextQueryStringQueryBuilder.
CirrusSearch\Query\FullTextQueryBuilder::buildDegraded | ( | SearchContext | $searchContext | ) |
Attempt to build a degraded query from the query already built into $context.
Must be called after self::build().
SearchContext | $searchContext |
Implemented in CirrusSearch\Query\FullTextQueryStringQueryBuilder.