pub struct ResponseReceiveKey<S: Response> { /* private fields */ }Expand description
Typed token held by the receiver to identify which request a response answers.
Implementations§
Source§impl<S: Response> ResponseReceiveKey<S>
impl<S: Response> ResponseReceiveKey<S>
Sourcepub fn new(request_id: GlobalRequestId) -> Self
pub fn new(request_id: GlobalRequestId) -> Self
Creates a ResponseReceiveKey tied to the given global request ID.
Sourcepub fn request_id(&self) -> GlobalRequestId
pub fn request_id(&self) -> GlobalRequestId
Returns the global request ID carried by this key.
Trait Implementations§
Source§impl<S: Clone + Response> Clone for ResponseReceiveKey<S>
impl<S: Clone + Response> Clone for ResponseReceiveKey<S>
Source§fn clone(&self) -> ResponseReceiveKey<S>
fn clone(&self) -> ResponseReceiveKey<S>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<S: PartialEq + Response> PartialEq for ResponseReceiveKey<S>
impl<S: PartialEq + Response> PartialEq for ResponseReceiveKey<S>
Source§fn eq(&self, other: &ResponseReceiveKey<S>) -> bool
fn eq(&self, other: &ResponseReceiveKey<S>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<S: Copy + Response> Copy for ResponseReceiveKey<S>
impl<S: Eq + Response> Eq for ResponseReceiveKey<S>
impl<S: Response> StructuralPartialEq for ResponseReceiveKey<S>
Auto Trait Implementations§
impl<S> Freeze for ResponseReceiveKey<S>
impl<S> RefUnwindSafe for ResponseReceiveKey<S>where
S: RefUnwindSafe,
impl<S> Send for ResponseReceiveKey<S>
impl<S> Sync for ResponseReceiveKey<S>
impl<S> Unpin for ResponseReceiveKey<S>where
S: Unpin,
impl<S> UnsafeUnpin for ResponseReceiveKey<S>
impl<S> UnwindSafe for ResponseReceiveKey<S>where
S: UnwindSafe,
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