public getRequestLine ( ) : string | ||
return | string |
public function getRequestLine()
{
$requestUri = $this->uri->getPath() . ($this->uri->getQuery() ? '?' . $this->uri->getQuery() : '') . ($this->uri->getFragment() ? '#' . $this->uri->getFragment() : '');
return sprintf("%s %s %s\r\n", $this->method, $requestUri, $this->version);
}