Trait carapax::ErrorHandler

source ·
pub trait ErrorHandler: Send {
    // Required method
    fn handle(
        &self,
        err: HandlerError
    ) -> impl Future<Output = HandlerError> + Send;
}
Expand description

Allows to process errors returned by handlers.

Required Methods§

source

fn handle(&self, err: HandlerError) -> impl Future<Output = HandlerError> + Send

Handles a errors.

§Arguments
  • err - An error to handle.

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<H, F> ErrorHandler for H
where H: Fn(HandlerError) -> F + Send + Sync, F: Future<Output = HandlerError> + Send,