Struct FoldChunksWith

#[must_use = "iterator adaptors are lazy and do nothing unless consumed"]
pub struct FoldChunksWith<I, U, F> { /* private fields */ }

FoldChunksWith is an iterator that groups elements of an underlying iterator and applies a function over them, producing a single value for each group.

This struct is created by the fold_chunks_with() method on IndexedParallelIterator

Trait Implementations

impl<I, U, F> IndexedParallelIterator for FoldChunksWith<I, U, F> where I: IndexedParallelIterator, U: Send + Clone, F: Fn(U, I::Item) -> U + Send + Sync,

fn len(&self) -> usize
fn drive<C>(self, consumer: C) -> C::Result
where
    C: Consumer<Self::Item>,
fn with_producer<CB>(self, callback: CB) -> CB::Output
where
    CB: ProducerCallback<Self::Item>,

impl<I, U, F> ParallelIterator for FoldChunksWith<I, U, F> where I: IndexedParallelIterator, U: Send + Clone, F: Fn(U, I::Item) -> U + Send + Sync,

type Item = U;
fn drive_unindexed<C>(self, consumer: C) -> C::Result
where
    C: Consumer<U>,
fn opt_len(&self) -> Option<usize>

impl<I: Clone, U: Clone, F: Clone> Clone for FoldChunksWith<I, U, F>

fn clone(&self) -> FoldChunksWith<I, U, F>

impl<I: Debug, U: Debug, F> Debug for FoldChunksWith<I, U, F>

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Auto Trait Implementations

impl<I, U, F> Freeze for FoldChunksWith<I, U, F> where I: Freeze, U: Freeze, F: Freeze,

impl<I, U, F> RefUnwindSafe for FoldChunksWith<I, U, F> where I: RefUnwindSafe, U: RefUnwindSafe, F: RefUnwindSafe,

impl<I, U, F> Send for FoldChunksWith<I, U, F> where I: Send, U: Send, F: Send,

impl<I, U, F> Sync for FoldChunksWith<I, U, F> where I: Sync, U: Sync, F: Sync,

impl<I, U, F> Unpin for FoldChunksWith<I, U, F> where I: Unpin, U: Unpin, F: Unpin,

impl<I, U, F> UnsafeUnpin for FoldChunksWith<I, U, F> where I: UnsafeUnpin, U: UnsafeUnpin, F: UnsafeUnpin,

impl<I, U, F> UnwindSafe for FoldChunksWith<I, U, F> where I: UnwindSafe, U: UnwindSafe, F: UnwindSafe,

Blanket Implementations

impl<T> Any for FoldChunksWith<I, U, F> where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for FoldChunksWith<I, U, F> where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for FoldChunksWith<I, U, F> where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> CloneToUninit for FoldChunksWith<I, U, F> where T: Clone,

unsafe fn clone_to_uninit(&self, dest: *mut u8)

impl<T> From<T> for FoldChunksWith<I, U, F>

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> IntoEither for FoldChunksWith<I, U, F>

impl<T> IntoParallelIterator for FoldChunksWith<I, U, F> where T: ParallelIterator,

type Iter = T;
type Item = <T as ParallelIterator>::Item;
fn into_par_iter(self) -> T

impl<T> Pointable for FoldChunksWith<I, U, F>

const ALIGN: usize = _;
type Init = T;
unsafe fn init(init: <T as Pointable>::Init) -> usize
unsafe fn deref<'a>(ptr: usize) -> &'a T
unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
unsafe fn drop(ptr: usize)

impl<T> ToOwned for FoldChunksWith<I, U, F> where T: Clone,

type Owned = T;
fn to_owned(&self) -> T
fn clone_into(&self, target: &mut T)

impl<T, U> Into<U> for FoldChunksWith<I, U, F> where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for FoldChunksWith<I, U, F> where U: Into<T>,

type Error = never;
fn try_from(value: U) -> Result<T, never>

impl<T, U> TryInto<U> for FoldChunksWith<I, U, F> where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>