pub struct Callbacks {
pub on_download_complete: Option<BoxFuture<'static, ()>>,
pub on_error: Option<BoxFuture<'static, ()>>,
}
Expand description
Callbacks that will be executed on notifications.
If the connection lost, all callbacks will be checked whether they need to be executed once reconnected.
Fields
on_download_complete: Option<BoxFuture<'static, ()>>
Will trigger on Event::Complete
or Event::BtComplete
.
on_error: Option<BoxFuture<'static, ()>>
Will trigger on Event::Error
.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Callbacks
impl Send for Callbacks
impl !Sync for Callbacks
impl Unpin for Callbacks
impl !UnwindSafe for Callbacks
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more