public static function serialize(RequestInterface $request): string
    {
        return self::requestLine($request).self::headers($request).$request->getBody();
    }
public static function serialize(RequestInterface $request): string
    {
        return self::requestLine($request).self::headers($request).$request->getBody();
    }
public static function serialize ( RequestInterface $ request ) : string { return self :: requestLine ( $ request ) . self :: headers ( $ request ) . $ request -> getBody ( ) ; }
Returns the string representation of an HTTP request.

@param RequestInterface $request Request to convert to a string.

@return string
Returns the string representation of an HTTP request .