1 | <?php |
||
18 | final class HttpClientException extends \RuntimeException implements Exception |
||
19 | { |
||
20 | /** |
||
21 | * @var ResponseInterface|null |
||
22 | */ |
||
23 | private $response; |
||
24 | |||
25 | /** |
||
26 | * @var array |
||
27 | */ |
||
28 | private $responseBody; |
||
29 | |||
30 | /** |
||
31 | * @var int |
||
32 | */ |
||
33 | private $responseCode; |
||
34 | |||
35 | /** |
||
36 | * @param string $message |
||
37 | * @param int $code |
||
38 | * @param ResponseInterface|null $response |
||
39 | */ |
||
40 | 2 | public function __construct($message, $code, ResponseInterface $response = null) |
|
55 | |||
56 | 2 | public static function badRequest(ResponseInterface $response = null) |
|
74 | |||
75 | public static function unauthorized(ResponseInterface $response = null) |
||
79 | |||
80 | public static function requestFailed(ResponseInterface $response = null) |
||
84 | |||
85 | public static function notFound(ResponseInterface $response = null) |
||
89 | |||
90 | public static function payloadTooLarge(ResponseInterface $response = null) |
||
94 | |||
95 | /** |
||
96 | * @return ResponseInterface |
||
97 | */ |
||
98 | public function getResponse() |
||
102 | |||
103 | /** |
||
104 | * @return array |
||
105 | */ |
||
106 | public function getResponseBody() |
||
110 | |||
111 | /** |
||
112 | * @return int |
||
113 | */ |
||
114 | public function getResponseCode() |
||
118 | } |
||
119 |
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..