pub struct Pending<P: PeerId> { /* private fields */ }Expand description
A request waiting in a Queue for the application’s answer.
Dropping it without an answer rejects the request.
Implementations§
Source§impl<P: PeerId> Pending<P>
impl<P: PeerId> Pending<P>
Sourcepub fn request(&self) -> &PeerRequest<P>
pub fn request(&self) -> &PeerRequest<P>
Returns the request to answer.
Sourcepub fn admit(self, authorization: impl Into<Authorization>)
pub fn admit(self, authorization: impl Into<Authorization>)
Admits the peer with authorization, such as a Grant.
Does nothing if the node no longer waits, for example after its decide timeout.
Trait Implementations§
Auto Trait Implementations§
impl<P> Freeze for Pending<P>where
P: Freeze,
impl<P> RefUnwindSafe for Pending<P>where
P: RefUnwindSafe,
impl<P> Send for Pending<P>
impl<P> Sync for Pending<P>
impl<P> Unpin for Pending<P>where
P: Unpin,
impl<P> UnsafeUnpin for Pending<P>where
P: UnsafeUnpin,
impl<P> UnwindSafe for Pending<P>where
P: 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