Trait OutputQueue

Source
pub trait OutputQueue {
    type Err: Debug;

    // Required methods
    fn put<'life0, 'async_trait, D>(
        &'life0 self,
        data: D,
    ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
       where D: AsRef<[u8]> + Send + 'async_trait,
             Self: 'async_trait,
             'life0: 'async_trait;
    fn close<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

The send-only side of a queue

Required Associated Types§

Source

type Err: Debug

The type of error that can occur sending messages to this OutputQueue

Required Methods§

Source

fn put<'life0, 'async_trait, D>( &'life0 self, data: D, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where D: AsRef<[u8]> + Send + 'async_trait, Self: 'async_trait, 'life0: 'async_trait,

Put a job in this OutputQueue

Source

fn close<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<(), Self::Err>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Close this OutputQueue signaling we don’t want to receive anymore messages

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§