Total Complexity | 4 |
Total Lines | 46 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | class ErrorResponse implements ResponseInterface |
||
8 | { |
||
9 | /** |
||
10 | * @var PsrResponse |
||
11 | */ |
||
12 | private $response; |
||
13 | |||
14 | /** |
||
15 | * @var ClientException |
||
16 | */ |
||
17 | private $exception; |
||
18 | |||
19 | /** |
||
20 | * @param PsrResponse $response |
||
21 | * @param $exception |
||
22 | */ |
||
23 | public function __construct(PsrResponse $response, ClientException $exception) |
||
27 | } |
||
28 | |||
29 | /** |
||
30 | * @param null $item |
||
|
|||
31 | * @param null $default |
||
32 | * @return mixed |
||
33 | */ |
||
34 | public function get($item = null, $default = null) |
||
35 | { |
||
36 | return 'An error occurred while processing the request.'; |
||
37 | } |
||
38 | |||
39 | /** |
||
40 | * @return PsrResponse |
||
41 | */ |
||
42 | public function getHttpResponse() |
||
43 | { |
||
44 | return $this->response; |
||
45 | } |
||
46 | |||
47 | /** |
||
48 | * @return bool |
||
49 | */ |
||
50 | public function successful() |
||
53 | } |
||
54 | } |
||
55 |