Conditions | 1 |
Paths | 1 |
Total Lines | 13 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
25 | public function take($offset, $limit) |
||
26 | { |
||
27 | $qb = clone $this->qb; |
||
28 | $results = function ($offset, $limit) use ($qb) { |
||
29 | return $qb |
||
30 | ->setFirstResult($offset) |
||
31 | ->setMaxResults($limit) |
||
32 | ->execute() |
||
33 | ->fetchAll(); |
||
34 | }; |
||
35 | |||
36 | return new CallbackPage($results, [$this, 'count'], $offset, $limit); |
||
37 | } |
||
38 | |||
68 |