Struct tower_web::middleware::log::LogMiddleware [−][src]
pub struct LogMiddleware { /* fields omitted */ }Decorate a service by logging all received requests.
Methods
impl LogMiddleware[src]
impl LogMiddlewarepub fn new(target: &'static str) -> LogMiddleware[src]
pub fn new(target: &'static str) -> LogMiddlewareCreate a new LogMiddleware instance configured to use target.
Trait Implementations
impl Debug for LogMiddleware[src]
impl Debug for LogMiddlewarefn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl<S, RequestBody, ResponseBody> Middleware<S> for LogMiddleware where
S: Service<Request = Request<RequestBody>, Response = Response<ResponseBody>>,
S::Error: Error, [src]
impl<S, RequestBody, ResponseBody> Middleware<S> for LogMiddleware where
S: Service<Request = Request<RequestBody>, Response = Response<ResponseBody>>,
S::Error: Error, type Request = Request<RequestBody>
The wrapped service request type
type Response = Response<ResponseBody>
The wrapped service response type
type Error = S::Error
The wrapped service's error type
type Service = LogService<S>
The wrapped service
fn wrap(&self, service: S) -> Self::Service[src]
fn wrap(&self, service: 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
Auto Trait Implementations
impl Send for LogMiddleware
impl Send for LogMiddlewareimpl Sync for LogMiddleware
impl Sync for LogMiddleware