Total Complexity | 4 |
Total Lines | 31 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
15 | class SessionStateStorage implements StateStorageInterface |
||
16 | { |
||
17 | /** |
||
18 | * @var SessionInterface session object to be used. |
||
19 | * |
||
20 | * After the SessionStateStorage object is created, if you want to change this property, |
||
21 | * you should only assign it with a session object. |
||
22 | * |
||
23 | * If not set - application 'session' component will be used, but only, if it is available (e.g. in web application), |
||
24 | * otherwise - no session will be used and no data saving will be performed. |
||
25 | */ |
||
26 | private SessionInterface $session; |
||
27 | |||
28 | 10 | public function __construct(SessionInterface $session) |
|
31 | 10 | } |
|
32 | |||
33 | 2 | public function set(string $key, $value): void |
|
36 | 2 | } |
|
37 | |||
38 | 3 | public function get(string $key) |
|
41 | } |
||
42 | |||
43 | 1 | public function remove(string $key): void |
|
48 |