1 | <?php |
||
7 | class Inputs |
||
8 | { |
||
9 | /** |
||
10 | * @var string |
||
11 | */ |
||
12 | public $pagerKey = '_page'; |
||
13 | |||
14 | /** |
||
15 | * @var string |
||
16 | */ |
||
17 | public $limitKey = '_limit'; |
||
18 | |||
19 | /** |
||
20 | * @var int|null |
||
21 | */ |
||
22 | private $total = null; |
||
23 | |||
24 | /** |
||
25 | * @var array |
||
26 | */ |
||
27 | private $list = []; |
||
28 | |||
29 | /** |
||
30 | * @var string |
||
31 | */ |
||
32 | public $path = ''; |
||
33 | |||
34 | /** |
||
35 | * @var array |
||
36 | */ |
||
37 | public $inputs = []; |
||
38 | |||
39 | /** |
||
40 | * @var PaginateInterface |
||
41 | */ |
||
42 | private $paginate; |
||
43 | |||
44 | /** |
||
45 | * Inputs constructor. |
||
46 | * |
||
47 | * @param PaginateInterface $paginate |
||
48 | */ |
||
49 | public function __construct($paginate = null) |
||
53 | |||
54 | /** |
||
55 | * get the limit, i.e. number of data per page. |
||
56 | * |
||
57 | * @return int |
||
58 | */ |
||
59 | public function getLimit() |
||
63 | |||
64 | /** |
||
65 | * get the offset for retrieving data. |
||
66 | * |
||
67 | * @return int |
||
68 | */ |
||
69 | public function getOffset() |
||
73 | |||
74 | /** |
||
75 | * get the current page number, starting from 1. |
||
76 | * |
||
77 | * @return int |
||
78 | */ |
||
79 | public function getPage() |
||
83 | |||
84 | /** |
||
85 | * get any key from query. |
||
86 | * |
||
87 | * @param string $key |
||
88 | * @param null|mixed $alt |
||
89 | * @return null|mixed |
||
90 | */ |
||
91 | public function get($key, $alt = null) |
||
97 | |||
98 | /** |
||
99 | * get total number of data. |
||
100 | * - total: number of all the possible data which can be retrieved. |
||
101 | * - count: number of data in the current list. |
||
102 | * |
||
103 | * @return int|null |
||
104 | */ |
||
105 | public function getTotal() |
||
109 | |||
110 | /** |
||
111 | * set the total of data. |
||
112 | * |
||
113 | * @param int|null $total |
||
114 | */ |
||
115 | public function setTotal($total) |
||
119 | |||
120 | /** |
||
121 | * set the data for list. |
||
122 | * |
||
123 | * @param mixed $list |
||
124 | */ |
||
125 | public function setList($list) |
||
129 | |||
130 | /** |
||
131 | * get the data for list. |
||
132 | * |
||
133 | * @return null|array|mixed |
||
134 | */ |
||
135 | public function getList() |
||
139 | |||
140 | /** |
||
141 | * get the count, i.e. number of data in the current list. |
||
142 | * count is the number of data in the current list. |
||
143 | * |
||
144 | * @return int |
||
145 | */ |
||
146 | public function getCount() |
||
153 | |||
154 | /** |
||
155 | * calculates the first page number, that is 1. |
||
156 | * |
||
157 | * @return int |
||
158 | */ |
||
159 | public function calcFirstPage() |
||
163 | |||
164 | /** |
||
165 | * calculates the last pager number. |
||
166 | * |
||
167 | * @return int |
||
168 | */ |
||
169 | public function calcLastPage() |
||
178 | |||
179 | /** |
||
180 | * @param null|int $page |
||
181 | * @return string |
||
182 | */ |
||
183 | public function getPath($page = null) |
||
191 | |||
192 | /** |
||
193 | * @return PaginateInterface |
||
194 | */ |
||
195 | public function getPagination() |
||
201 | } |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..