Worker::isShutdown
(PECL pthreads >= 2.0.0)
Worker::isShutdown — State Detection
説明
public Worker::isShutdown ( ) : bool
Whether the worker has been shutdown or not.
パラメータ
この関数にはパラメータはありません。
返り値
Returns whether the worker has been shutdown or not.
例
例1 Detect the state of a worker
<?php$worker = new Worker();$worker->start();var_dump($worker->isShutdown());$worker->shutdown();var_dump($worker->isShutdown());
上の例の出力は以下となります。
bool(false) bool(true)