#[non_exhaustive]pub struct HoopedHandler { /* private fields */ }Expand description
Handler that wrap Handler to let it use middlewares.
Implementations§
Source§impl HoopedHandler
impl HoopedHandler
Sourcepub fn hoops(&self) -> &Vec<Arc<dyn Handler>>
pub fn hoops(&self) -> &Vec<Arc<dyn Handler>>
Get a reference to the middlewares attached to this handler.
Sourcepub fn hoops_mut(&mut self) -> &mut Vec<Arc<dyn Handler>>
pub fn hoops_mut(&mut self) -> &mut Vec<Arc<dyn Handler>>
Get a mutable reference to the middlewares attached to this handler.
Trait Implementations§
Source§impl Clone for HoopedHandler
impl Clone for HoopedHandler
Source§impl Debug for HoopedHandler
impl Debug for HoopedHandler
Source§impl Handler for HoopedHandler
impl Handler for HoopedHandler
Source§fn handle<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
req: &'life1 mut Request,
depot: &'life2 mut Depot,
res: &'life3 mut Response,
ctrl: &'life4 mut FlowCtrl,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn handle<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
req: &'life1 mut Request,
depot: &'life2 mut Depot,
res: &'life3 mut Response,
ctrl: &'life4 mut FlowCtrl,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Handles one HTTP request.
Source§fn arc(self) -> ArcHandlerwhere
Self: Sized,
fn arc(self) -> ArcHandlerwhere
Self: Sized,
Wrap to
ArcHandler.Source§fn hooped(self) -> HoopedHandlerwhere
Self: Sized,
fn hooped(self) -> HoopedHandlerwhere
Self: Sized,
Wraps this handler in a
HoopedHandler.Auto Trait Implementations§
impl !RefUnwindSafe for HoopedHandler
impl !UnwindSafe for HoopedHandler
impl Freeze for HoopedHandler
impl Send for HoopedHandler
impl Sync for HoopedHandler
impl Unpin for HoopedHandler
impl UnsafeUnpin for HoopedHandler
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