芝麻web文件管理V1.00
编辑当前文件:/home/pulsehostuk9/www/cloud.pulsehost.co.uk/system/Managers/Cache.php
cacheManager === null) { $app = new Container(); Container::setInstance($app); $app->singleton('files', function () { return new \Illuminate\Filesystem\Filesystem(); }); $app->singleton('config', function () use ($sStoragePath) { return [ 'cache.default' => 'file', 'cache.stores.file' => [ 'driver' => 'file', 'path' => $sStoragePath ] ]; }); $cacheManager = new CacheManager($app); $this->cacheManager = $cacheManager->driver(); } } public function getInstance($sStorage) { return new self($sStorage); } public static function getPath() { return rtrim(trim(\Aurora\System\Api::DataPath()), '\\/') . '/temp/.cache/'; } public function set($key, $value) { $this->cacheManager->put($key, $value); } public function get($key) { return $this->cacheManager->get($key); } public function has($key) { $result = $this->cacheManager->get($key); return $result !== null; } public function delete($key) { return $this->cacheManager->forget($key); } }