[][src]Trait flatk::IntoChunkIterator

pub trait IntoChunkIterator {
    type Item;
    type IterType: Iterator<Item = Self::Item>;
    fn into_chunk_iter(self, chunk_size: usize) -> Self::IterType;
}

This trait generalizes the method chunks available on slices in the standard library. Collections that can be chunked by a runtime stride should implement this behaviour such that they can be composed with ChunkedN types.

Associated Types

type Item

type IterType: Iterator<Item = Self::Item>

Loading content...

Required methods

fn into_chunk_iter(self, chunk_size: usize) -> Self::IterType

Produce a chunk iterator with the given stride chunk_size. One notable difference between this trait and chunks* methods on slices is that chunks_iter should panic when the underlying data cannot split into chunk_size sized chunks exactly.

Loading content...

Implementors

impl<S> IntoChunkIterator for S where
    S: Set + SplitAt + Dummy
[src]

type Item = S

type IterType = ChunkedNIter<S>

Loading content...