Skip to main content

Source

Trait Source 

Source
pub trait Source {
    // Required method
    fn run(self, sink: &mut dyn Sink) -> Result<Flow, Fail>;
}
Expand description

Something that can drive a sink with one document’s events.

Required Methods§

Source

fn run(self, sink: &mut dyn Sink) -> Result<Flow, Fail>

Run to completion, or until the sink stops, or until a failure. Ok(Flow::Stop) means the sink stopped it; the document was not validated past that point.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§