\OCP\Files\CacheIWatcher

check the storage backends for updates and change the cache accordingly

Summary

Methods
Constants
setPolicy()
getPolicy()
checkUpdate()
update()
needsUpdate()
cleanFolder()
CHECK_NEVER
CHECK_ONCE
CHECK_ALWAYS
No protected methods found
N/A
No private methods found
N/A

Constants

CHECK_NEVER

CHECK_NEVER

CHECK_ONCE

CHECK_ONCE

CHECK_ALWAYS

CHECK_ALWAYS

Methods

setPolicy()

setPolicy(integer  $policy) 

Parameters

integer $policy

either IWatcher::CHECK_NEVER, IWatcher::CHECK_ONCE, IWatcher::CHECK_ALWAYS

getPolicy()

getPolicy() : integer

Returns

integer —

either IWatcher::CHECK_NEVER, IWatcher::CHECK_ONCE, IWatcher::CHECK_ALWAYS

checkUpdate()

checkUpdate(string  $path, \OCP\Files\Cache\ICacheEntry|null  $cachedEntry = null) : boolean

check $path for updates and update if needed

Parameters

string $path
\OCP\Files\Cache\ICacheEntry|null $cachedEntry

Returns

boolean —

true if path was updated

update()

update(string  $path, \OCP\Files\Cache\ICacheEntry  $cachedData) 

Update the cache for changes to $path

Parameters

string $path
\OCP\Files\Cache\ICacheEntry $cachedData

needsUpdate()

needsUpdate(string  $path, \OCP\Files\Cache\ICacheEntry  $cachedData) : boolean

Check if the cache for $path needs to be updated

Parameters

string $path
\OCP\Files\Cache\ICacheEntry $cachedData

Returns

boolean

cleanFolder()

cleanFolder(string  $path) 

remove deleted files in $path from the cache

Parameters

string $path