http_type/request/
type.rs

1use crate::*;
2
3/// HTTP request method.
4pub type RequestMethod = Method;
5/// The host part of an HTTP request.
6pub type RequestHost = String;
7/// The HTTP version.
8pub type RequestVersion = HttpVersion;
9/// The path portion of the request URL.
10pub type RequestPath = String;
11/// Key type used in the request query parameters.
12pub type RequestQuerysKey = String;
13/// Value type used in the request query parameters.
14pub type RequestQuerysValue = String;
15/// Optional value for a query parameter.
16pub type OptionRequestQuerysValue = Option<RequestQuerysValue>;
17/// All query parameters parsed from the request URL.
18pub type RequestQuerys = HashMapXxHash3_64<RequestQuerysKey, RequestQuerysValue>;
19/// The raw binary body of the request.
20pub type RequestBody = Vec<u8>;
21/// The request body as a UTF-8 string.
22pub type RequestBodyString = String;
23/// Key type used in the request headers.
24pub type RequestHeadersKey = String;
25/// A single value string for an HTTP request header.
26/// This represents one individual value that can be associated with a header key.
27pub type RequestHeadersValueItem = String;
28/// Optional value for a header string.
29pub type OptionRequestHeadersValueItem = Option<RequestHeadersValueItem>;
30/// A collection of values for a single HTTP request header.
31pub type RequestHeadersValue = VecDeque<RequestHeadersValueItem>;
32/// Optional value for a header.
33pub type OptionRequestHeadersValue = Option<RequestHeadersValue>;
34/// All headers sent with the HTTP request.
35pub type RequestHeaders = HashMapXxHash3_64<RequestHeadersKey, RequestHeadersValue>;
36/// The result type returned from a request reader handler.
37pub type RequestReaderHandleResult = Result<Request, RequestError>;
38/// Read guard for a `Request` wrapped in a `RwLock`.
39pub type RwLockReadGuardRequest<'a> = RwLockReadGuard<'a, Request>;
40/// Write guard for a `Request` wrapped in a `RwLock`.
41pub type RwLockWriteGuardRequest<'a> = RwLockWriteGuard<'a, Request>;