public function terminate()
    {
        if ($socket = end($this->sockets)) {
            // Quit the worker
            fwrite($socket, PHP_EOL);
        }

        // Return the process ID
        return key($this->sockets);
    }
public function terminate()
    {
        if ($socket = end($this->sockets)) {
            // Quit the worker
            fwrite($socket, PHP_EOL);
        }

        // Return the process ID
        return key($this->sockets);
    }
public function terminate ( ) { if ( $ socket = end ( $ this -> sockets ) ) { // Quit the worker fwrite ( $ socket , PHP_EOL ) ; } // Return the process ID return key ( $ this -> sockets ) ; }
Stop a worker process.

@return  int  A process ID to be stopped
Stop a worker process .