Struct AsyncFilterLayer
pub struct AsyncFilterLayer<U> { /* private fields */ }
Conditionally dispatch requests to the inner service based on an asynchronous predicate.
This Layer produces instances of the AsyncFilter service.
Implementations
impl<U> AsyncFilterLayer<U>
const fn new(predicate: U) -> SelfReturns a new layer that produces
AsyncFilterservices with the givenAsyncPredicate.
Trait Implementations
impl<U: Clone> Clone for AsyncFilterLayer<U>
fn clone(&self) -> AsyncFilterLayer<U>
impl<U: Clone, S> Layer<S> for AsyncFilterLayer<U>
type Service = AsyncFilter<S, U>;fn layer(&self, service: S) -> Self::Service
impl<U: Debug> Debug for AsyncFilterLayer<U>
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Auto Trait Implementations
impl<U> Freeze for AsyncFilterLayer<U>
where
U: Freeze,
impl<U> RefUnwindSafe for AsyncFilterLayer<U>
where
U: RefUnwindSafe,
impl<U> Send for AsyncFilterLayer<U>
where
U: Send,
impl<U> Sync for AsyncFilterLayer<U>
where
U: Sync,
impl<U> Unpin for AsyncFilterLayer<U>
where
U: Unpin,
impl<U> UnsafeUnpin for AsyncFilterLayer<U>
where
U: UnsafeUnpin,
impl<U> UnwindSafe for AsyncFilterLayer<U>
where
U: UnwindSafe,
Blanket Implementations
impl<T> Any for AsyncFilterLayer<U>
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for AsyncFilterLayer<U>
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for AsyncFilterLayer<U>
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> CloneToUninit for AsyncFilterLayer<U>
where
T: Clone,
unsafe fn clone_to_uninit(&self, dest: *mut u8)
impl<T> From<T> for AsyncFilterLayer<U>
fn from(t: T) -> TReturns the argument unchanged.
impl<T> Instrument for AsyncFilterLayer<U>
impl<T> ToOwned for AsyncFilterLayer<U>
where
T: Clone,
type Owned = T;fn to_owned(&self) -> Tfn clone_into(&self, target: &mut T)
impl<T> WithSubscriber for AsyncFilterLayer<U>
impl<T, U> Into<U> for AsyncFilterLayer<U>
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for AsyncFilterLayer<U>
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for AsyncFilterLayer<U>
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>