Completed
Push — master ( 9ec6aa...297e32 )
by Reen
07:19 queued 05:21
created

Pager::getLimit()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace ReenExeCubeTime\LightPaginator;
4
5
use ReenExeCubeTime\LightPaginator\Adapter\AdapterInterface;
6
7
class Pager implements PagerInterface
8
{
9
    /**
10
     * @var int
11
     */
12
    private $currentPage;
13
14
    /**
15
     * @var int
16
     */
17
    private $limit;
18
19
    /**
20
     * @var int
21
     */
22
    private $count;
23
24
    /**
25
     * @var array|\Traversable
26
     */
27
    private $list;
28
29
    public function __construct($currentPage, $limit, $count, $list)
30
    {
31
        $this->currentPage = $currentPage;
32
        $this->limit = $limit;
33
        $this->count = $count;
34
        $this->list = $list;
35
    }
36
37
    /**
38
     * @return int
39
     */
40
    public function getCurrentPage()
41
    {
42
        return $this->currentPage;
43
    }
44
45
    /**
46
     * @return int
47
     */
48
    public function getLimit()
49
    {
50
        return $this->limit;
51
    }
52
53
    /**
54
     * @return int
55
     */
56
    public function getCount()
57
    {
58
        return $this->count;
59
    }
60
61
    /**
62
     * @return array|\Traversable
63
     */
64
    public function getList()
65
    {
66
        return $this->list;
67
    }
68
}
69