downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

Worker::unstack> <Worker::stack
[edit] Last updated: Thu, 23 May 2013

view this page in

Worker::start

(PECL pthreads >= 0.36)

Worker::startExécution

Description

final public boolean Worker::start ([ long $options ] )

Démarre un nouveau Thread, exécute la méthode Worker::run puis, attend des Stackables.

Liste de paramètres

options

Un masque optionnel de constantes héritées, par défaut PTHREADS_INHERIT_ALL

Valeurs de retour

Un booléen indiquant le succès de l'opération.

Exemples

Exemple #1 Démarre les Workers

<?php
class My extends Worker {
    public function 
run() {
        
/** ... **/
    
}
}
$my = new My();
var_dump($my->start());
?>

L'exemple ci-dessus va afficher :

bool(true)



add a note add a note User Contributed Notes Worker::start - [0 notes]
There are no user contributed notes for this page.

 
show source | credits | sitemap | contact | advertising | mirror sites