1 | <?php |
||
17 | class PimpleCacheProvider implements ServiceProviderInterface |
||
18 | { |
||
19 | /** |
||
20 | * Registers cache services on the given container. |
||
21 | * |
||
22 | * @param Container $pimple A container instance |
||
23 | */ |
||
24 | public function register(Container $pimple) |
||
39 | |||
40 | /** |
||
41 | * Gets a cache object based on the backend requested |
||
42 | * |
||
43 | * @param $backend |
||
44 | * |
||
45 | * @return Closure|\Cmp\Cache\Infrastructure\ArrayCache |
||
46 | */ |
||
47 | private function getCache($backend) |
||
59 | |||
60 | /** |
||
61 | * Return a factory closure to build |
||
62 | * |
||
63 | * @param array|Redis $redis |
||
64 | * |
||
65 | * @return Closure |
||
66 | */ |
||
67 | private function getRedis($redis) |
||
80 | } |
||
81 |