The Mutex class
Introduction
(PECL pthreads < 3.0.0)
Warning
The Mutex class has been removed in pthreads v3.
The static methods contained in the Mutex class provide direct access to Posix Mutex functionality.
Class synopsis
Mutex {
/* Methods */
final public static create ([ bool $lock ] ) : int
final public static destroy ( int $mutex ) : bool
final public static lock ( int $mutex ) : bool
final public static trylock ( int $mutex ) : bool
final public static unlock ( int $mutex [, bool $destroy ] ) : bool}
Table of Contents
- Mutex::create — Create a Mutex
- Mutex::destroy — Destroy Mutex
- Mutex::lock — Acquire Mutex
- Mutex::trylock — Attempt to Acquire Mutex
- Mutex::unlock — Release Mutex
© 1997–2020 The PHP Documentation Group
Licensed under the Creative Commons Attribution License v3.0 or later.
https://www.php.net/manual/en/class.mutex.php