| 1 | <?php namespace CMPayments\Exception; |
||
| 9 | class BaseException extends \ErrorException |
||
| 10 | { |
||
| 11 | private $args = []; |
||
| 12 | |||
| 13 | private $defaultMessage = 'This service is temporarily unavailable'; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * @return mixed |
||
| 17 | */ |
||
| 18 | public function getArgs() |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @param mixed $args |
||
| 25 | */ |
||
| 26 | public function setArgs($args) |
||
| 36 | |||
| 37 | /** |
||
| 38 | * BaseException constructor. |
||
| 39 | * |
||
| 40 | * @param string $code |
||
| 41 | * @param array $args |
||
| 42 | * @param null $message |
||
| 43 | */ |
||
| 44 | public function __construct($code, $args = [], $message = null) |
||
| 51 | |||
| 52 | /** |
||
| 53 | * Retrieves a specific array key from a class constant |
||
| 54 | * |
||
| 55 | * @param int $code |
||
| 56 | * @param null $default |
||
| 57 | * @param string $msgArray |
||
| 58 | * |
||
| 59 | * @return null|string |
||
| 60 | */ |
||
| 61 | public function getItemFromVariableArray($code, $default = null, $msgArray = 'messages') |
||
| 82 | |||
| 83 | /** |
||
| 84 | * PHP 5.4 workaround to something like this |
||
| 85 | * |
||
| 86 | * @return string |
||
| 87 | */ |
||
| 88 | public static function getClassName(){ |
||
| 92 | } |
||
| 93 |