SilverStripe\Elastica\ResultList::__construct
Create a search and then optionally tweak it. Actual search is only performed against Elasticsearch when the getResults() method is called.
Signature
public function __construct(ElasticaService
$service,
Query
$query,
string
$queryText,
[array
$filters = ] )
Parameters
$service
—
SilverStripe\Elastica\ElasticaService
- object used to communicate with Elasticsearch
$query
—
Elastica\Query
- Elastica query object, created via QueryGenerator
$queryText
—
string
- the text from the query
$filters
—
array
- Selected filters, used for aggregation purposes only
(i.e. query already filtered prior to this)