Thread::isStarted
(PECL pthreads >= 2.0.0)
Thread::isStarted — State Detection
Description
public boolean Thread::isStarted
( void
)
Tell if the referenced Thread was started
Parameters
This function has no parameters.
Return Values
boolean indication of state
Examples
Example #1 Tell if the referenced Thread was started
<?php
$worker = new Worker();
$worker->start();
var_dump($worker->isStarted());
?>
The above example will output:
bool(true)
- PHP Руководство
- Функции по категориям
- Индекс функций
- Справочник функций
- Расширения для управления процессами программ
- pthreads
- Функция Thread::detach() - Execution
- Функция Thread::getCreatorId() - Identification
- Функция Thread::getCurrentThread() - Identification
- Функция Thread::getCurrentThreadId() - Identification
- Функция Thread::getThreadId() - Identification
- Функция Thread::globally() - Execution
- Функция Thread::isJoined() - State Detection
- Функция Thread::isStarted() - State Detection
- Функция Thread::join() - Synchronization
- Функция Thread::kill() - Execution
- Функция Thread::start() - Execution
Коментарии
Even if you kill() a thread, the isStarted() method will still return true.