pub trait AtomicIterWithInitialLen: AtomicIter {
    // Required methods
    fn initial_len(&self) -> usize;
    fn fetch_n_with_exact_len(
        &self,
        n: usize
    ) -> NextManyExact<Self::Item, impl ExactSizeIterator<Item = Self::Item>>;
}
Expand description

An atomic counter based iterator with exactly known initial length.

Required Methods§

source

fn initial_len(&self) -> usize

Returns the initial length of the atomic iterator.

source

fn fetch_n_with_exact_len( &self, n: usize ) -> NextManyExact<Self::Item, impl ExactSizeIterator<Item = Self::Item>>

Returns an iterator of the next n consecutive items that the iterator together with an exact size iterator. It might return an iterator of less or no items if the iteration does not have sufficient elements left.

Object Safety§

This trait is not object safe.

Implementors§