1 | <?php |
||
26 | class TransformedFinder implements PaginatedFinderInterface |
||
27 | { |
||
28 | /** |
||
29 | * @var SearchableInterface |
||
30 | */ |
||
31 | protected $searchable; |
||
32 | |||
33 | /** |
||
34 | * @var ElasticaToModelTransformerInterface |
||
35 | */ |
||
36 | protected $transformer; |
||
37 | |||
38 | /** |
||
39 | * @param SearchableInterface $searchable |
||
40 | * @param ElasticaToModelTransformerInterface $transformer |
||
41 | */ |
||
42 | 7 | public function __construct(SearchableInterface $searchable, ElasticaToModelTransformerInterface $transformer) |
|
47 | |||
48 | /** |
||
49 | * {@inheritdoc} |
||
50 | */ |
||
51 | 1 | public function find($query, $limit = null, $options = []) |
|
57 | |||
58 | /** |
||
59 | * @param $query |
||
60 | * @param null|int $limit |
||
61 | * @param array $options |
||
62 | * |
||
63 | * @return array |
||
64 | */ |
||
65 | 1 | public function findHybrid($query, $limit = null, $options = []) |
|
71 | |||
72 | /** |
||
73 | * {@inheritdoc} |
||
74 | */ |
||
75 | 1 | public function findPaginated($query, $options = []) |
|
82 | |||
83 | /** |
||
84 | * {@inheritdoc} |
||
85 | */ |
||
86 | public function findHybridPaginated($query) |
||
92 | |||
93 | /** |
||
94 | * {@inheritdoc} |
||
95 | */ |
||
96 | 2 | public function createPaginatorAdapter($query, $options = []) |
|
102 | |||
103 | /** |
||
104 | * {@inheritdoc} |
||
105 | */ |
||
106 | 1 | public function createHybridPaginatorAdapter($query) |
|
112 | |||
113 | /** |
||
114 | * {@inheritdoc} |
||
115 | */ |
||
116 | public function createRawPaginatorAdapter($query, $options = []) |
||
122 | |||
123 | /** |
||
124 | * @param $query |
||
125 | * @param null|int $limit |
||
126 | * @param array $options |
||
127 | * |
||
128 | * @return array |
||
129 | */ |
||
130 | 1 | protected function search($query, $limit = null, $options = []) |
|
140 | } |
||
141 |