[][src]Struct sized_chunks::sized_chunk::Drain

pub struct Drain<'a, A, N> where
    N: ChunkLength<A>, 
{ /* fields omitted */ }

A draining iterator over the elements of a Chunk.

"Draining" means that as the iterator yields each element, it's removed from the Chunk. When the iterator terminates, the chunk will be empty. This is different from the consuming iterator Iter in that Iter will take ownership of the Chunk and discard it when you're done iterating, while Drain leaves you still owning the drained Chunk.

Trait Implementations

impl<'a, A, N> DoubleEndedIterator for Drain<'a, A, N> where
    A: 'a,
    N: ChunkLength<A> + 'a, 
[src]

impl<'a, A, N> ExactSizeIterator for Drain<'a, A, N> where
    A: 'a,
    N: ChunkLength<A> + 'a, 
[src]

impl<'a, A, N> FusedIterator for Drain<'a, A, N> where
    A: 'a,
    N: ChunkLength<A> + 'a, 
[src]

impl<'a, A, N> Iterator for Drain<'a, A, N> where
    A: 'a,
    N: ChunkLength<A> + 'a, 
[src]

type Item = A

The type of the elements being iterated over.

Auto Trait Implementations

impl<'a, A, N> RefUnwindSafe for Drain<'a, A, N> where
    <N as ChunkLength<A>>::SizedType: RefUnwindSafe

impl<'a, A, N> Send for Drain<'a, A, N> where
    <N as ChunkLength<A>>::SizedType: Send

impl<'a, A, N> Sync for Drain<'a, A, N> where
    <N as ChunkLength<A>>::SizedType: Sync

impl<'a, A, N> Unpin for Drain<'a, A, N>

impl<'a, A, N> !UnwindSafe for Drain<'a, A, N>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<T> Same<T> for T[src]

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.