Struct tower_web::middleware::Identity [−][src]
pub struct Identity { /* fields omitted */ }A no-op middleware.
When wrapping a Service, the Identity middleware returns the provided
service without modifying it.
Methods
impl Identity[src]
impl IdentityTrait Implementations
impl Debug for Identity[src]
impl Debug for Identityfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Default for Identity[src]
impl Default for Identityimpl Clone for Identity[src]
impl Clone for Identityfn clone(&self) -> Identity[src]
fn clone(&self) -> IdentityReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)1.0.0
[src]Performs copy-assignment from source. Read more
impl<S: Service> Middleware<S> for Identity[src]
impl<S: Service> Middleware<S> for IdentityDecorates a Service, transforming either the request or the response.
type Request = S::Request
The wrapped service request type
type Response = S::Response
The wrapped service response type
type Error = S::Error
The wrapped service's error type
type Service = S
The wrapped service
fn wrap(&self, inner: S) -> Self::Service[src]
fn wrap(&self, inner: S) -> Self::ServiceWrap the given service with the middleware, returning a new service that has been decorated with the middleware. Read more
fn chain<T>(self, middleware: T) -> Chain<Self, T> where
T: Middleware<Self::Service>,
Self: Sized, [src]
fn chain<T>(self, middleware: T) -> Chain<Self, T> where
T: Middleware<Self::Service>,
Self: Sized, Return a new Middleware instance that applies both self and middleware to services being wrapped. Read more
impl<T> Chain<T> for Identity[src]
impl<T> Chain<T> for Identity