LockHandler
class LockHandler
LockHandler class provides a simple abstraction to lock anything by means of a file lock.
A locked file is created based on the lock name when calling lock(). Other lock handlers will not be able to lock the same name until it is released (explicitly by calling release() or implicitly when the instance holding the lock is destroyed).
Methods
__construct(string $name, string|null $lockPath = null)
No description
bool
lock(bool $blocking = false)
Lock the resource.
release()
Release the resource.
Details
at line line 40
__construct(string $name, string|null $lockPath = null)
at line line 65
bool
lock(bool $blocking = false)
Lock the resource.
at line line 106
release()
Release the resource.