public function toString(RequestInterface $request)
    {
        $string = sprintf(
            "%s %s HTTP/%s\n",
            $request->getMethod(),
            $request->getRequestTarget(),
            $request->getProtocolVersion()
        );

        $string .= $this->headersAndBody($request);

        return $string;
    }
public function toString(RequestInterface $request)
    {
        $string = sprintf(
            "%s %s HTTP/%s\n",
            $request->getMethod(),
            $request->getRequestTarget(),
            $request->getProtocolVersion()
        );

        $string .= $this->headersAndBody($request);

        return $string;
    }
public function toString ( RequestInterface $ request ) { $ string = sprintf ( "%s %s HTTP/%s\n" , $ request -> getMethod ( ) , $ request -> getRequestTarget ( ) , $ request -> getProtocolVersion ( ) ) ; $ string .= $ this -> headersAndBody ( $ request ) ; return $ string ; }
Generate a pretty PS7 request.

@param RequestInterface $request

@return string
Generate a pretty PS7 request .