| Total Complexity | 3 |
| Total Lines | 24 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 0 | ||
| 1 | <?php |
||
| 9 | class PaginableQueryAdapter implements AdapterInterface |
||
| 10 | { |
||
| 11 | /** @var Query */ |
||
| 12 | private $query; |
||
| 13 | /** @var int */ |
||
| 14 | private $totalItems; |
||
| 15 | |||
| 16 | public function __construct(Query $query, int $totalItems) |
||
| 20 | } |
||
| 21 | |||
| 22 | public function getItems($offset, $itemCountPerPage): iterable |
||
| 28 | } |
||
| 29 | |||
| 30 | public function count(): int |
||
| 35 |
In the issue above, the returned value is violating the contract defined by the mentioned interface.
Let's take a look at an example: