Skip to main content

ChunkGenerator

Trait ChunkGenerator 

Source
pub trait ChunkGenerator: Send + Sync {
    // Required methods
    fn process_data(&mut self, data: &[u8]) -> Vec<Chunk>;
    fn signal_eos(&mut self) -> Vec<Chunk>;
    fn chunks_count(&self) -> u64;
    fn chunked_bytes_count(&self) -> u64;
}

Required Methods§

Source

fn process_data(&mut self, data: &[u8]) -> Vec<Chunk>

Source

fn signal_eos(&mut self) -> Vec<Chunk>

Source

fn chunks_count(&self) -> u64

Total number of chunks generated

Source

fn chunked_bytes_count(&self) -> u64

Total number of bytes received by the generator

Implementors§