Total Complexity | 4 |
Total Lines | 52 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
7 | class JsonRpcParseErrorException extends JsonRpcException |
||
8 | { |
||
9 | const CODE = -32700; |
||
10 | |||
11 | /** @var mixed */ |
||
12 | private $content; |
||
13 | /** @var mixed */ |
||
14 | private $parseErrorCode; |
||
15 | /** @var string */ |
||
16 | private $parseErrorMessage; |
||
17 | |||
18 | const DATA_CONTENT_KEY = 'content'; |
||
19 | const DATA_ERROR_KEY = 'error'; |
||
20 | const DATA_ERROR_CODE_KEY = 'code'; |
||
21 | const DATA_ERROR_MESSAGE_KEY = 'message'; |
||
22 | |||
23 | /** |
||
24 | * @param string $content |
||
25 | * @param mixed $parseErrorCode |
||
26 | * @param mixed $parseErrorMessage |
||
27 | */ |
||
28 | 4 | public function __construct(string $content, $parseErrorCode = null, $parseErrorMessage = null) |
|
35 | 4 | } |
|
36 | |||
37 | /** |
||
38 | * @return mixed |
||
39 | */ |
||
40 | 1 | public function getContent() |
|
41 | { |
||
42 | 1 | return $this->content; |
|
43 | } |
||
44 | |||
45 | /** |
||
46 | * @return mixed |
||
47 | */ |
||
48 | 1 | public function getParseErrorCode() |
|
51 | } |
||
52 | |||
53 | /** |
||
54 | * @return string |
||
55 | */ |
||
56 | 1 | public function getParseErrorMessage() |
|
61 |