| 1 | <?php |
||
| 19 | class SearchResult extends ValueObject implements IteratorAggregate |
||
| 20 | { |
||
| 21 | /** |
||
| 22 | * The facets for this search. |
||
| 23 | * |
||
| 24 | * @var \eZ\Publish\API\Repository\Values\Content\Search\Facet[] |
||
| 25 | */ |
||
| 26 | public $facets = []; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * The value objects found for the query. |
||
| 30 | * |
||
| 31 | * @var \eZ\Publish\API\Repository\Values\Content\Search\SearchHit[] |
||
| 32 | */ |
||
| 33 | public $searchHits = []; |
||
| 34 | |||
| 35 | /** |
||
| 36 | * If spellcheck is on this field contains a collated query suggestion where in the appropriate |
||
| 37 | * criterions the wrong spelled value is replaced by a corrected one (TBD). |
||
| 38 | * |
||
| 39 | * @var \eZ\Publish\API\Repository\Values\Content\Query\Criterion |
||
| 40 | */ |
||
| 41 | public $spellSuggestion; |
||
| 42 | |||
| 43 | /** |
||
| 44 | * The duration of the search processing in ms. |
||
| 45 | * |
||
| 46 | * @var int |
||
| 47 | */ |
||
| 48 | public $time; |
||
| 49 | |||
| 50 | /** |
||
| 51 | * Indicates if the search has timed out. |
||
| 52 | * |
||
| 53 | * @var bool |
||
| 54 | */ |
||
| 55 | public $timedOut; |
||
| 56 | |||
| 57 | /** |
||
| 58 | * The maximum score of this query. |
||
| 59 | * |
||
| 60 | * @var float |
||
| 61 | */ |
||
| 62 | public $maxScore; |
||
| 63 | |||
| 64 | /** |
||
| 65 | * The total number of searchHits. |
||
| 66 | * |
||
| 67 | * `null` if Query->performCount was set to false and search engine avoids search lookup. |
||
| 68 | * |
||
| 69 | * @var int|null |
||
| 70 | */ |
||
| 71 | public $totalCount; |
||
| 72 | |||
| 73 | public function getIterator(): Traversable |
||
| 77 | } |
||
| 78 |