| Total Complexity | 5 |
| Total Lines | 47 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php declare(strict_types = 1); |
||
| 12 | class SuggesterResults |
||
| 13 | { |
||
| 14 | /** @var string */ |
||
| 15 | private $index; |
||
| 16 | |||
| 17 | /** @var string */ |
||
| 18 | private $query; |
||
| 19 | |||
| 20 | /** @var array<string> */ |
||
| 21 | private $results; |
||
| 22 | |||
| 23 | /** @var float the time in seconds */ |
||
| 24 | private $time; |
||
|
|
|||
| 25 | |||
| 26 | /** @var int */ |
||
| 27 | private $limit; |
||
| 28 | |||
| 29 | |||
| 30 | public function setIndex(string $newIndex): void |
||
| 31 | { |
||
| 32 | $this->index = $newIndex; |
||
| 33 | } |
||
| 34 | |||
| 35 | |||
| 36 | public function setLimit(int $newLimit): void |
||
| 37 | { |
||
| 38 | $this->limit = $newLimit; |
||
| 39 | } |
||
| 40 | |||
| 41 | |||
| 42 | public function setQuery(string $newQuery): void |
||
| 43 | { |
||
| 44 | $this->query = $newQuery; |
||
| 45 | } |
||
| 46 | |||
| 47 | |||
| 48 | /** @return array<string> */ |
||
| 49 | public function getResults(): array |
||
| 50 | { |
||
| 51 | return $this->results; |
||
| 52 | } |
||
| 53 | |||
| 54 | |||
| 55 | /** @param array<string> $newResults */ |
||
| 56 | public function setResults(array $newResults): void |
||
| 59 | } |
||
| 60 | } |
||
| 61 |