CacheFile::clear PHP Method

clear() public method

清除缓存
public clear ( ) : boolen
return boolen
    public function clear()
    {
        $path = $this->options['temp'];
        if ($dir = opendir($path)) {
            while ($file = readdir($dir)) {
                $check = is_dir($file);
                if (!$check) {
                    unlink($path . $file);
                }
            }
            closedir($dir);
            return true;
        }
    }