Mutex::trylockAttempt to Acquire Mutex Description
final
public
static
boolean
Mutex::trylock
(
long
$mutex
)Attempt to lock the Mutex for the caller without blocking if the Mutex is owned (locked) by another Thread. Parameters
Return ValuesA boolean indication of success. Examples
Example #1 Mutex Locking and Unlocking
<?php The above example will output: bool(true) bool(true) |