pub struct ErrorHandlerMiddleware { /* private fields */ }
Expand description
Error handling middleware
Implementations§
Source§impl ErrorHandlerMiddleware
impl ErrorHandlerMiddleware
Sourcepub fn with_config(config: ErrorHandlerConfig) -> Self
pub fn with_config(config: ErrorHandlerConfig) -> Self
Create with custom configuration
Sourcepub fn with_panic_details(self, include: bool) -> Self
pub fn with_panic_details(self, include: bool) -> Self
Enable panic details in responses (use only in development)
Sourcepub fn with_logging(self, enable: bool) -> Self
pub fn with_logging(self, enable: bool) -> Self
Enable error logging
Trait Implementations§
Source§impl Debug for ErrorHandlerMiddleware
impl Debug for ErrorHandlerMiddleware
Source§impl Default for ErrorHandlerMiddleware
impl Default for ErrorHandlerMiddleware
Source§impl Middleware for ErrorHandlerMiddleware
impl Middleware for ErrorHandlerMiddleware
Source§fn handle(&self, request: ElifRequest, next: Next) -> NextFuture<'static>
fn handle(&self, request: ElifRequest, next: Next) -> NextFuture<'static>
Handle the request and call the next middleware in the chain
Auto Trait Implementations§
impl Freeze for ErrorHandlerMiddleware
impl RefUnwindSafe for ErrorHandlerMiddleware
impl Send for ErrorHandlerMiddleware
impl Sync for ErrorHandlerMiddleware
impl Unpin for ErrorHandlerMiddleware
impl UnwindSafe for ErrorHandlerMiddleware
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more