pub struct ReconStrat<S> { /* private fields */ }
Expand description
Reconnection strategy
You should probably add a timeout before reconnecting
Implementations§
Source§impl<S> ReconStrat<S>
impl<S> ReconStrat<S>
Sourcepub fn new<F>(f: F) -> ReconStrat<S>
pub fn new<F>(f: F) -> ReconStrat<S>
Expects the following fn:
ⓘ
async fn new_stream(error_count: usize) -> io::Result<S>;
Auto Trait Implementations§
impl<S> Freeze for ReconStrat<S>
impl<S> !RefUnwindSafe for ReconStrat<S>
impl<S> Send for ReconStrat<S>
impl<S> !Sync for ReconStrat<S>
impl<S> Unpin for ReconStrat<S>
impl<S> !UnwindSafe for ReconStrat<S>
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