pub struct AsyncHandler<Req, State, Res> {
pub name: &'static str,
pub module_name: &'static str,
/* private fields */
}Expand description
A type-erased asynchronous handler held in an Arc.
It gives up the tower adaptation layer, holding the handler in an Arc<dyn Call>
and boxing only the future. This drops the extra Service boxing while staying
cloneable through a cheap Arc clone.
Fields§
§name: &'static strThe handler’s name.
module_name: &'static strThe module the handler was registered from.
Implementations§
Source§impl<Req, State, Res> AsyncHandler<Req, State, Res>
impl<Req, State, Res> AsyncHandler<Req, State, Res>
Trait Implementations§
Source§impl<Req, State, Res> Call<Req, State, Res> for AsyncHandler<Req, State, Res>
impl<Req, State, Res> Call<Req, State, Res> for AsyncHandler<Req, State, Res>
Auto Trait Implementations§
impl<Req, State, Res> !RefUnwindSafe for AsyncHandler<Req, State, Res>
impl<Req, State, Res> !UnwindSafe for AsyncHandler<Req, State, Res>
impl<Req, State, Res> Freeze for AsyncHandler<Req, State, Res>
impl<Req, State, Res> Send for AsyncHandler<Req, State, Res>
impl<Req, State, Res> Sync for AsyncHandler<Req, State, Res>
impl<Req, State, Res> Unpin for AsyncHandler<Req, State, Res>
impl<Req, State, Res> UnsafeUnpin for AsyncHandler<Req, State, Res>
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
impl<T> CloneAny for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoResponse<T> for Twhere
T: Send,
impl<T> IntoResponse<T> for Twhere
T: Send,
Source§fn into_response(self) -> T
fn into_response(self) -> T
Convert this value into a response.