laravel / 10 / api / 10.x / illuminate / cache / hascachelock.html

HasCacheLock

trait HasCacheLock (View source)

Methods

Lock lock(string $name, int $seconds = 0, string|null $owner = null)

Get a lock instance.

Lock restoreLock(string $name, string $owner)

Restore a lock instance using the owner identifier.

Details

Lock lock(string $name, int $seconds = 0, string|null $owner = null)

Get a lock instance.

Parameters

string $name
int $seconds
string|null $owner

Return Value

Lock restoreLock(string $name, string $owner)

Restore a lock instance using the owner identifier.

Parameters

string $name
string $owner

Return Value

© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/10.x/Illuminate/Cache/HasCacheLock.html