pub trait Source: Operator {
// Provided method
fn ready(&mut self, _cx: &mut Cx<'_>) -> VortexResult<SourceReady> { ... }
}Expand description
The start of a pipeline: produces batches from its inlets and the segments it asks to have read.
Provided Methods§
Sourcefn ready(&mut self, _cx: &mut Cx<'_>) -> VortexResult<SourceReady>
fn ready(&mut self, _cx: &mut Cx<'_>) -> VortexResult<SourceReady>
Prepares the next compute call, after the driver checks outlets.
Returning SourceReady::Ready guarantees that call can proceed without blocking.
Any input or choice made here can be retained by the source for that call.
Queue reads with Cx::request_read and return
SourceReady::Blocked(SourceBlocked::Io). The driver issues newly queued reads
before waiting. Readiness is checked again when bytes are available, including bytes
already delivered; they are available through Cx::take_segment in arrival order.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".