1 | <?php |
||
9 | class JsonRpcException extends \Exception implements JsonRpcExceptionInterface |
||
10 | { |
||
11 | /** @var JsonRpcErrorInterface */ |
||
12 | private $jsonRpcError; |
||
13 | |||
14 | 7 | public function __construct($message = '', $code = 0, Exception $previous = null) |
|
20 | |||
21 | /** |
||
22 | * @return JsonRpcErrorInterface |
||
23 | */ |
||
24 | 1 | public function getJsonRpcError() |
|
25 | { |
||
26 | 1 | return $this->jsonRpcError; |
|
27 | } |
||
28 | |||
29 | /** |
||
30 | * @param JsonRpcErrorInterface $jsonRpcError |
||
31 | */ |
||
32 | protected function setJsonRpcError(JsonRpcErrorInterface $jsonRpcError) |
||
33 | { |
||
34 | $this->jsonRpcError = $jsonRpcError; |
||
35 | } |
||
36 | |||
37 | 7 | public static function create($code, $message, $data = null) |
|
44 | } |
||
45 |