phasync
UnbufferedStream / __construct

Method

UnbufferedStream::__construct

Creates an empty stream, owned by the current coroutine.

Description#

public UnbufferedStream::__construct(
    int $bufferSize = 65536,
    float $deadlockTimeout = 60.0
)

Parameters#

$bufferSize int = 65536
The number of unread bytes after which append() waits for the reader
$deadlockTimeout float = 60.0
Seconds that read() and append() wait for the other side before throwing a TimeoutException