1 | <?php |
||
8 | class Result |
||
9 | { |
||
10 | /** |
||
11 | * Input data. |
||
12 | * |
||
13 | * @var string |
||
14 | */ |
||
15 | private $raw; |
||
16 | |||
17 | /** |
||
18 | * Decoded data. |
||
19 | * |
||
20 | * @var array |
||
21 | */ |
||
22 | private $decoded = []; |
||
23 | |||
24 | /** |
||
25 | * Result constructor. |
||
26 | * |
||
27 | * @param string $raw |
||
28 | */ |
||
29 | public function __construct($raw) |
||
34 | |||
35 | /** |
||
36 | * @return string |
||
37 | */ |
||
38 | public function getRaw() |
||
42 | |||
43 | /** |
||
44 | * @return array |
||
45 | */ |
||
46 | public function getDecoded() |
||
50 | |||
51 | /** |
||
52 | * Decode json encoded string. |
||
53 | * |
||
54 | * @param string $raw |
||
55 | * @return array |
||
56 | */ |
||
57 | private function decode($raw) |
||
67 | } |