Exemplo n.º 1
0
 /**
  * 返回指定路径中符合条件的文件夹列表  
  * @param string $path
  * @param string $sort
  * @return array
  */
 public static function folderList($path, $sort = 'ASC', $withPath = false)
 {
     $condition = array('folderonly' => true);
     $result = FileSystem::ls($path, $condition, $sort, $withPath);
     return $result;
 }
Exemplo n.º 2
0
 /**
  * 清空cache中所有项
  * @return 如果成功则返回 TRUE,失败则返回 FALSE。
  * @access public
  */
 public function flush()
 {
     $fileList = FileSystem::ls($this->cachePath, array(), 'asc', true);
     return FileSystem::rm($fileList);
 }