src/Generics/Client/HttpClientTrait.php
private function appendPayloadToRequest(MemoryStream $ms): MemoryStream
    {
        $this->payload->reset();
        
        while ($this->payload->ready()) {
            $ms->write($this->payload->read(1024));
        }
        
        $ms->reset();
        
        return $ms;
    }
private function appendPayloadToRequest(MemoryStream $ms): MemoryStream
    {
        $this->payload->reset();
        
        while ($this->payload->ready()) {
            $ms->write($this->payload->read(1024));
        }
        
        $ms->reset();
        
        return $ms;
    }
private function appendPayloadToRequest ( MemoryStream $ ms ) : MemoryStream { $ this -> payload -> reset ( ) ; while ( $ this -> payload -> ready ( ) ) { $ ms -> write ( $ this -> payload -> read ( 1024 ) ) ; } $ ms -> reset ( ) ; return $ ms ; }
Append the payload buffer to the request buffer

@param MemoryStream $ms
@return MemoryStream
@throws \Generics\Streams\StreamException
@throws \Generics\ResetException
Append the payload buffer to the request buffer