class Cache {
/**
- * @var OC_Cache $user_cache
+ * @var Cache $user_cache
*/
static protected $user_cache;
/**
- * @var OC_Cache $global_cache
+ * @var Cache $global_cache
*/
static protected $global_cache;
/**
* get the global cache
- * @return OC_Cache
+ * @return Cache
*/
static public function getGlobalCache() {
if (!self::$global_cache) {
/**
* get the user cache
- * @return OC_Cache
+ * @return Cache
*/
static public function getUserCache() {
if (!self::$user_cache) {
/**
* clear the user cache of all entries starting with a prefix
- * @param string prefix (optional)
+ * @param string $prefix (optional)
* @return bool
*/
static public function clear($prefix='') {
return $user_cache->clear($prefix);
}
+ /**
+ * creates cache key based on the files given
+ * @param $files
+ * @return string
+ */
static public function generateCacheKeyFromFiles($files) {
$key = '';
sort($files);
class UserCache implements \OCP\ICache {
/**
- * @var OC\Cache\File $userCache
+ * @var \OC\Cache\File $userCache
*/
protected $userCache;
/**
* clear the user cache of all entries starting with a prefix
- * @param string prefix (optional)
+ * @param string $prefix (optional)
* @return bool
*/
public function clear($prefix = '') {
/**
* clear the user cache of all entries starting with a prefix
- * @param string prefix (optional)
+ * @param string $prefix (optional)
* @return bool
*/
public function clear($prefix = '');