PHP Class Icicle\Concurrent\Threading\Internal\Thread

Inheritance: extends Thread
Afficher le fichier Open project: icicleio/concurrent Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( resource $socket, callable $function, array $args = [] ) Creates a new thread object.
kill ( ) Sets a local variable to true so the running event loop can check for a kill signal.
run ( ) Runs the thread code and the initialized function.

Private Methods

Méthode Description
execute ( Channel $channel ) : Generator

Method Details

__construct() public méthode

Creates a new thread object.
public __construct ( resource $socket, callable $function, array $args = [] )
$socket resource IPC communication socket.
$function callable The function to execute in the thread.
$args array Arguments to pass to the function.

kill() public méthode

Sets a local variable to true so the running event loop can check for a kill signal.
public kill ( )

run() public méthode

Runs the thread code and the initialized function.
public run ( )