1 | <?php |
||
25 | class JsonReader extends ReaderAbstract |
||
26 | { |
||
27 | /** |
||
28 | * default json error |
||
29 | * |
||
30 | * @var array |
||
31 | * @access protected |
||
32 | * @staticvar |
||
33 | */ |
||
34 | protected static $error = [ |
||
35 | \JSON_ERROR_NONE => 'No error', |
||
36 | \JSON_ERROR_DEPTH => 'Maximum stack depth exceeded', |
||
37 | \JSON_ERROR_STATE_MISMATCH => 'State mismatch (invalid or malformed JSON)', |
||
38 | \JSON_ERROR_CTRL_CHAR => 'Control character error, possibly incorrectly encoded', |
||
39 | \JSON_ERROR_SYNTAX => 'Syntax error', |
||
40 | \JSON_ERROR_UTF8 => 'Malformed UTF-8 characters, possibly incorrectly encoded', |
||
41 | \JSON_ERROR_RECURSION => 'Recursion found', |
||
42 | \JSON_ERROR_INF_OR_NAN => 'NaN found', |
||
43 | \JSON_ERROR_UNSUPPORTED_TYPE => 'Unsupported type found', |
||
44 | ]; |
||
45 | |||
46 | /** |
||
47 | * {@inheritDoc} |
||
48 | */ |
||
49 | protected static function readFromFile($path) |
||
53 | |||
54 | /** |
||
55 | * {@inheritDoc} |
||
56 | */ |
||
57 | protected static function getError(/*# string */ $path)/*#: string */ |
||
64 | } |
||
65 |