pub struct Info<'a> {
route: &'a Route,
}
Expand description
Information about the request/response that can be used to prepare log lines.
Fields§
§route: &'a Route
Implementations§
source§impl<'a> Info<'a>
impl<'a> Info<'a>
sourcepub fn remote_addr(&self) -> Option<SocketAddr>
pub fn remote_addr(&self) -> Option<SocketAddr>
View the remote SocketAddr
of the request.
sourcepub fn user_agent(&self) -> Option<&str>
pub fn user_agent(&self) -> Option<&str>
View the user agent of the request.
sourcepub fn request_headers(&self) -> &HeaderMap
pub fn request_headers(&self) -> &HeaderMap
View the request headers.
Auto Trait Implementations§
impl<'a> Freeze for Info<'a>
impl<'a> !RefUnwindSafe for Info<'a>
impl<'a> Send for Info<'a>
impl<'a> Sync for Info<'a>
impl<'a> Unpin for Info<'a>
impl<'a> !UnwindSafe for Info<'a>
Blanket Implementations§
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