Trait ByteSource

Source
pub trait ByteSource {
    type Future<'a>: Future<Output = Result<Bytes, FileErr>>
       where Self: 'a;

    // Required method
    fn request_bytes<'a>(&'a mut self, size: usize) -> Self::Future<'a>;
}

Required Associated Typesยง

Source

type Future<'a>: Future<Output = Result<Bytes, FileErr>> where Self: 'a

Required Methodsยง

Source

fn request_bytes<'a>(&'a mut self, size: usize) -> Self::Future<'a>

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ยง