1 | <?php |
||
12 | class FilesystemAdapter extends Adapter |
||
13 | { |
||
14 | private $filesystem; |
||
15 | |||
16 | 3 | public function __construct(Filesystem $filesystem) |
|
20 | |||
21 | /** |
||
22 | * Retrieve an item from the cache by key. |
||
23 | * |
||
24 | * @param string $key |
||
25 | * @param mixed $default |
||
26 | * |
||
27 | * @return mixed |
||
28 | */ |
||
29 | 1 | public function get(string $key, $default = null) |
|
44 | |||
45 | /** |
||
46 | * Store an item in the cache. |
||
47 | * |
||
48 | * @param string $key |
||
49 | * @param mixed $value |
||
50 | */ |
||
51 | 1 | public function store(string $key, $value): void |
|
61 | |||
62 | /** |
||
63 | * Remove an item from the cache. |
||
64 | * |
||
65 | * @param string $key |
||
66 | */ |
||
67 | 1 | public function forget(string $key): void |
|
74 | |||
75 | 3 | private function key(string $key): string |
|
79 | } |
||
80 |