pub trait Storage<U>: 'static + Send + Sync {
    type Error: Send + Error;
    type QueuedMail: QueuedMail;
    type InflightMail: InflightMail;
    type PendingCleanupMail: PendingCleanupMail;
    type QueueLister: Send + Stream<Item = Result<Self::QueuedMail, (Self::Error, Option<QueueId>)>>;
    type InflightLister: Send + Stream<Item = Result<Self::InflightMail, (Self::Error, Option<QueueId>)>>;
    type PendingCleanupLister: Send + Stream<Item = Result<Self::PendingCleanupMail, (Self::Error, Option<QueueId>)>>;
    type Enqueuer: StorageEnqueuer<U, Self, Self::QueuedMail>;
    type Reader: Send + AsyncRead;
    fn list_queue<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Self::QueueLister> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn find_inflight<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Self::InflightLister> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn find_pending_cleanup<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Self::PendingCleanupLister> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn read_inflight<'life0, 'life1, 'async_trait>(
        &'life0 self,
        mail: &'life1 Self::InflightMail
    ) -> Pin<Box<dyn Future<Output = Result<(MailMetadata<U>, Self::Reader), Self::Error>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        Self: 'async_trait
;
fn enqueue<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Result<Self::Enqueuer, Self::Error>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn reschedule<'life0, 'life1, 'async_trait>(
        &'life0 self,
        mail: &'life1 mut Self::QueuedMail,
        schedule: ScheduleInfo
    ) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        Self: 'async_trait
;
fn send_start<'life0, 'async_trait>(
        &'life0 self,
        mail: Self::QueuedMail
    ) -> Pin<Box<dyn Future<Output = Result<Option<Self::InflightMail>, (Self::QueuedMail, Self::Error)>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn send_done<'life0, 'async_trait>(
        &'life0 self,
        mail: Self::InflightMail
    ) -> Pin<Box<dyn Future<Output = Result<Option<Self::PendingCleanupMail>, (Self::InflightMail, Self::Error)>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn send_cancel<'life0, 'async_trait>(
        &'life0 self,
        mail: Self::InflightMail
    ) -> Pin<Box<dyn Future<Output = Result<Option<Self::QueuedMail>, (Self::InflightMail, Self::Error)>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn drop<'life0, 'async_trait>(
        &'life0 self,
        mail: Self::QueuedMail
    ) -> Pin<Box<dyn Future<Output = Result<Option<Self::PendingCleanupMail>, (Self::QueuedMail, Self::Error)>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
;
fn cleanup<'life0, 'async_trait>(
        &'life0 self,
        mail: Self::PendingCleanupMail
    ) -> Pin<Box<dyn Future<Output = Result<bool, (Self::PendingCleanupMail, Self::Error)>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
; }

Associated Types

Required methods

Implementors