1 | <?php |
||
13 | class Result |
||
14 | { |
||
15 | /** |
||
16 | * HTTP code. |
||
17 | * @var integer |
||
18 | */ |
||
19 | private $httpCode; |
||
20 | |||
21 | /** |
||
22 | * Payload. |
||
23 | * @var mixed |
||
24 | */ |
||
25 | private $payload = null; |
||
26 | |||
27 | /** |
||
28 | * Previous page number (or null). |
||
29 | * @var integer|null |
||
30 | */ |
||
31 | private $prevPage = null; |
||
32 | |||
33 | /** |
||
34 | * Next page number (or null). |
||
35 | * @var integer|null |
||
36 | */ |
||
37 | private $nextPage = null; |
||
38 | |||
39 | /** |
||
40 | * Last page number |
||
41 | * @var integer|null |
||
42 | */ |
||
43 | private $lastPage = null; |
||
44 | |||
45 | /** |
||
46 | * The limit for this endpoint |
||
47 | * @var integer |
||
48 | */ |
||
49 | private $rateLimit; |
||
50 | |||
51 | /** |
||
52 | * The amount of calls remaining for this endpoint |
||
53 | * @var integer |
||
54 | */ |
||
55 | private $rateLimitRemaining; |
||
56 | |||
57 | /** |
||
58 | * The X-RateLimit-Reset header provides a Unix UTC timestamp, letting you |
||
59 | * know the exact time that your fresh new rate limit kicks in. |
||
60 | * @var string |
||
61 | */ |
||
62 | private $rateLimitReset; |
||
63 | |||
64 | /** |
||
65 | * Decoded JSON response data. |
||
66 | * @var array |
||
67 | */ |
||
68 | private $decodedJsonData = null; |
||
69 | |||
70 | /** |
||
71 | * Constructor. |
||
72 | * @param array $decodedJsonData |
||
73 | * @param string $rawHttpResponseData |
||
|
|||
74 | * @param array[string] $rawHttpResponseHeaders |
||
75 | */ |
||
76 | 31 | public function __construct($decodedJsonData, $httpCode) |
|
81 | |||
82 | /** |
||
83 | * Return HTTP response code. |
||
84 | * @return integer |
||
85 | */ |
||
86 | 3 | public function getHttpCode() |
|
90 | |||
91 | /** |
||
92 | * Set HTTP response code. |
||
93 | * @param integer $code |
||
94 | */ |
||
95 | public function setHttpCode($httpCode) |
||
99 | |||
100 | /** |
||
101 | * Return payload. |
||
102 | * @return mixed |
||
103 | */ |
||
104 | 29 | public function getPayload() |
|
108 | |||
109 | /** |
||
110 | * Set payload (parsed and wrapped response data). |
||
111 | * @param mixed $payload |
||
112 | */ |
||
113 | 28 | public function setPayload($payload) |
|
117 | |||
118 | /** |
||
119 | * Return decoded JSON data. |
||
120 | * @return array |
||
121 | */ |
||
122 | 28 | public function getDecodedJsonData() |
|
126 | |||
127 | /** |
||
128 | * Set decoded JSON data. |
||
129 | * @param array $decodedJsonData |
||
130 | */ |
||
131 | public function setDecodedJsonData($decodedJsonData) |
||
135 | |||
136 | /** |
||
137 | * Returns previous page number (or null). |
||
138 | * @return integer|null |
||
139 | */ |
||
140 | public function getPrevPage() |
||
144 | |||
145 | /** |
||
146 | * Set previous page number. |
||
147 | * @param integer|null $prevPage |
||
148 | */ |
||
149 | public function setPrevPage($prevPage) |
||
153 | |||
154 | /** |
||
155 | * Returns next page number (or null). |
||
156 | * @return integer|null |
||
157 | */ |
||
158 | public function getNextPage() |
||
162 | |||
163 | /** |
||
164 | * Set next page number. |
||
165 | * @param integer|null $nextPage |
||
166 | */ |
||
167 | public function setNextPage($nextPage) |
||
171 | |||
172 | /** |
||
173 | * Return last page number |
||
174 | * @return integer|null |
||
175 | */ |
||
176 | public function getLastPage() |
||
180 | |||
181 | /** |
||
182 | * Set last page number. |
||
183 | * @param integer|null $lastPage |
||
184 | */ |
||
185 | public function setLastPage($lastPage) |
||
189 | |||
190 | public function getRateLimit() |
||
194 | |||
195 | public function setRateLimit($rateLimit) |
||
199 | |||
200 | public function getRateLimitRemaining() |
||
204 | |||
205 | public function setRateLimitRemaining($rateLimitRemaining) |
||
209 | |||
210 | public function getRateLimitReset() |
||
214 | |||
215 | public function setRateLimitReset($rateLimitReset) |
||
219 | } |
||
220 | |||
222 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.