pub struct Request {
pub method: String,
pub target: String,
pub version: String,
pub headers: Vec<(String, String)>,
pub body: Vec<u8>,
}Expand description
A parsed HTTP/1.x request.
Fields§
§method: StringGET, POST, PUT, DELETE, HEAD, or another verb (SOAP
uses POST exclusively; the REST PSM’s RestMethod maps from
this).
target: StringRequest target, exactly as sent (path + optional ?query), not
yet percent-decoded.
version: StringHTTP/1.0 or HTTP/1.1.
headers: Vec<(String, String)>Headers in receipt order; multiple values of the same name are kept as separate entries (RFC 7230 §3.2.2 allows a single comma-joined value instead — both are accepted on read, values are always looked up case-insensitively).
body: Vec<u8>The body, fully read (decoded out of chunked framing if the request used it).
Implementations§
Source§impl Request
impl Request
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Request
impl RefUnwindSafe for Request
impl Send for Request
impl Sync for Request
impl Unpin for Request
impl UnsafeUnpin for Request
impl UnwindSafe for Request
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more