pub struct Context {
pub session: Session,
pub request_id: String,
pub ip_address: String,
pub x_forwarded_for: String,
pub path: String,
pub user_agent: String,
pub accept_language: String,
}
Fields§
§session: Session
§request_id: String
§ip_address: String
§x_forwarded_for: String
§path: String
§user_agent: String
§accept_language: String
Implementations§
Source§impl Context
impl Context
pub fn new( session: Session, request_id: String, ip_address: String, x_forwarded_for: String, path: String, user_agent: String, accept_language: String, ) -> Self
pub fn clone(&self) -> Self
pub fn session(&self) -> Session
pub fn request_id(&self) -> &str
pub fn ip_address(&self) -> &str
pub fn x_forwarded_for(&self) -> &str
pub fn path(&self) -> &str
pub fn user_agent(&self) -> &str
pub fn accept_language(&self) -> &str
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl Send for Context
impl Sync for Context
impl Unpin for Context
impl UnwindSafe for Context
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request