pub struct Context { /* private fields */ }Expand description
A context passed by the RPC server into a service.
Implementations§
Source§impl Context
impl Context
Sourcepub fn with_client(&self, client: ClientID) -> Self
pub fn with_client(&self, client: ClientID) -> Self
Extend the context with an additional client.
This makes a copy.
Sourcepub fn with_trace_id(&self, trace: TraceID) -> Self
pub fn with_trace_id(&self, trace: TraceID) -> Self
Extend the context with a trace ID.
This make a copy.
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