Total Complexity | 2 |
Total Lines | 28 |
Duplicated Lines | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
11 | class HttpException extends Exception |
||
12 | { |
||
13 | /** |
||
14 | * @var array |
||
15 | */ |
||
16 | protected $parameters = []; |
||
17 | |||
18 | /** |
||
19 | * HttpException constructor. |
||
20 | * |
||
21 | * @param string $message [optional] The Exception message to throw. |
||
22 | * @param int $code [optional] The Exception code. |
||
23 | * @param \Throwable|\Exception $previous [optional] The previous throwable used for the exception chaining. |
||
24 | * @param array $parameters [optional] Array of parameters returned from API. |
||
25 | */ |
||
26 | public function __construct($message = '', $code = 0, $previous = null, $parameters = []) |
||
27 | { |
||
28 | $this->parameters = $parameters; |
||
29 | |||
30 | parent::__construct($message, $code, $previous); |
||
31 | } |
||
32 | |||
33 | /** |
||
34 | * @return array |
||
35 | */ |
||
36 | public function getParameters() |
||
39 | } |
||
40 | } |
||
41 |