1 | <?php |
||
11 | final class ORMQueryResult implements Result |
||
12 | { |
||
13 | private $query; |
||
14 | private $fetchCollection; |
||
15 | private $count; |
||
16 | |||
17 | /** |
||
18 | * @param Query|QueryBuilder $query |
||
19 | * @param bool $fetchCollection |
||
20 | */ |
||
21 | 12 | public function __construct($query, $fetchCollection = true) |
|
30 | |||
31 | /** |
||
32 | * {@inheritdoc} |
||
33 | */ |
||
34 | public function take($offset, $limit) |
||
42 | |||
43 | /** |
||
44 | * {@inheritdoc} |
||
45 | */ |
||
46 | 4 | public function count() |
|
54 | |||
55 | /** |
||
56 | * {@inheritdoc} |
||
57 | */ |
||
58 | 2 | public function getIterator() |
|
62 | |||
63 | /** |
||
64 | * @param int $offset |
||
65 | * @param int $limit |
||
66 | * |
||
67 | * @return Paginator |
||
68 | */ |
||
69 | 10 | private function createPaginator($offset, $limit) |
|
82 | } |
||
83 |