1 | <?php |
||
8 | class Inputs |
||
9 | { |
||
10 | /** |
||
11 | * @var string |
||
12 | */ |
||
13 | public $pagerKey = '_page'; |
||
14 | |||
15 | /** |
||
16 | * @var string |
||
17 | */ |
||
18 | public $limitKey = '_limit'; |
||
19 | |||
20 | /** |
||
21 | * @var int|null |
||
22 | */ |
||
23 | private $total = null; |
||
24 | |||
25 | /** |
||
26 | * @var array |
||
27 | */ |
||
28 | private $list = []; |
||
29 | |||
30 | /** |
||
31 | * @var string |
||
32 | */ |
||
33 | public $path = ''; |
||
34 | |||
35 | /** |
||
36 | * @var array |
||
37 | */ |
||
38 | public $inputs = []; |
||
39 | |||
40 | /** |
||
41 | * Inputs constructor. |
||
42 | * |
||
43 | */ |
||
44 | public function __construct() |
||
45 | { |
||
46 | } |
||
47 | |||
48 | /** |
||
49 | * get the limit, i.e. number of data per page. |
||
50 | * |
||
51 | * @return int |
||
52 | */ |
||
53 | public function getLimit() |
||
57 | |||
58 | /** |
||
59 | * get the offset for retrieving data. |
||
60 | * |
||
61 | * @return int |
||
62 | */ |
||
63 | public function getOffset() |
||
67 | |||
68 | /** |
||
69 | * get the current page number, starting from 1. |
||
70 | * |
||
71 | * @return int |
||
72 | */ |
||
73 | public function getPage() |
||
77 | |||
78 | /** |
||
79 | * get any key from query. |
||
80 | * |
||
81 | * @param string $key |
||
82 | * @param null|mixed $alt |
||
83 | * @return null|mixed |
||
84 | */ |
||
85 | public function get($key, $alt = null) |
||
91 | |||
92 | /** |
||
93 | * get total number of data. |
||
94 | * - total: number of all the possible data which can be retrieved. |
||
95 | * - count: number of data in the current list. |
||
96 | * |
||
97 | * @return int|null |
||
98 | */ |
||
99 | public function getTotal() |
||
103 | |||
104 | /** |
||
105 | * set the total of data. |
||
106 | * |
||
107 | * @param int|null $total |
||
108 | */ |
||
109 | public function setTotal($total) |
||
113 | |||
114 | /** |
||
115 | * set the data for list. |
||
116 | * |
||
117 | * @param mixed $list |
||
118 | */ |
||
119 | public function setList($list) |
||
123 | |||
124 | /** |
||
125 | * get the data for list. |
||
126 | * |
||
127 | * @return null|array|mixed |
||
128 | */ |
||
129 | public function getList() |
||
133 | |||
134 | /** |
||
135 | * get the count, i.e. number of data in the current list. |
||
136 | * count is the number of data in the current list. |
||
137 | * |
||
138 | * @return int |
||
139 | */ |
||
140 | public function getCount() |
||
147 | |||
148 | /** |
||
149 | * calculates the first page number, that is 1. |
||
150 | * |
||
151 | * @return int |
||
152 | */ |
||
153 | public function calcFirstPage() |
||
157 | |||
158 | /** |
||
159 | * calculates the last pager number. |
||
160 | * |
||
161 | * @return int |
||
162 | */ |
||
163 | public function calcLastPage() |
||
172 | |||
173 | /** |
||
174 | * @param null|int $page |
||
175 | * @return string |
||
176 | */ |
||
177 | public function getPath($page = null) |
||
185 | |||
186 | /** |
||
187 | * @return PaginateInterface |
||
188 | */ |
||
189 | public function getPagination() |
||
193 | |||
194 | /** |
||
195 | * @return string |
||
196 | */ |
||
197 | public function __toString() |
||
202 | } |
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..