function Process::readPipes
Reads pipes, executes callback.
Parameters
bool $blocking Whether to use blocking calls or not:
bool $close Whether to close file handles or not:
2 calls to Process::readPipes()
- Process::updateStatus in vendor/
symfony/ process/ Process.php - Updates the status of the process, reads pipes.
- Process::wait in vendor/
symfony/ process/ Process.php - Waits for the process to terminate.
File
-
vendor/
symfony/ process/ Process.php, line 1416
Class
- Process
- Process is a thin wrapper around proc_* functions to easily start independent PHP processes.
Namespace
Symfony\Component\ProcessCode
private function readPipes(bool $blocking, bool $close) : void {
$result = $this->processPipes
->readAndWrite($blocking, $close);
$callback = $this->callback;
foreach ($result as $type => $data) {
if (3 !== $type) {
$callback(self::STDOUT === $type ? self::OUT : self::ERR, $data);
}
elseif (!isset($this->fallbackStatus['signaled'])) {
$this->fallbackStatus['exitcode'] = (int) $data;
}
}
}