1 | <?php |
||
4 | class StringDecoder |
||
5 | { |
||
6 | |||
7 | const RS = "\x1E"; |
||
8 | |||
9 | /** |
||
10 | * @var bool |
||
11 | */ |
||
12 | private $jsonDecodeAssoc; |
||
13 | |||
14 | /** |
||
15 | * @var int |
||
16 | */ |
||
17 | private $jsonDecodeDepth; |
||
18 | |||
19 | /** |
||
20 | * @var int |
||
21 | */ |
||
22 | private $jsonDecodeOptions; |
||
23 | |||
24 | 6 | public function __construct(bool $assoc = false, int $depth = 512, int $options = 0) |
|
30 | |||
31 | 6 | public function decode(string $content): iterable |
|
51 | |||
52 | /** |
||
53 | * @param string $jsonText |
||
54 | * @return mixed|ParseError |
||
55 | */ |
||
56 | 5 | private function jsonDecode(string $jsonText) |
|
65 | } |
||
66 |