Worker::isWorking
(PECL pthreads >= 0.37)
Worker::isWorking — State Detection
Beschreibung
final public boolean Worker::isWorking
( void
)
Tell if a Worker is executing Stackables
Parameter-Liste
Diese Funktion hat keine Parameter.
Rückgabewerte
A boolean indication of state
Beispiele
Beispiel #1 Detect the state of a Worker
<?php
class My extends Worker {
public function run() {
/* ... */
}
}
$my = new My();
$my->start();
/* ... */
if ($my->isWorking()) {
/* ... the Worker is busy executing another object */
}
?>
There are no user contributed notes for this page.
