pub trait IsReady<Request>: Service<Request> {
    // Required methods
    fn is_ready(&mut self) -> BoxFuture<'_, bool>;
    fn is_pending(&mut self) -> BoxFuture<'_, bool>;
    fn is_failed(&mut self) -> BoxFuture<'_, bool>;
}
Expand description

An extension trait to check if a [Service] is immediately ready to be called.

Required Methods§

source

fn is_ready(&mut self) -> BoxFuture<'_, bool>

Poll the [Service] once, and return true if it is immediately ready to be called.

source

fn is_pending(&mut self) -> BoxFuture<'_, bool>

Poll the [Service] once, and return true if it is pending.

source

fn is_failed(&mut self) -> BoxFuture<'_, bool>

Poll the [Service] once, and return true if it has failed.

Implementors§

source§

impl<S, Request> IsReady<Request> for S
where S: Service<Request> + Send, Request: 'static,