Worker::shutdown
(PECL pthreads >= 2.0.0)
Worker::shutdown — 关闭 Worker
说明
public Worker::shutdown(): bool
在执行完已入栈对象之后,关闭这个 Worker 对象
参数
此函数没有参数。
返回值
成功时返回 true
, 或者在失败时返回 false
。
范例
示例 #1 关闭 Worker
<?php
$my = new Worker();
$my->start();
/* 入栈和执行任务 */
var_dump($my->shutdown());
以上例程会输出:
bool(true)

User Contributed Notes
There are no user contributed notes for this page.