pub struct Route {
pub container: SyncHashMap<String, Arc<Box<dyn Any>>>,
pub middleware: Vec<Box<dyn MiddleWare>>,
pub handlers: SyncHashMap<String, HandleBox>,
}Fields§
§container: SyncHashMap<String, Arc<Box<dyn Any>>>§middleware: Vec<Box<dyn MiddleWare>>§handlers: SyncHashMap<String, HandleBox>Implementations§
Trait Implementations§
Source§impl Handler for Route
impl Handler for Route
Source§fn check_continue(&self, _: (&Method, &RequestUri, &Headers)) -> StatusCode
fn check_continue(&self, _: (&Method, &RequestUri, &Headers)) -> StatusCode
Called when a Request includes a
Expect: 100-continue header. Read moreSource§fn on_connection_start(&self)
fn on_connection_start(&self)
This is run after a connection is received, on a per-connection basis (not a
per-request basis, as a connection with keep-alive may handle multiple
requests)
Source§fn on_connection_end(&self)
fn on_connection_end(&self)
This is run before a connection is closed, on a per-connection basis (not a
per-request basis, as a connection with keep-alive may handle multiple
requests)
Auto Trait Implementations§
impl !Freeze for Route
impl !RefUnwindSafe for Route
impl Send for Route
impl Sync for Route
impl Unpin for Route
impl !UnwindSafe for Route
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