Source of file AggregateResultList.php
Size: 0,610 Bytes - Last Modified: 2021-12-23T10:07:43+00:00
/var/www/docs.ssmods.com/process/src/src/AggregateResultList.php
12345678910111213141516171819202122232425262728293031 | <?php namespace Symbiote\ElasticSearch; use Elastica\Result; use Heyday\Elastica\ResultList; /** * A class that makes use of the results returned in a top_hits * aggregate to allow for sub-grouped sets of results to be displayed * */ class AggregateResultList extends ResultList { private $aggregateResult; public function __construct($results) { $this->aggregateResult = []; foreach ($results as $hitData) { $this->aggregateResult[] = new Result($hitData); } } public function getResults() { return $this->aggregateResult; } } |