Struct RedirectFn

pub struct RedirectFn<F> { /* private fields */ }

A redirection Policy created from a closure.

See redirect_fn for more details.

Trait Implementations

impl<B, E, F> Policy<B, E> for RedirectFn<F> where F: FnMut(&Attempt<'_>) -> Result<Action, E>,

fn redirect(&mut self, attempt: &Attempt<'_>) -> Result<Action, E>

impl<F> Debug for RedirectFn<F>

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl<F: Clone> Clone for RedirectFn<F>

fn clone(&self) -> Self

impl<F: Copy> Copy for RedirectFn<F>

Auto Trait Implementations

impl<F> Freeze for RedirectFn<F> where F: Freeze,

impl<F> RefUnwindSafe for RedirectFn<F> where F: RefUnwindSafe,

impl<F> Send for RedirectFn<F> where F: Send,

impl<F> Sync for RedirectFn<F> where F: Sync,

impl<F> Unpin for RedirectFn<F> where F: Unpin,

impl<F> UnsafeUnpin for RedirectFn<F> where F: UnsafeUnpin,

impl<F> UnwindSafe for RedirectFn<F> where F: UnwindSafe,

Blanket Implementations

impl<T> Any for RedirectFn<F> where T: 'static + ?Sized,

impl<T> Borrow<T> for RedirectFn<F> where T: ?Sized,

impl<T> BorrowMut<T> for RedirectFn<F> where T: ?Sized,

impl<T> CloneToUninit for RedirectFn<F> where T: Clone,

impl<T> From<T> for RedirectFn<F>

impl<T> Instrument for RedirectFn<F>

impl<T> PolicyExt for RedirectFn<F> where T: ?Sized,

impl<T> ToOwned for RedirectFn<F> where T: Clone,

impl<T> WithSubscriber for RedirectFn<F>

impl<T, U> Into<U> for RedirectFn<F> where U: From<T>,

impl<T, U> TryFrom<U> for RedirectFn<F> where U: Into<T>,

impl<T, U> TryInto<U> for RedirectFn<F> where U: TryFrom<T>,