1 | <?php |
||
18 | class Entry implements ResponseInterface, \ArrayAccess |
||
19 | { |
||
20 | /** |
||
21 | * @var array |
||
22 | */ |
||
23 | protected $data = null; |
||
24 | |||
25 | /** |
||
26 | * @var array |
||
27 | */ |
||
28 | protected $metadata = null; |
||
29 | |||
30 | /** |
||
31 | * Entry constructor. |
||
32 | * |
||
33 | * @param $data |
||
34 | */ |
||
35 | 22 | public function __construct($data) |
|
39 | |||
40 | /** |
||
41 | * Get the entry data |
||
42 | * |
||
43 | * @return array |
||
44 | */ |
||
45 | 6 | public function getData() |
|
49 | |||
50 | /** |
||
51 | * Get the entry metadata |
||
52 | * |
||
53 | * @return array |
||
54 | */ |
||
55 | 6 | public function getMetaData() |
|
59 | |||
60 | 2 | public function offsetExists($offset) |
|
64 | |||
65 | 2 | public function offsetGet($offset) |
|
69 | |||
70 | 2 | public function offsetSet($offset, $value) |
|
74 | |||
75 | 2 | public function offsetUnset($offset) |
|
79 | |||
80 | 2 | public function __get($name) |
|
88 | |||
89 | 2 | public function __set($name, $value) |
|
93 | |||
94 | /** |
||
95 | * Gets the object representation of this entry |
||
96 | * |
||
97 | * @return object |
||
98 | */ |
||
99 | 4 | public function jsonSerialize() |
|
106 | } |