1 | <?php |
||
28 | class ArrayAccessor implements \ArrayAccess |
||
29 | { |
||
30 | /** |
||
31 | * @var SessionInterface |
||
32 | */ |
||
33 | private $session; |
||
34 | |||
35 | /** |
||
36 | * ArrayAccessor constructor. |
||
37 | * |
||
38 | * @param SessionInterface $session |
||
39 | */ |
||
40 | 6 | public function __construct(SessionInterface $session) |
|
44 | |||
45 | /** |
||
46 | * Proxy function to SessionInterface |
||
47 | * |
||
48 | * @param string $method |
||
49 | * @param array $args |
||
50 | * |
||
51 | * @return mixed |
||
52 | */ |
||
53 | 1 | public function __call($method, $args) |
|
57 | |||
58 | /** |
||
59 | * {@inheritdoc} |
||
60 | */ |
||
61 | 1 | public function offsetExists($offset) |
|
65 | |||
66 | /** |
||
67 | * Offset to retrieve. |
||
68 | * |
||
69 | * @link http://php.net/manual/en/arrayaccess.offsetget.php |
||
70 | * |
||
71 | * @param string $offset |
||
72 | * @param null $default |
||
73 | * |
||
74 | * @return array|bool|float|int|mixed|string |
||
75 | */ |
||
76 | 1 | public function offsetGet($offset, $default = null) |
|
80 | |||
81 | /** |
||
82 | * {@inheritdoc} |
||
83 | */ |
||
84 | 1 | public function offsetSet($offset, $value) |
|
88 | |||
89 | /** |
||
90 | * {@inheritdoc} |
||
91 | */ |
||
92 | 1 | public function offsetUnset($offset) |
|
96 | } |