Struct ntex_service::dev::MapConfig
source · [−]pub struct MapConfig<A, R, F, C, C2> { /* private fields */ }Expand description
map_config() adapter service factory
Trait Implementations
sourceimpl<A, R, F, C, C2> ServiceFactory<R, C> for MapConfig<A, R, F, C, C2> where
A: ServiceFactory<R, C2>,
F: Fn(C) -> C2,
impl<A, R, F, C, C2> ServiceFactory<R, C> for MapConfig<A, R, F, C, C2> where
A: ServiceFactory<R, C2>,
F: Fn(C) -> C2,
type Response = <A as ServiceFactory<R, C2>>::Response
type Response = <A as ServiceFactory<R, C2>>::Response
Responses given by the service
type Error = <A as ServiceFactory<R, C2>>::Error
type Error = <A as ServiceFactory<R, C2>>::Error
Errors produced by the service
type Service = <A as ServiceFactory<R, C2>>::Service
type Service = <A as ServiceFactory<R, C2>>::Service
The Service value created by this factory
type InitError = <A as ServiceFactory<R, C2>>::InitError
type InitError = <A as ServiceFactory<R, C2>>::InitError
Errors produced while building a service.
type Future = <A as ServiceFactory<R, C2>>::Future
type Future = <A as ServiceFactory<R, C2>>::Future
The future of the ServiceFactory instance.
sourcefn new_service(&self, cfg: C) -> Self::Future
fn new_service(&self, cfg: C) -> Self::Future
Create and return a new service value asynchronously.
sourcefn map<F, Res>(self, f: F) -> MapServiceFactory<Self, F, Req, Res, Cfg> where
Self: Sized,
F: FnMut(Self::Response) -> Res + Clone,
fn map<F, Res>(self, f: F) -> MapServiceFactory<Self, F, Req, Res, Cfg> where
Self: Sized,
F: FnMut(Self::Response) -> Res + Clone,
Map this service’s output to a different type, returning a new service of the resulting type. Read more
sourcefn map_err<F, E>(self, f: F) -> MapErrServiceFactory<Self, Req, Cfg, F, E> where
Self: Sized,
F: Fn(Self::Error) -> E + Clone,
fn map_err<F, E>(self, f: F) -> MapErrServiceFactory<Self, Req, Cfg, F, E> where
Self: Sized,
F: Fn(Self::Error) -> E + Clone,
Map this service’s error to a different error, returning a new service.
sourcefn map_init_err<F, E>(self, f: F) -> MapInitErr<Self, Req, Cfg, F, E> where
Self: Sized,
F: Fn(Self::InitError) -> E + Clone,
fn map_init_err<F, E>(self, f: F) -> MapInitErr<Self, Req, Cfg, F, E> where
Self: Sized,
F: Fn(Self::InitError) -> E + Clone,
Map this factory’s init error to a different error, returning a new service.
Auto Trait Implementations
impl<A, R, F, C, C2> RefUnwindSafe for MapConfig<A, R, F, C, C2> where
A: RefUnwindSafe,
C: RefUnwindSafe,
C2: RefUnwindSafe,
F: RefUnwindSafe,
R: RefUnwindSafe,
impl<A, R, F, C, C2> Send for MapConfig<A, R, F, C, C2> where
A: Send,
C: Send,
C2: Send,
F: Send,
R: Send,
impl<A, R, F, C, C2> Sync for MapConfig<A, R, F, C, C2> where
A: Sync,
C: Sync,
C2: Sync,
F: Sync,
R: Sync,
impl<A, R, F, C, C2> Unpin for MapConfig<A, R, F, C, C2> where
A: Unpin,
C: Unpin,
C2: Unpin,
F: Unpin,
R: Unpin,
impl<A, R, F, C, C2> UnwindSafe for MapConfig<A, R, F, C, C2> where
A: UnwindSafe,
C: UnwindSafe,
C2: UnwindSafe,
F: UnwindSafe,
R: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
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
sourceimpl<T, Req, Cfg> IntoServiceFactory<T, Req, Cfg> for T where
T: ServiceFactory<Req, Cfg>,
impl<T, Req, Cfg> IntoServiceFactory<T, Req, Cfg> for T where
T: ServiceFactory<Req, Cfg>,
sourcefn into_factory(self) -> T
fn into_factory(self) -> T
Convert Self to a ServiceFactory