Worker::shutdown
PHP function
Edit on GitHub ✎
(PECL pthreads >= 2.0.0)
Shutdown the worker
Description
Worker::shutdown(): bool
Shuts down the worker after executing all of the stacked tasks.
Parameters Parameters
Return Values
Success
Examples
Shutdown the referenced worker
php
<?php
$my = new Worker();
$my->start();
/* stack/execute tasks */
var_dump($my->shutdown());The above example will output:
output
bool(true)