Struct AsyncFilter
struct AsyncFilter<T, U> { ... }
Conditionally dispatch requests to the inner service based on an asynchronous predicate.
Implementations
impl<T, U> AsyncFilter<T, U>
const fn new(inner: T, predicate: U) -> SelfReturns a new
AsyncFilterservice wrappinginner.fn layer(predicate: U) -> FilterLayer<U>Returns a new
Layerthat wraps services with anAsyncFilterservice with the givenAsyncPredicate.async fn check<R>(self: &mut Self, request: R) -> Result<<U as >::Request, BoxError> where U: AsyncPredicate<R>Check a
Requestvalue against this filter's predicate.fn get_ref(self: &Self) -> &TGet a reference to the inner service
fn get_mut(self: &mut Self) -> &mut TGet a mutable reference to the inner service
fn into_inner(self: Self) -> TConsume
self, returning the inner service
impl<M, S, Target, Request> MakeService for AsyncFilter<T, U>
fn poll_ready(self: &mut Self, cx: &mut Context<'_>) -> Poll<Result<(), <M as MakeService<Target, Request>>::MakeError>>fn make_service(self: &mut Self, target: Target) -> <M as MakeService<Target, Request>>::Future
impl<T> Any for AsyncFilter<T, U>
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for AsyncFilter<T, U>
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for AsyncFilter<T, U>
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> CloneToUninit for AsyncFilter<T, U>
unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)
impl<T> From for AsyncFilter<T, U>
fn from(t: T) -> TReturns the argument unchanged.
impl<T> Instrument for AsyncFilter<T, U>
impl<T> ToOwned for AsyncFilter<T, U>
fn to_owned(self: &Self) -> Tfn clone_into(self: &Self, target: &mut T)
impl<T> WithSubscriber for AsyncFilter<T, U>
impl<T, Request> ServiceExt for AsyncFilter<T, U>
impl<T, U> Freeze for AsyncFilter<T, U>
impl<T, U> Into for AsyncFilter<T, U>
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> RefUnwindSafe for AsyncFilter<T, U>
impl<T, U> Send for AsyncFilter<T, U>
impl<T, U> Sync for AsyncFilter<T, U>
impl<T, U> TryFrom for AsyncFilter<T, U>
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for AsyncFilter<T, U>
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>
impl<T, U> Unpin for AsyncFilter<T, U>
impl<T, U> UnwindSafe for AsyncFilter<T, U>
impl<T, U, Request> Service for AsyncFilter<T, U>
fn poll_ready(self: &mut Self, cx: &mut Context<'_>) -> Poll<Result<(), <Self as >::Error>>fn call(self: &mut Self, request: Request) -> <Self as >::Future
impl<T: $crate::clone::Clone, U: $crate::clone::Clone> Clone for AsyncFilter<T, U>
fn clone(self: &Self) -> AsyncFilter<T, U>
impl<T: $crate::fmt::Debug, U: $crate::fmt::Debug> Debug for AsyncFilter<T, U>
fn fmt(self: &Self, f: &mut $crate::fmt::Formatter<'_>) -> $crate::fmt::Result