pub struct KeepAliveService<R, E, F> { /* private fields */ }Implementations§
Source§impl<R, E, F> KeepAliveService<R, E, F>where
F: Fn() -> E,
impl<R, E, F> KeepAliveService<R, E, F>where
F: Fn() -> E,
pub fn new(dur: Millis, f: F) -> KeepAliveService<R, E, F>
Trait Implementations§
Source§impl<R, E, F> Debug for KeepAliveService<R, E, F>
impl<R, E, F> Debug for KeepAliveService<R, E, F>
Source§impl<R, E, F> Service<R> for KeepAliveService<R, E, F>where
F: Fn() -> E,
impl<R, E, F> Service<R> for KeepAliveService<R, E, F>where
F: Fn() -> E,
Source§async fn ready(
&self,
_: ServiceCtx<'_, KeepAliveService<R, E, F>>,
) -> Result<(), <KeepAliveService<R, E, F> as Service<R>>::Error>
async fn ready( &self, _: ServiceCtx<'_, KeepAliveService<R, E, F>>, ) -> Result<(), <KeepAliveService<R, E, F> as Service<R>>::Error>
Returns when the service is able to process requests. Read more
Source§fn poll(
&self,
cx: &mut Context<'_>,
) -> Result<(), <KeepAliveService<R, E, F> as Service<R>>::Error>
fn poll( &self, cx: &mut Context<'_>, ) -> Result<(), <KeepAliveService<R, E, F> as Service<R>>::Error>
Polls service from the current task. Read more
Source§async fn call(
&self,
req: R,
_: ServiceCtx<'_, KeepAliveService<R, E, F>>,
) -> Result<R, E>
async fn call( &self, req: R, _: ServiceCtx<'_, KeepAliveService<R, E, F>>, ) -> Result<R, E>
Process the request and return the response asynchronously. Read more
Auto Trait Implementations§
impl<R, E, F> !Freeze for KeepAliveService<R, E, F>
impl<R, E, F> !RefUnwindSafe for KeepAliveService<R, E, F>
impl<R, E, F> Send for KeepAliveService<R, E, F>
impl<R, E, F> !Sync for KeepAliveService<R, E, F>
impl<R, E, F> Unpin for KeepAliveService<R, E, F>
impl<R, E, F> UnwindSafe for KeepAliveService<R, E, F>
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<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