pub(crate) enum Callback<T, U> {
Retry(Option<Sender<Result<U, (Error, Option<T>)>>>),
NoRetry(Option<Sender<Result<U, Error>>>),
}
Variants§
Implementations§
source§impl<T, U> Callback<T, U>
impl<T, U> Callback<T, U>
pub(crate) fn is_canceled(&self) -> bool
pub(crate) fn poll_canceled(&mut self, cx: &mut Context<'_>) -> Poll<()>
pub(crate) fn send(self, val: Result<U, (Error, Option<T>)>)
pub(crate) async fn send_when( self, when: impl Future<Output = Result<U, (Error, Option<T>)>> + Unpin, )
Trait Implementations§
Auto Trait Implementations§
impl<T, U> Freeze for Callback<T, U>
impl<T, U> !RefUnwindSafe for Callback<T, U>
impl<T, U> Send for Callback<T, U>
impl<T, U> Sync for Callback<T, U>
impl<T, U> Unpin for Callback<T, U>
impl<T, U> !UnwindSafe for Callback<T, U>
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