| Total Complexity | 4 |
| Total Lines | 68 |
| Duplicated Lines | 0 % |
| Coverage | 85.71% |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 21 | class Error extends \Exception { |
||
| 22 | /** |
||
| 23 | * Status. |
||
| 24 | * |
||
| 25 | * @var int |
||
| 26 | */ |
||
| 27 | private $status; |
||
| 28 | |||
| 29 | /** |
||
| 30 | * Title. |
||
| 31 | * |
||
| 32 | * @var string |
||
| 33 | */ |
||
| 34 | private $title; |
||
| 35 | |||
| 36 | /** |
||
| 37 | * Detail. |
||
| 38 | * |
||
| 39 | * @var string |
||
| 40 | */ |
||
| 41 | public $detail; |
||
| 42 | |||
| 43 | /** |
||
| 44 | * Construct Mollie error. |
||
| 45 | * |
||
| 46 | * @param int $status Status. |
||
| 47 | * @param string $title Title. |
||
| 48 | * @param string $detail Detail. |
||
| 49 | */ |
||
| 50 | 3 | public function __construct( $status, $title, $detail ) { |
|
| 51 | 3 | $message = sprintf( |
|
| 52 | 3 | '%s - %s', |
|
| 53 | $title, |
||
| 54 | $detail |
||
| 55 | ); |
||
| 56 | |||
| 57 | 3 | parent::__construct( $message, $status ); |
|
| 58 | |||
| 59 | 3 | $this->status = $status; |
|
| 60 | 3 | $this->title = $title; |
|
| 61 | 3 | $this->detail = $detail; |
|
| 62 | 3 | } |
|
| 63 | |||
| 64 | /** |
||
| 65 | * Get status. |
||
| 66 | * |
||
| 67 | * @return int |
||
| 68 | */ |
||
| 69 | public function get_status() { |
||
| 71 | } |
||
| 72 | |||
| 73 | /** |
||
| 74 | * Get title. |
||
| 75 | * |
||
| 76 | * @return string |
||
| 77 | */ |
||
| 78 | 3 | public function get_title() { |
|
| 80 | } |
||
| 81 | |||
| 82 | /** |
||
| 83 | * Get title. |
||
| 84 | * |
||
| 85 | * @return string |
||
| 86 | */ |
||
| 87 | 3 | public function get_detail() { |
|
| 91 |