src/Binary/StreamWriter.php
public function writeByteStream(Stream $stream, Stream $value)
    {
        $length = $value->getSize();

        $value->seek(0);
        $this->writeVarint($stream, $length);
        $stream->writeStream($value, $length);
    }
public function writeByteStream(Stream $stream, Stream $value)
    {
        $length = $value->getSize();

        $value->seek(0);
        $this->writeVarint($stream, $length);
        $stream->writeStream($value, $length);
    }
public function writeByteStream ( Stream $ stream , Stream $ value ) { $ length = $ value -> getSize ( ) ; $ value -> seek ( 0 ) ; $ this -> writeVarint ( $ stream , $ length ) ; $ stream -> writeStream ( $ value , $ length ) ; }
Encode a stream of bytes.

@param \Protobuf\Stream $stream
@param \Protobuf\Stream $value
Encode a stream of bytes .