pub struct ServerHandler<Ctl, Pub>(/* private fields */);
Expand description
Http2 connections handler
Implementations§
Source§impl<Ctl, Pub> ServerHandler<Ctl, Pub>where
Ctl: ServiceFactory<Control<Pub::Error>, Response = ControlAck> + 'static,
Ctl::Error: Debug,
Ctl::InitError: Debug,
Pub: ServiceFactory<Message, Response = ()> + 'static,
Pub::Error: Debug,
Pub::InitError: Debug,
impl<Ctl, Pub> ServerHandler<Ctl, Pub>where
Ctl: ServiceFactory<Control<Pub::Error>, Response = ControlAck> + 'static,
Ctl::Error: Debug,
Ctl::InitError: Debug,
Pub: ServiceFactory<Message, Response = ()> + 'static,
Pub::Error: Debug,
Pub::InitError: Debug,
Trait Implementations§
Source§impl<Ctl, Pub> Clone for ServerHandler<Ctl, Pub>
impl<Ctl, Pub> Clone for ServerHandler<Ctl, Pub>
Source§impl<F, Ctl, Pub> Service<Io<F>> for ServerHandler<Ctl, Pub>
impl<F, Ctl, Pub> Service<Io<F>> for ServerHandler<Ctl, Pub>
Source§type Error = ServerError<()>
type Error = ServerError<()>
Errors produced by the service when polling readiness or executing call.
Source§async fn call(
&self,
req: Io<F>,
_: ServiceCtx<'_, Self>,
) -> Result<Self::Response, Self::Error>
async fn call( &self, req: Io<F>, _: ServiceCtx<'_, Self>, ) -> Result<Self::Response, Self::Error>
Process the request and return the response asynchronously. Read more
Source§async fn ready(&self, ctx: ServiceCtx<'_, Self>) -> Result<(), Self::Error>
async fn ready(&self, ctx: ServiceCtx<'_, Self>) -> Result<(), Self::Error>
Returns when the service is able to process requests. Read more
Source§fn poll(&self, cx: &mut Context<'_>) -> Result<(), Self::Error>
fn poll(&self, cx: &mut Context<'_>) -> Result<(), Self::Error>
Polls service from the current task. Read more
Source§impl<Ctl, Pub> Service<IoBoxed> for ServerHandler<Ctl, Pub>where
Ctl: ServiceFactory<Control<Pub::Error>, Response = ControlAck> + 'static,
Ctl::Error: Debug,
Ctl::InitError: Debug,
Pub: ServiceFactory<Message, Response = ()> + 'static,
Pub::Error: Debug,
Pub::InitError: Debug,
impl<Ctl, Pub> Service<IoBoxed> for ServerHandler<Ctl, Pub>where
Ctl: ServiceFactory<Control<Pub::Error>, Response = ControlAck> + 'static,
Ctl::Error: Debug,
Ctl::InitError: Debug,
Pub: ServiceFactory<Message, Response = ()> + 'static,
Pub::Error: Debug,
Pub::InitError: Debug,
Source§type Error = ServerError<()>
type Error = ServerError<()>
Errors produced by the service when polling readiness or executing call.
Source§async fn call(
&self,
io: IoBoxed,
_: ServiceCtx<'_, Self>,
) -> Result<Self::Response, Self::Error>
async fn call( &self, io: IoBoxed, _: ServiceCtx<'_, Self>, ) -> Result<Self::Response, Self::Error>
Process the request and return the response asynchronously. Read more
Source§async fn ready(&self, ctx: ServiceCtx<'_, Self>) -> Result<(), Self::Error>
async fn ready(&self, ctx: ServiceCtx<'_, Self>) -> Result<(), Self::Error>
Returns when the service is able to process requests. Read more
Source§fn poll(&self, cx: &mut Context<'_>) -> Result<(), Self::Error>
fn poll(&self, cx: &mut Context<'_>) -> Result<(), Self::Error>
Polls service from the current task. Read more
Auto Trait Implementations§
impl<Ctl, Pub> Freeze for ServerHandler<Ctl, Pub>
impl<Ctl, Pub> !RefUnwindSafe for ServerHandler<Ctl, Pub>
impl<Ctl, Pub> !Send for ServerHandler<Ctl, Pub>
impl<Ctl, Pub> !Sync for ServerHandler<Ctl, Pub>
impl<Ctl, Pub> Unpin for ServerHandler<Ctl, Pub>
impl<Ctl, Pub> !UnwindSafe for ServerHandler<Ctl, Pub>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Svc, Req> IntoService<Svc, Req> for Svcwhere
Svc: Service<Req>,
impl<Svc, Req> IntoService<Svc, Req> for Svcwhere
Svc: Service<Req>,
Source§fn into_service(self) -> Svc
fn into_service(self) -> Svc
Convert to a
Service