Trait lapin::ConsumerDelegate

source ·
pub trait ConsumerDelegate: Send + Sync {
    // Required method
    fn on_new_delivery(
        &self,
        delivery: DeliveryResult
    ) -> Pin<Box<dyn Future<Output = ()> + Send>>;

    // Provided method
    fn drop_prefetched_messages(
        &self
    ) -> Pin<Box<dyn Future<Output = ()> + Send>> { ... }
}

Required Methods§

source

fn on_new_delivery( &self, delivery: DeliveryResult ) -> Pin<Box<dyn Future<Output = ()> + Send>>

Provided Methods§

source

fn drop_prefetched_messages(&self) -> Pin<Box<dyn Future<Output = ()> + Send>>

Implementors§

source§

impl<F: Future<Output = ()> + Send + 'static, DeliveryHandler: Fn(DeliveryResult) -> F + Send + Sync + 'static> ConsumerDelegate for DeliveryHandler