[−][src]Struct fallible_iterator::MapErr
pub struct MapErr<I, F> { /* fields omitted */ }
An iterator which applies a transform to the errors of the underlying iterator.
Trait Implementations
impl<I: Debug, F: Debug> Debug for MapErr<I, F>
[src]
impl<I: Debug, F: Debug> Debug for MapErr<I, F>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<B, F, I> FallibleIterator for MapErr<I, F> where
I: FallibleIterator,
F: FnMut(I::Error) -> B,
[src]
impl<B, F, I> FallibleIterator for MapErr<I, F> where
I: FallibleIterator,
F: FnMut(I::Error) -> B,
type Item = I::Item
The type being iterated over.
type Error = B
The error type.
fn next(&mut self) -> Result<Option<I::Item>, B>
[src]
fn next(&mut self) -> Result<Option<I::Item>, B>
Advances the iterator and returns the next value. Read more
fn size_hint(&self) -> (usize, Option<usize>)
[src]
fn size_hint(&self) -> (usize, Option<usize>)
Returns bounds on the remaining length of the iterator. Read more
fn count(self) -> Result<usize, B>
[src]
fn count(self) -> Result<usize, B>
Consumes the iterator, returning the number of remaining items.
fn all<F>(&mut self, f: F) -> Result<bool, Self::Error> where
Self: Sized,
F: FnMut(Self::Item) -> bool,
[src]
fn all<F>(&mut self, f: F) -> Result<bool, Self::Error> where
Self: Sized,
F: FnMut(Self::Item) -> bool,
Determines if all elements of this iterator match a predicate.
fn and_then<F, B>(self, f: F) -> AndThen<Self, F> where
Self: Sized,
F: FnMut(Self::Item) -> Result<B, Self::Error>,
[src]
fn and_then<F, B>(self, f: F) -> AndThen<Self, F> where
Self: Sized,
F: FnMut(Self::Item) -> Result<B, Self::Error>,
Returns an iterator which applies a fallible transform to the elements of the underlying iterator. Read more
fn any<F>(&mut self, f: F) -> Result<bool, Self::Error> where
Self: Sized,
F: FnMut(Self::Item) -> bool,
[src]
fn any<F>(&mut self, f: F) -> Result<bool, Self::Error> where
Self: Sized,
F: FnMut(Self::Item) -> bool,
Determines if any element of this iterator matches a predicate.
ⓘImportant traits for &'a mut Ifn by_ref(&mut self) -> &mut Self where
Self: Sized,
[src]
fn by_ref(&mut self) -> &mut Self where
Self: Sized,
Borrow an iterator rather than consuming it. Read more
fn chain<I>(self, it: I) -> Chain<Self, I> where
I: IntoFallibleIterator<Item = Self::Item, Error = Self::Error>,
Self: Sized,
[src]
fn chain<I>(self, it: I) -> Chain<Self, I> where
I: IntoFallibleIterator<Item = Self::Item, Error = Self::Error>,
Self: Sized,
Returns an iterator which yields the elements of this iterator followed by another. Read more
fn cloned<'a, T>(self) -> Cloned<Self> where
Self: Sized + FallibleIterator<Item = &'a T>,
T: 'a + Clone,
[src]
fn cloned<'a, T>(self) -> Cloned<Self> where
Self: Sized + FallibleIterator<Item = &'a T>,
T: 'a + Clone,
Returns an iterator which clones all of its elements.
fn collect<T>(self) -> Result<T, Self::Error> where
T: FromFallibleIterator<Self::Item>,
Self: Sized,
[src]
fn collect<T>(self) -> Result<T, Self::Error> where
T: FromFallibleIterator<Self::Item>,
Self: Sized,
Transforms the iterator into a collection. Read more
fn enumerate(self) -> Enumerate<Self> where
Self: Sized,
[src]
fn enumerate(self) -> Enumerate<Self> where
Self: Sized,
Returns an iterator which yields the current iteration count as well as the value. Read more
fn filter<F>(self, f: F) -> Filter<Self, F> where
Self: Sized,
F: FnMut(&Self::Item) -> bool,
[src]
fn filter<F>(self, f: F) -> Filter<Self, F> where
Self: Sized,
F: FnMut(&Self::Item) -> bool,
Returns an iterator which uses a predicate to determine which values should be yielded. Read more
fn filter_map<B, F>(self, f: F) -> FilterMap<Self, F> where
Self: Sized,
F: FnMut(Self::Item) -> Option<B>,
[src]
fn filter_map<B, F>(self, f: F) -> FilterMap<Self, F> where
Self: Sized,
F: FnMut(Self::Item) -> Option<B>,
Returns an iterator which both filters and maps.
fn find<F>(&mut self, f: F) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
F: FnMut(&Self::Item) -> bool,
[src]
fn find<F>(&mut self, f: F) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
F: FnMut(&Self::Item) -> bool,
Returns the first element of the iterator that matches a predicate.
fn fuse(self) -> Fuse<Self> where
Self: Sized,
[src]
fn fuse(self) -> Fuse<Self> where
Self: Sized,
Returns an iterator which yields this iterator's elements and ends after the first Ok(None)
. Read more
fn fold<B, F>(self, init: B, f: F) -> Result<B, Self::Error> where
Self: Sized,
F: FnMut(B, Self::Item) -> B,
[src]
fn fold<B, F>(self, init: B, f: F) -> Result<B, Self::Error> where
Self: Sized,
F: FnMut(B, Self::Item) -> B,
Applies a function over the elements of the iterator, producing a single final value. Read more
ⓘImportant traits for Iterator<I>fn iterator(self) -> Iterator<Self> where
Self: Sized,
[src]
fn iterator(self) -> Iterator<Self> where
Self: Sized,
Returns a normal (non-fallible) iterator over Result<Item, Error>
.
fn last(self) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
[src]
fn last(self) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
Returns the last element of the iterator.
fn map<B, F>(self, f: F) -> Map<Self, F> where
F: FnMut(Self::Item) -> B,
Self: Sized,
[src]
fn map<B, F>(self, f: F) -> Map<Self, F> where
F: FnMut(Self::Item) -> B,
Self: Sized,
Returns an iterator which applies a transform to the elements of the underlying iterator. Read more
fn map_err<B, F>(self, f: F) -> MapErr<Self, F> where
F: FnMut(Self::Error) -> B,
Self: Sized,
[src]
fn map_err<B, F>(self, f: F) -> MapErr<Self, F> where
F: FnMut(Self::Error) -> B,
Self: Sized,
Returns an iterator which applies a transform to the errors of the underlying iterator. Read more
fn max(self) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
Self::Item: Ord,
[src]
fn max(self) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
Self::Item: Ord,
Returns the maximal element of the iterator.
fn max_by_key<B, F>(self, f: F) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
B: Ord,
F: FnMut(&Self::Item) -> B,
[src]
fn max_by_key<B, F>(self, f: F) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
B: Ord,
F: FnMut(&Self::Item) -> B,
Returns the element of the iterator which gives the maximum value from the function. Read more
fn min(self) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
Self::Item: Ord,
[src]
fn min(self) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
Self::Item: Ord,
Returns the minimal element of the iterator.
fn min_by_key<B, F>(self, f: F) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
B: Ord,
F: FnMut(&Self::Item) -> B,
[src]
fn min_by_key<B, F>(self, f: F) -> Result<Option<Self::Item>, Self::Error> where
Self: Sized,
B: Ord,
F: FnMut(&Self::Item) -> B,
Returns the element of the iterator which gives the minimum value from the function. Read more
fn nth(&mut self, n: usize) -> Result<Option<Self::Item>, Self::Error>
[src]
fn nth(&mut self, n: usize) -> Result<Option<Self::Item>, Self::Error>
Returns the n
th element of the iterator.
fn peekable(self) -> Peekable<Self> where
Self: Sized,
[src]
fn peekable(self) -> Peekable<Self> where
Self: Sized,
Returns an iterator that can peek at the next element without consuming it. Read more
fn position<F>(&mut self, f: F) -> Result<Option<usize>, Self::Error> where
Self: Sized,
F: FnMut(Self::Item) -> bool,
[src]
fn position<F>(&mut self, f: F) -> Result<Option<usize>, Self::Error> where
Self: Sized,
F: FnMut(Self::Item) -> bool,
Returns the position of the first element of this iterator that matches a predicate. Read more
fn rev(self) -> Rev<Self> where
Self: Sized + DoubleEndedFallibleIterator,
[src]
fn rev(self) -> Rev<Self> where
Self: Sized + DoubleEndedFallibleIterator,
Returns an iterator that yields this iterator's items in the opposite order. Read more
fn take(self, n: usize) -> Take<Self> where
Self: Sized,
[src]
fn take(self, n: usize) -> Take<Self> where
Self: Sized,
Returns an iterator that yields only the first n
values of this iterator. Read more
fn zip<I>(self, o: I) -> Zip<Self, I::IntoIter> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
[src]
fn zip<I>(self, o: I) -> Zip<Self, I::IntoIter> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Returns an iterator that yields pairs of this iterator's and another iterator's values. Read more
fn cmp<I>(self, other: I) -> Result<Ordering, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Item = Self::Item, Error = Self::Error>,
Self::Item: Ord,
[src]
fn cmp<I>(self, other: I) -> Result<Ordering, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Item = Self::Item, Error = Self::Error>,
Self::Item: Ord,
Lexicographically compares the elements of this iterator to that of another. Read more
fn partial_cmp<I>(self, other: I) -> Result<Option<Ordering>, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
[src]
fn partial_cmp<I>(self, other: I) -> Result<Option<Ordering>, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
Lexicographically compares the elements of this iterator to that of another. Read more
fn eq<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialEq<I::Item>,
[src]
fn eq<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialEq<I::Item>,
Determines if the elements of this iterator are equal to those of another. Read more
fn ne<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialEq<I::Item>,
[src]
fn ne<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialEq<I::Item>,
Determines if the elements of this iterator are not equal to those of another. Read more
fn lt<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
[src]
fn lt<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
Determines if the elements of this iterator are lexicographically less than those of another. Read more
fn le<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
[src]
fn le<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
Determines if the elements of this iterator are lexicographically less than or equal to those of another. Read more
fn gt<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
[src]
fn gt<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
Determines if the elements of this iterator are lexicographically greater than those of another. Read more
fn ge<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
[src]
fn ge<I>(self, other: I) -> Result<bool, Self::Error> where
Self: Sized,
I: IntoFallibleIterator<Error = Self::Error>,
Self::Item: PartialOrd<I::Item>,
Determines if the elements of this iterator are lexicographically greater than or equal to those of another. Read more
impl<B, F, I> DoubleEndedFallibleIterator for MapErr<I, F> where
I: DoubleEndedFallibleIterator,
F: FnMut(I::Error) -> B,
[src]
impl<B, F, I> DoubleEndedFallibleIterator for MapErr<I, F> where
I: DoubleEndedFallibleIterator,
F: FnMut(I::Error) -> B,
Auto Trait Implementations
impl<I, F> Send for MapErr<I, F> where
F: Send,
I: Send,
impl<I, F> Send for MapErr<I, F> where
F: Send,
I: Send,
impl<I, F> Sync for MapErr<I, F> where
F: Sync,
I: Sync,
impl<I, F> Sync for MapErr<I, F> where
F: Sync,
I: Sync,
Blanket Implementations
impl<I> IntoFallibleIterator for I where
I: FallibleIterator,
[src]
impl<I> IntoFallibleIterator for I where
I: FallibleIterator,
type Item = <I as FallibleIterator>::Item
The elements of the iterator.
type Error = <I as FallibleIterator>::Error
The error value of the iterator.
type IntoIter = I
The iterator.
fn into_fallible_iterator(Self) -> I
[src]
fn into_fallible_iterator(Self) -> I
Creates a fallible iterator from a value.
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
try_from
)Performs the conversion.
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
try_from
)Performs the conversion.
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
ⓘImportant traits for &'a mut Ifn borrow(&self) -> &T
[src]
fn borrow(&self) -> &T
Immutably borrows from an owned value. Read more
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
ⓘImportant traits for &'a mut Ifn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more