Struct jobsteal::iter::Map
[−]
[src]
pub struct Map<T, F> { // some fields omitted }
Map iterator adapter.
This transforms each element into a new object.
Trait Implementations
impl<In: IntoIterator, T, F: Sync, U> Consumer<MapBase<In>> for Map<T, F> where T: Consumer<In>, F: Fn(T::Item) -> U
[src]
type Item = U
fn consume<C: Callback<U>>(&self, i: MapBase<In>, cb: C) -> C::Out
Consume the iterator, typically by passing it on to the parent consumer along with a callback which will receive a producer of items to transform. Read more
impl<T: Spliterator, F: Sync, U> Spliterator for Map<T, F> where F: Fn(T::Item) -> U
[src]
type Item = U
The item this iterator produces.
type Base = MapBase<T::Base>
The splittable base data which this consists of.
type Consumer = Map<T::Consumer, F>
A consumer which can act as an ad-hoc iterator adapter chain while being shared across threads. Read more
fn destructure(self) -> (Self::Base, Self::Consumer)
Destructure this iterator into a splittable base and a shareable consumer of that base. Read more
fn size_hint(&self) -> (usize, Option<usize>)
A lower bound and optional upper bound on the size of this iterator.
fn cloned<'a, T: 'a + Clone>(self) -> Cloned<Self> where Self: Spliterator<Item=&'a T>
Clone the items of this iterator to get owned copies.
fn enumerate(self) -> Enumerate<Self>
Enumerate items by their index.
fn filter<F: Sync>(self, pred: F) -> Filter<Self, F> where F: Fn(&Self::Item) -> bool
Filter items by some predicate.
fn flat_map<U, F: Sync>(self, flat_map: F) -> FlatMap<Self, F> where U: IntoIterator, F: Fn(Self::Item) -> U
Produce an iterator for each element, and then yield the elements of those iterators.
fn map<F: Sync, U>(self, map: F) -> Map<Self, F> where F: Fn(Self::Item) -> U
Map the items of this iterator to another type using the supplied function.
fn zip<B: IntoSpliterator>(self, other: B) -> Zip<Self, B::SplitIter>
Zip this iterator with another, combining their items in a tuple. Read more
fn any<P: Sync>(self, spawner: &Spawner, pred: P) -> bool where P: Fn(Self::Item) -> bool
Whether any of the elements fulfill the supplied predicate.
fn all<P: Sync>(self, spawner: &Spawner, pred: P) -> bool where P: Fn(Self::Item) -> bool
Whether all of the elements fulfill the supplied predicate.
fn for_each<F>(self, spawner: &Spawner, f: F) where F: Sync + Fn(Self::Item)
Consume this iterator, performing an action for each item.
fn collect<T: Send>(self, spawner: &Spawner) -> T where Self::Item: Send, T: FromIterator<Self::Item> + Combine + Send
Collect the items of this iterator into a combinable collection. Read more
fn fold<F: Sync>(self, spawner: &Spawner, initial: Self::Item, folder: F) -> Self::Item where F: Folder<Self::Item>, Self::Item: Send
Fold the items of the iterator together with the given operation and initial state. Read more
fn with_cost_mul(self, mul: f32) -> CostMul<Self>
Uses a cost multiplier for this iterator. Read more
impl<T: ExactSizeSpliterator, F: Sync> ExactSizeSpliterator for Map<T, F> where Map<T, F>: Spliterator
[src]
impl<T: Clone, F: Clone> Clone for Map<T, F>
[src]
fn clone(&self) -> Map<T, F>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more