Total Complexity | 2 |
Total Lines | 28 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
20 | class Exception extends \Exception |
||
21 | { |
||
22 | private $details; |
||
23 | |||
24 | |||
25 | /** |
||
26 | * Initializes the object. |
||
27 | * |
||
28 | * @param string $message Exception message |
||
29 | * @param int $code Custom exception code |
||
30 | * @param mixed $details Custom exception details |
||
31 | */ |
||
32 | public function __construct( string $message = '', int $code = 0, $details = null ) |
||
33 | { |
||
34 | parent::__construct( $message, $code ); |
||
35 | |||
36 | $this->details = $details; |
||
37 | } |
||
38 | |||
39 | |||
40 | /** |
||
41 | * Returns the custom exception details |
||
42 | * |
||
43 | * @return mixed Custom exception details |
||
44 | */ |
||
45 | public function getDetails() |
||
48 | } |
||
49 | } |
||
50 |