pub trait Source: Send + Sync {
// Required methods
fn next_chunk(
&mut self,
chunk_size: usize,
) -> Result<Option<DataChunk>, OperatorError>;
fn reset(&mut self);
fn name(&self) -> &'static str;
}Expand description
Source of data chunks for a pipeline.
Sources produce chunks of data that flow through the pipeline.
Required Methods§
Sourcefn next_chunk(
&mut self,
chunk_size: usize,
) -> Result<Option<DataChunk>, OperatorError>
fn next_chunk( &mut self, chunk_size: usize, ) -> Result<Option<DataChunk>, OperatorError>
Produce the next chunk of data.
Returns Ok(Some(chunk)) if data is available, Ok(None) if exhausted.