\OCP\Files\StorageILockingStorage

Storage backends that require explicit locking

Storage backends implementing this interface do not need to implement their own locking implementation but should use the provided lockingprovider instead The implementation of the locking methods only need to map internal storage paths to "lock keys"

Summary

Methods
Constants
acquireLock()
releaseLock()
changeLock()
No constants found
No protected methods found
N/A
No private methods found
N/A

Methods

acquireLock()

acquireLock(string  $path, integer  $type, \OCP\Lock\ILockingProvider  $provider) 

Parameters

string $path

The path of the file to acquire the lock for

integer $type

\OCP\Lock\ILockingProvider::LOCK_SHARED or \OCP\Lock\ILockingProvider::LOCK_EXCLUSIVE

\OCP\Lock\ILockingProvider $provider

Throws

\OCP\Lock\LockedException

releaseLock()

releaseLock(string  $path, integer  $type, \OCP\Lock\ILockingProvider  $provider) 

Parameters

string $path

The path of the file to acquire the lock for

integer $type

\OCP\Lock\ILockingProvider::LOCK_SHARED or \OCP\Lock\ILockingProvider::LOCK_EXCLUSIVE

\OCP\Lock\ILockingProvider $provider

changeLock()

changeLock(string  $path, integer  $type, \OCP\Lock\ILockingProvider  $provider) 

Parameters

string $path

The path of the file to change the lock for

integer $type

\OCP\Lock\ILockingProvider::LOCK_SHARED or \OCP\Lock\ILockingProvider::LOCK_EXCLUSIVE

\OCP\Lock\ILockingProvider $provider

Throws

\OCP\Lock\LockedException