forked from KnpLabs/KnpPaginatorBundle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Adapter.php
44 lines (38 loc) · 952 Bytes
/
Adapter.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
namespace Knp\Bundle\PaginatorBundle\Paginator;
use Zend\Paginator\Adapter as ZendPaginatorAdapter;
/**
* Doctrine Paginator Adapter interface
*/
interface Adapter extends ZendPaginatorAdapter
{
/**
* Set the query object for the adapter
* to be paginated
*
* @param Query $query - The query to paginate
* @param integer $numRows(optional) - number of rows
*/
public function setQuery($query, $numRows = null);
/**
* Set the distinct mode
*
* @param bool $distinct
*/
public function setDistinct($distinct);
/**
* Get paginator alias
*
* @return string
*/
public function getAlias();
/**
* Add a listener service by $type for
* adaper to be able to use
*
* @param string $serviceId
* @param string $type
* @param string $priority
*/
public function addListenerService($serviceId, $type, $priority);
}