chore: fix doc comments
Signed-off-by: Egor Lazarchuk <yegorlz@amazon.co.uk>
This commit is contained in:
committed by
ShadowCurse
parent
9e748fd2d9
commit
936b18fce6
@@ -251,8 +251,8 @@ impl Headers {
|
||||
|
||||
/// Parses a byte slice into a Headers structure for a HTTP request.
|
||||
///
|
||||
/// The byte slice is expected to have the following format: </br>
|
||||
/// * Request Header Lines "<header_line> CRLF"- Optional </br>
|
||||
/// The byte slice is expected to have the following format: <br/>
|
||||
/// * Request Header Lines "<header_line> CRLF"- Optional <br/>
|
||||
/// There can be any number of request headers, including none, followed by
|
||||
/// an extra sequence of Carriage Return and Line Feed.
|
||||
/// All header fields are parsed. However, only the ones present in the
|
||||
|
||||
@@ -166,11 +166,11 @@ pub struct Request {
|
||||
impl Request {
|
||||
/// Parses a byte slice into a HTTP Request.
|
||||
///
|
||||
/// The byte slice is expected to have the following format: </br>
|
||||
/// * Request Line: "GET SP Request-uri SP HTTP/1.0 CRLF" - Mandatory </br>
|
||||
/// * Request Headers "<headers> CRLF"- Optional </br>
|
||||
/// * Empty Line "CRLF" </br>
|
||||
/// * Entity Body - Optional </br>
|
||||
/// The byte slice is expected to have the following format: <br/>
|
||||
/// * Request Line: "GET SP Request-uri SP HTTP/1.0 CRLF" - Mandatory <br/>
|
||||
/// * Request Headers "`<headers>` CRLF"- Optional <br/>
|
||||
/// * Empty Line "CRLF" <br/>
|
||||
/// * Entity Body - Optional <br/>
|
||||
/// The request headers and the entity body are not parsed and None is returned because
|
||||
/// these are not used by the MMDS server.
|
||||
/// The only supported method is GET and the HTTP protocol is expected to be HTTP/1.0
|
||||
|
||||
@@ -209,7 +209,7 @@ impl ResponseHeaders {
|
||||
}
|
||||
|
||||
/// Sets the `Deprecation` header to be written in the HTTP response.
|
||||
/// https://tools.ietf.org/id/draft-dalal-deprecation-header-03.html
|
||||
/// <https://tools.ietf.org/id/draft-dalal-deprecation-header-03.html>
|
||||
#[allow(unused)]
|
||||
pub fn set_deprecation(&mut self) {
|
||||
self.deprecation = true;
|
||||
@@ -263,7 +263,7 @@ impl Response {
|
||||
/// status code is 1XX or 204. If needed, users can remove it by calling
|
||||
/// `set_content_length(None)`.
|
||||
///
|
||||
/// https://datatracker.ietf.org/doc/html/rfc9110#name-content-length
|
||||
/// <https://datatracker.ietf.org/doc/html/rfc9110#name-content-length>
|
||||
/// > A server MAY send a Content-Length header field in a response to a
|
||||
/// > HEAD request (Section 9.3.2); a server MUST NOT send Content-Length
|
||||
/// > in such a response unless its field value equals the decimal number
|
||||
|
||||
Reference in New Issue
Block a user