Loader

Trait Loader 

Source
pub trait Loader:
    DynClone
    + Send
    + Sync {
    type Output: Chunk;

    // Required method
    fn into_stream(self) -> IndexingStream<Self::Output>;

    // Provided methods
    fn into_stream_boxed(self: Box<Self>) -> IndexingStream<Self::Output> { ... }
    fn name(&self) -> &'static str { ... }
}
Expand description

Starting point of a stream

Required Associated Types§

Required Methods§

Provided Methods§

Source

fn into_stream_boxed(self: Box<Self>) -> IndexingStream<Self::Output>

Intended for use with Box

Only needed if you use trait objects (Box)

§Example
fn into_stream_boxed(self: Box<Self>) -> IndexingStream {
   self.into_stream()
 }
Source

fn name(&self) -> &'static str

Trait Implementations§

Source§

impl<O: Chunk> Loader for &dyn Loader<Output = O>

Source§

type Output = O

Source§

fn into_stream(self) -> IndexingStream<Self::Output>

Source§

fn into_stream_boxed(self: Box<Self>) -> IndexingStream<Self::Output>

Intended for use with Box Read more
Source§

fn name(&self) -> &'static str

Source§

impl<O: Chunk> Loader for Box<dyn Loader<Output = O>>

Source§

type Output = O

Source§

fn into_stream(self) -> IndexingStream<Self::Output>

Source§

fn into_stream_boxed(self: Box<Self>) -> IndexingStream<Self::Output>

Intended for use with Box Read more
Source§

fn name(&self) -> &'static str

Implementations on Foreign Types§

Source§

impl<O: Chunk> Loader for Box<dyn Loader<Output = O>>

Source§

type Output = O

Source§

fn into_stream(self) -> IndexingStream<Self::Output>

Source§

fn into_stream_boxed(self: Box<Self>) -> IndexingStream<Self::Output>

Source§

fn name(&self) -> &'static str

Implementors§

Source§

impl Loader for MockLoader

Source§

impl<O: Chunk> Loader for &dyn Loader<Output = O>