pub struct Scan<L, St, F> { /* private fields */ }Expand description
Implementations§
Source§impl<L, St, F> Scan<L, St, F>
impl<L, St, F> Scan<L, St, F>
Sourcepub fn into_inner(self) -> L
pub fn into_inner(self) -> L
Returns the inner lender.
Sourcepub fn into_parts(self) -> (L, St, Covar<F>)
pub fn into_parts(self) -> (L, St, Covar<F>)
Returns the inner lender, the state, and the scan function.
Trait Implementations§
Source§impl<L, St, F> FallibleLender for Scan<L, St, F>where
for<'all> F: FnMutHKAResOpt<'all, (&'all mut St, FallibleLend<'all, L>), L::Error>,
L: FallibleLender,
impl<L, St, F> FallibleLender for Scan<L, St, F>where
for<'all> F: FnMutHKAResOpt<'all, (&'all mut St, FallibleLend<'all, L>), L::Error>,
L: FallibleLender,
Source§type Error = <L as FallibleLender>::Error
type Error = <L as FallibleLender>::Error
The error type.
Source§fn __check_covariance<'long: 'short, 'short>(
proof: CovariantProof<&'short <Self as FallibleLending<'long>>::Lend>,
) -> CovariantProof<&'short <Self as FallibleLending<'short>>::Lend>
fn __check_covariance<'long: 'short, 'short>( proof: CovariantProof<&'short <Self as FallibleLending<'long>>::Lend>, ) -> CovariantProof<&'short <Self as FallibleLending<'short>>::Lend>
Internal method for compile-time covariance checking. Read more
Source§fn next(&mut self) -> Result<Option<FallibleLend<'_, Self>>, Self::Error>
fn next(&mut self) -> Result<Option<FallibleLend<'_, Self>>, Self::Error>
Yields the next lend, if any, of the lender, or
Ok(None) when iteration
is finished. Read moreSource§fn next_chunk(&mut self, chunk_size: usize) -> Chunk<'_, Self>where
Self: Sized,
fn next_chunk(&mut self, chunk_size: usize) -> Chunk<'_, Self>where
Self: Sized,
Takes the next
chunk_size lends of the lender with temporary lender
Chunk. This is equivalent to cloning the lender and calling
take(chunk_size) on it. Read moreSource§fn count(self) -> Result<usize, Self::Error>where
Self: Sized,
fn count(self) -> Result<usize, Self::Error>where
Self: Sized,
Counts the number of lends in the lender by consuming it until the
lender yields
Ok(None) or Err(_). Read moreSource§fn last<'call>(
&'call mut self,
) -> Result<Option<FallibleLend<'call, Self>>, Self::Error>where
Self: Sized,
fn last<'call>(
&'call mut self,
) -> Result<Option<FallibleLend<'call, Self>>, Self::Error>where
Self: Sized,
Gets the last lend of the lender, if any, by consuming it. Read more
Source§fn advance_by(
&mut self,
n: usize,
) -> Result<Result<(), NonZeroUsize>, Self::Error>
fn advance_by( &mut self, n: usize, ) -> Result<Result<(), NonZeroUsize>, Self::Error>
Advances the lender by
n lends. Read moreSource§fn nth(
&mut self,
n: usize,
) -> Result<Option<FallibleLend<'_, Self>>, Self::Error>
fn nth( &mut self, n: usize, ) -> Result<Option<FallibleLend<'_, Self>>, Self::Error>
Yields the nth lend of the lender, if any, by
consuming it. If the lender does not have enough
lends, returns
Ok(None). Read moreSource§fn step_by(self, step: usize) -> StepBy<Self>where
Self: Sized,
fn step_by(self, step: usize) -> StepBy<Self>where
Self: Sized,
Skips
step - 1 lends between each lend of the lender. Read moreSource§fn chain<U>(
self,
other: U,
) -> Chain<Self, <U as IntoFallibleLender>::FallibleLender>where
Self: Sized,
U: IntoFallibleLender<Error = Self::Error> + for<'all> FallibleLending<'all, Lend = FallibleLend<'all, Self>>,
fn chain<U>(
self,
other: U,
) -> Chain<Self, <U as IntoFallibleLender>::FallibleLender>where
Self: Sized,
U: IntoFallibleLender<Error = Self::Error> + for<'all> FallibleLending<'all, Lend = FallibleLend<'all, Self>>,
Chains the lender with another lender of the same type. Read more
Source§fn zip<U: IntoFallibleLender>(
self,
other: U,
) -> Zip<Self, <U as IntoFallibleLender>::FallibleLender>where
Self: Sized,
fn zip<U: IntoFallibleLender>(
self,
other: U,
) -> Zip<Self, <U as IntoFallibleLender>::FallibleLender>where
Self: Sized,
Zips the lender with another lender of the same or different type. Read more
Source§fn intersperse<'call>(
self,
separator: FallibleLend<'call, Self>,
) -> FallibleIntersperse<'call, Self>
fn intersperse<'call>( self, separator: FallibleLend<'call, Self>, ) -> FallibleIntersperse<'call, Self>
Intersperses each lend of this lender with the given separator. Read more
Source§fn intersperse_with<'call, G>(
self,
separator: G,
) -> FallibleIntersperseWith<'call, Self, G>
fn intersperse_with<'call, G>( self, separator: G, ) -> FallibleIntersperseWith<'call, Self, G>
Intersperses each lend of this lender with the separator produced by
the given function. Read more
Source§fn map<F>(self, f: Covar<F>) -> Map<Self, F>
fn map<F>(self, f: Covar<F>) -> Map<Self, F>
Maps each lend of this lender using the given function. Read more
Source§fn map_err<E, F>(self, f: F) -> MapErr<E, Self, F>
fn map_err<E, F>(self, f: F) -> MapErr<E, Self, F>
Maps the error of this lender using the given function. Read more
Source§fn map_into_iter<O, F>(self, f: F) -> MapIntoIter<Self, O, F> ⓘ
fn map_into_iter<O, F>(self, f: F) -> MapIntoIter<Self, O, F> ⓘ
Maps each lend of this lender into an owned value using the given function. Read more
Source§fn for_each<F>(self, f: F) -> Result<(), Self::Error>
fn for_each<F>(self, f: F) -> Result<(), Self::Error>
Calls the given function with each lend of this lender. Read more
Source§fn filter<P>(self, predicate: P) -> Filter<Self, P>
fn filter<P>(self, predicate: P) -> Filter<Self, P>
Filters this lender using the given predicate. Read more
Source§fn filter_map<F>(self, f: Covar<F>) -> FilterMap<Self, F>
fn filter_map<F>(self, f: Covar<F>) -> FilterMap<Self, F>
Filters and maps this lender using the given function. Read more
Source§fn enumerate(self) -> Enumerate<Self>where
Self: Sized,
fn enumerate(self) -> Enumerate<Self>where
Self: Sized,
Enumerates this lender. Each lend is paired with its zero-based
index. Read more
Source§fn peekable<'call>(self) -> FalliblePeekable<'call, Self>where
Self: Sized,
fn peekable<'call>(self) -> FalliblePeekable<'call, Self>where
Self: Sized,
Makes this lender peekable, so that it is possible to peek at the next
lend without consuming it. Read more
Source§fn skip_while<P>(self, predicate: P) -> SkipWhile<Self, P>
fn skip_while<P>(self, predicate: P) -> SkipWhile<Self, P>
Skips the first contiguous sequence of lends of this lender that
satisfy the given predicate. Read more
Source§fn take_while<P>(self, predicate: P) -> TakeWhile<Self, P>
fn take_while<P>(self, predicate: P) -> TakeWhile<Self, P>
Takes the first contiguous sequence of lends of this lender that
satisfy the given predicate. Read more
Source§fn skip(self, n: usize) -> Skip<Self>where
Self: Sized,
fn skip(self, n: usize) -> Skip<Self>where
Self: Sized,
Skips the first
n lends of this lender. Read moreSource§fn take(self, n: usize) -> Take<Self>where
Self: Sized,
fn take(self, n: usize) -> Take<Self>where
Self: Sized,
Takes the first
n lends of this lender. Read moreSource§fn scan<St, F>(self, initial_state: St, f: Covar<F>) -> Scan<Self, St, F>where
Self: Sized,
F: for<'all> FnMutHKAResOpt<'all, (&'all mut St, FallibleLend<'all, Self>), Self::Error>,
fn scan<St, F>(self, initial_state: St, f: Covar<F>) -> Scan<Self, St, F>where
Self: Sized,
F: for<'all> FnMutHKAResOpt<'all, (&'all mut St, FallibleLend<'all, Self>), Self::Error>,
Source§fn flat_map<'call, F>(self, f: Covar<F>) -> FallibleFlatMap<'call, Self, F>where
Self: Sized,
F: for<'all> FnMutHKARes<'all, FallibleLend<'all, Self>, Self::Error>,
for<'all> <F as FnMutHKARes<'all, FallibleLend<'all, Self>, Self::Error>>::B: IntoFallibleLender<Error = Self::Error>,
fn flat_map<'call, F>(self, f: Covar<F>) -> FallibleFlatMap<'call, Self, F>where
Self: Sized,
F: for<'all> FnMutHKARes<'all, FallibleLend<'all, Self>, Self::Error>,
for<'all> <F as FnMutHKARes<'all, FallibleLend<'all, Self>, Self::Error>>::B: IntoFallibleLender<Error = Self::Error>,
Source§fn flatten<'call>(self) -> FallibleFlatten<'call, Self>
fn flatten<'call>(self) -> FallibleFlatten<'call, Self>
Source§fn mutate<F>(self, f: F) -> Mutate<Self, F>
fn mutate<F>(self, f: F) -> Mutate<Self, F>
Mutates each lend with the given function. Read more
Source§fn collect<B>(self) -> Result<B, (B, Self::Error)>where
Self: Sized,
for<'all> B: FromLender<NonFallibleAdapter<'all, Self>>,
fn collect<B>(self) -> Result<B, (B, Self::Error)>where
Self: Sized,
for<'all> B: FromLender<NonFallibleAdapter<'all, Self>>,
Transforms the fallible lender into a collection.
If any invocation of next returns Err, returns the collection built
from values yielded successfully, together with the error. Read more
Source§fn try_collect<'a, B, T>(&'a mut self) -> Result<T, (T, Self::Error)>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: Try,
for<'all> <FallibleLend<'all, Self> as Try>::Residual: Residual<B, TryType = T>,
for<'b, 'c, 'd> B: FromLender<FallibleTryShuntAdapter<'b, 'c, 'd, 'a, Self>>,
fn try_collect<'a, B, T>(&'a mut self) -> Result<T, (T, Self::Error)>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: Try,
for<'all> <FallibleLend<'all, Self> as Try>::Residual: Residual<B, TryType = T>,
for<'b, 'c, 'd> B: FromLender<FallibleTryShuntAdapter<'b, 'c, 'd, 'a, Self>>,
Source§fn collect_into<E>(
self,
collection: &mut E,
) -> Result<&mut E, (&mut E, Self::Error)>where
Self: Sized,
for<'all> E: ExtendLender<NonFallibleAdapter<'all, Self>>,
fn collect_into<E>(
self,
collection: &mut E,
) -> Result<&mut E, (&mut E, Self::Error)>where
Self: Sized,
for<'all> E: ExtendLender<NonFallibleAdapter<'all, Self>>,
Extends an existing collection with lends from this fallible lender. Read more
Source§fn partition<'this, E, F>(self, f: F) -> Result<(E, E), ((E, E), Self::Error)>where
Self: Sized + 'this,
E: Default + ExtendLender<NonFallibleAdapter<'this, Self>>,
F: FnMut(&FallibleLend<'_, Self>) -> Result<bool, Self::Error>,
fn partition<'this, E, F>(self, f: F) -> Result<(E, E), ((E, E), Self::Error)>where
Self: Sized + 'this,
E: Default + ExtendLender<NonFallibleAdapter<'this, Self>>,
F: FnMut(&FallibleLend<'_, Self>) -> Result<bool, Self::Error>,
Source§fn try_for_each<F, R>(&mut self, f: F) -> Result<R, Self::Error>
fn try_for_each<F, R>(&mut self, f: F) -> Result<R, Self::Error>
Source§fn reduce<T, F>(self, f: F) -> Result<Option<T>, Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: ToOwned<Owned = T>,
F: FnMut(T, FallibleLend<'_, Self>) -> Result<T, Self::Error>,
fn reduce<T, F>(self, f: F) -> Result<Option<T>, Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: ToOwned<Owned = T>,
F: FnMut(T, FallibleLend<'_, Self>) -> Result<T, Self::Error>,
Source§fn try_reduce<T, F, R>(
self,
f: F,
) -> Result<ChangeOutputType<R, Option<T>>, Self::Error>
fn try_reduce<T, F, R>( self, f: F, ) -> Result<ChangeOutputType<R, Option<T>>, Self::Error>
Source§fn find<P>(
&mut self,
predicate: P,
) -> Result<Option<FallibleLend<'_, Self>>, Self::Error>
fn find<P>( &mut self, predicate: P, ) -> Result<Option<FallibleLend<'_, Self>>, Self::Error>
Source§fn find_map<'a, F>(
&'a mut self,
f: F,
) -> Result<Option<<F as FnMutHKAResOpt<'a, FallibleLend<'a, Self>, Self::Error>>::B>, Self::Error>
fn find_map<'a, F>( &'a mut self, f: F, ) -> Result<Option<<F as FnMutHKAResOpt<'a, FallibleLend<'a, Self>, Self::Error>>::B>, Self::Error>
Source§fn try_find<F, R>(
&mut self,
f: F,
) -> Result<ChangeOutputType<R, Option<FallibleLend<'_, Self>>>, Self::Error>
fn try_find<F, R>( &mut self, f: F, ) -> Result<ChangeOutputType<R, Option<FallibleLend<'_, Self>>>, Self::Error>
Source§fn max_by<T, F>(self, compare: F) -> Result<Option<T>, Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: ToOwned<Owned = T>,
F: FnMut(&T, &FallibleLend<'_, Self>) -> Result<Ordering, Self::Error>,
fn max_by<T, F>(self, compare: F) -> Result<Option<T>, Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: ToOwned<Owned = T>,
F: FnMut(&T, &FallibleLend<'_, Self>) -> Result<Ordering, Self::Error>,
Source§fn min_by<T, F>(self, compare: F) -> Result<Option<T>, Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: ToOwned<Owned = T>,
F: FnMut(&T, &FallibleLend<'_, Self>) -> Result<Ordering, Self::Error>,
fn min_by<T, F>(self, compare: F) -> Result<Option<T>, Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: ToOwned<Owned = T>,
F: FnMut(&T, &FallibleLend<'_, Self>) -> Result<Ordering, Self::Error>,
Source§fn unzip<ExtA, ExtB>(self) -> Result<(ExtA, ExtB), Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: TupleLend<'all>,
ExtA: Default + for<'this> ExtendLender<NonFallibleAdapter<'this, <FirstShunt<Self> as IntoFallibleLender>::FallibleLender>>,
ExtB: Default + for<'this> ExtendLender<NonFallibleAdapter<'this, <SecondShunt<Self> as IntoFallibleLender>::FallibleLender>>,
fn unzip<ExtA, ExtB>(self) -> Result<(ExtA, ExtB), Self::Error>where
Self: Sized,
for<'all> FallibleLend<'all, Self>: TupleLend<'all>,
ExtA: Default + for<'this> ExtendLender<NonFallibleAdapter<'this, <FirstShunt<Self> as IntoFallibleLender>::FallibleLender>>,
ExtB: Default + for<'this> ExtendLender<NonFallibleAdapter<'this, <SecondShunt<Self> as IntoFallibleLender>::FallibleLender>>,
The
FallibleLender version of Iterator::unzip.Source§fn product<P>(self) -> Result<P, Self::Error>where
Self: Sized,
P: ProductFallibleLender<Self>,
fn product<P>(self) -> Result<P, Self::Error>where
Self: Sized,
P: ProductFallibleLender<Self>,
Source§fn cmp<L>(self, other: L) -> Result<Ordering, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
L::FallibleLender: for<'all> FallibleLending<'all, Lend = FallibleLend<'all, Self>>,
for<'all> FallibleLend<'all, Self>: Ord,
Self: Sized,
fn cmp<L>(self, other: L) -> Result<Ordering, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
L::FallibleLender: for<'all> FallibleLending<'all, Lend = FallibleLend<'all, Self>>,
for<'all> FallibleLend<'all, Self>: Ord,
Self: Sized,
Source§fn cmp_by<L, F>(self, other: L, cmp: F) -> Result<Ordering, Self::Error>where
Self: Sized,
L: IntoFallibleLender<Error = Self::Error>,
F: for<'all> FnMut(FallibleLend<'all, Self>, FallibleLend<'all, L::FallibleLender>) -> Result<Ordering, Self::Error>,
fn cmp_by<L, F>(self, other: L, cmp: F) -> Result<Ordering, Self::Error>where
Self: Sized,
L: IntoFallibleLender<Error = Self::Error>,
F: for<'all> FnMut(FallibleLend<'all, Self>, FallibleLend<'all, L::FallibleLender>) -> Result<Ordering, Self::Error>,
Source§fn partial_cmp<L>(self, other: L) -> Result<Option<Ordering>, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn partial_cmp<L>(self, other: L) -> Result<Option<Ordering>, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn partial_cmp_by<L, F>(
self,
other: L,
partial_cmp: F,
) -> Result<Option<Ordering>, Self::Error>where
Self: Sized,
L: IntoFallibleLender<Error = Self::Error>,
F: for<'all> FnMut(FallibleLend<'all, Self>, FallibleLend<'all, L::FallibleLender>) -> Result<Option<Ordering>, Self::Error>,
fn partial_cmp_by<L, F>(
self,
other: L,
partial_cmp: F,
) -> Result<Option<Ordering>, Self::Error>where
Self: Sized,
L: IntoFallibleLender<Error = Self::Error>,
F: for<'all> FnMut(FallibleLend<'all, Self>, FallibleLend<'all, L::FallibleLender>) -> Result<Option<Ordering>, Self::Error>,
Source§fn eq<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialEq<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn eq<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialEq<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn eq_by<L, F>(self, other: L, eq: F) -> Result<bool, Self::Error>where
Self: Sized,
L: IntoFallibleLender<Error = Self::Error>,
F: for<'all> FnMut(FallibleLend<'all, Self>, FallibleLend<'all, L::FallibleLender>) -> Result<bool, Self::Error>,
fn eq_by<L, F>(self, other: L, eq: F) -> Result<bool, Self::Error>where
Self: Sized,
L: IntoFallibleLender<Error = Self::Error>,
F: for<'all> FnMut(FallibleLend<'all, Self>, FallibleLend<'all, L::FallibleLender>) -> Result<bool, Self::Error>,
Source§fn ne<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialEq<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn ne<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialEq<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn lt<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn lt<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn le<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn le<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn gt<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn gt<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn ge<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
fn ge<L>(self, other: L) -> Result<bool, Self::Error>where
L: IntoFallibleLender<Error = Self::Error>,
for<'all> FallibleLend<'all, Self>: PartialOrd<FallibleLend<'all, L::FallibleLender>>,
Self: Sized,
Source§fn iter<'this>(self) -> Iter<'this, Self> ⓘwhere
Self: Sized + 'this,
for<'all> FallibleLend<'all, Self>: 'this,
fn iter<'this>(self) -> Iter<'this, Self> ⓘwhere
Self: Sized + 'this,
for<'all> FallibleLend<'all, Self>: 'this,
Turns this
FallibleLender into a
FallibleIterator where it has
already fulfilled the requirements of the
FallibleIterator trait. Read moreSource§fn lender_by_ref<'this>(self) -> FromFallibleIterRef<Iter<'this, Self>>where
Self: Sized + 'this,
for<'all> FallibleLend<'all, Self>: 'this,
fn lender_by_ref<'this>(self) -> FromFallibleIterRef<Iter<'this, Self>>where
Self: Sized + 'this,
for<'all> FallibleLend<'all, Self>: 'this,
Turns this
FallibleLender into a new
FallibleLender that lends references to the items
of the original lender. Read moreSource§impl<'lend, L, St, F> FallibleLending<'lend> for Scan<L, St, F>where
F: for<'all> FnMutHKAResOpt<'all, (&'all mut St, FallibleLend<'all, L>), L::Error>,
L: FallibleLender,
impl<'lend, L, St, F> FallibleLending<'lend> for Scan<L, St, F>where
F: for<'all> FnMutHKAResOpt<'all, (&'all mut St, FallibleLend<'all, L>), L::Error>,
L: FallibleLender,
Source§type Lend = <F as FnMutHKAResOpt<'lend, (&'lend mut St, <L as FallibleLending<'lend>>::Lend), <L as FallibleLender>::Error>>::B
type Lend = <F as FnMutHKAResOpt<'lend, (&'lend mut St, <L as FallibleLending<'lend>>::Lend), <L as FallibleLender>::Error>>::B
The type being lent.
Source§impl<L, St, F> Lender for Scan<L, St, F>
impl<L, St, F> Lender for Scan<L, St, F>
Source§fn __check_covariance<'long: 'short, 'short>(
proof: CovariantProof<<Self as Lending<'long>>::Lend>,
) -> CovariantProof<<Self as Lending<'short>>::Lend>
fn __check_covariance<'long: 'short, 'short>( proof: CovariantProof<<Self as Lending<'long>>::Lend>, ) -> CovariantProof<<Self as Lending<'short>>::Lend>
Internal method for compile-time covariance checking. Read more
Source§fn next(&mut self) -> Option<Lend<'_, Self>>
fn next(&mut self) -> Option<Lend<'_, Self>>
Yields the next lend, if any, of the lender. Read more
Source§fn size_hint(&self) -> (usize, Option<usize>)
fn size_hint(&self) -> (usize, Option<usize>)
Gets the estimated minimum and maximum length of the lender. Use
.len() for the exact length if the lender
implements ExactSizeLender. Read moreSource§fn next_chunk(&mut self, chunk_size: usize) -> Chunk<'_, Self>where
Self: Sized,
fn next_chunk(&mut self, chunk_size: usize) -> Chunk<'_, Self>where
Self: Sized,
Takes the next
chunk_size lends of the lender with temporary lender
Chunk. This is equivalent to cloning the lender and calling
take(chunk_size) on it. Read moreSource§fn count(self) -> usizewhere
Self: Sized,
fn count(self) -> usizewhere
Self: Sized,
Counts the number of lends in the lender by consuming it. Read more
Source§fn last<'call>(&'call mut self) -> Option<Lend<'call, Self>>where
Self: Sized,
fn last<'call>(&'call mut self) -> Option<Lend<'call, Self>>where
Self: Sized,
Gets the last lend of the lender, if any, by consuming it. Read more
Source§fn advance_by(&mut self, n: usize) -> Result<(), NonZeroUsize>
fn advance_by(&mut self, n: usize) -> Result<(), NonZeroUsize>
Advances the lender by
n lends. Read moreSource§fn step_by(self, step: usize) -> StepBy<Self>where
Self: Sized,
fn step_by(self, step: usize) -> StepBy<Self>where
Self: Sized,
Skips
step - 1 lends between each lend of the lender. Read moreSource§fn chain<U>(self, other: U) -> Chain<Self, <U as IntoLender>::Lender>
fn chain<U>(self, other: U) -> Chain<Self, <U as IntoLender>::Lender>
Chains the lender with another lender of the same type. Read more
Source§fn zip<U: IntoLender>(self, other: U) -> Zip<Self, <U as IntoLender>::Lender>where
Self: Sized,
fn zip<U: IntoLender>(self, other: U) -> Zip<Self, <U as IntoLender>::Lender>where
Self: Sized,
Zips the lender with another lender of the same or different type. Read more
Source§fn intersperse<'call>(
self,
separator: Lend<'call, Self>,
) -> Intersperse<'call, Self>
fn intersperse<'call>( self, separator: Lend<'call, Self>, ) -> Intersperse<'call, Self>
Intersperses each lend of this lender with the given separator. Read more
Source§fn intersperse_with<'call, G>(
self,
separator: G,
) -> IntersperseWith<'call, Self, G>
fn intersperse_with<'call, G>( self, separator: G, ) -> IntersperseWith<'call, Self, G>
Intersperses each lend of this lender with the separator produced by
the given function. Read more
Source§fn map<F>(self, f: Covar<F>) -> Map<Self, F>
fn map<F>(self, f: Covar<F>) -> Map<Self, F>
Maps each lend of this lender using the given function. Read more
Source§fn map_into_iter<O, F: FnMut(Lend<'_, Self>) -> O>(
self,
f: F,
) -> MapIntoIter<Self, O, F> ⓘwhere
Self: Sized,
fn map_into_iter<O, F: FnMut(Lend<'_, Self>) -> O>(
self,
f: F,
) -> MapIntoIter<Self, O, F> ⓘwhere
Self: Sized,
Maps each lend of this lender into an owned value using the given function. Read more
Source§fn filter<P>(self, predicate: P) -> Filter<Self, P>
fn filter<P>(self, predicate: P) -> Filter<Self, P>
Filters this lender using the given predicate. Read more
Source§fn filter_map<F>(self, f: Covar<F>) -> FilterMap<Self, F>
fn filter_map<F>(self, f: Covar<F>) -> FilterMap<Self, F>
Filters and maps this lender using the given function. Read more
Source§fn enumerate(self) -> Enumerate<Self>where
Self: Sized,
fn enumerate(self) -> Enumerate<Self>where
Self: Sized,
Enumerates this lender. Each lend is paired with its zero-based index. Read more
Source§fn peekable<'call>(self) -> Peekable<'call, Self>where
Self: Sized,
fn peekable<'call>(self) -> Peekable<'call, Self>where
Self: Sized,
Makes this lender peekable, so that it is possible to peek at the next
lend without consuming it. Read more
Source§fn skip_while<P>(self, predicate: P) -> SkipWhile<Self, P>
fn skip_while<P>(self, predicate: P) -> SkipWhile<Self, P>
Skips the first contiguous sequence of lends of this lender that
satisfy the given predicate. Read more
Source§fn take_while<P>(self, predicate: P) -> TakeWhile<Self, P>
fn take_while<P>(self, predicate: P) -> TakeWhile<Self, P>
Takes the first contiguous sequence of lends of this lender that
satisfy the given predicate. Read more
Source§fn skip(self, n: usize) -> Skip<Self>where
Self: Sized,
fn skip(self, n: usize) -> Skip<Self>where
Self: Sized,
Skips the first
n lends of this lender. Read moreSource§fn take(self, n: usize) -> Take<Self>where
Self: Sized,
fn take(self, n: usize) -> Take<Self>where
Self: Sized,
Takes the first
n lends of this lender. Read moreSource§fn mutate<F>(self, f: F) -> Mutate<Self, F>
fn mutate<F>(self, f: F) -> Mutate<Self, F>
Mutates each lend with the given function. Read more
Source§fn collect<B>(self) -> Bwhere
Self: Sized,
B: FromLender<Self>,
fn collect<B>(self) -> Bwhere
Self: Sized,
B: FromLender<Self>,
Source§fn try_collect<'a, B>(&'a mut self) -> ChangeOutputType<Lend<'a, Self>, B>
fn try_collect<'a, B>(&'a mut self) -> ChangeOutputType<Lend<'a, Self>, B>
Source§fn collect_into<E>(self, collection: &mut E) -> &mut Ewhere
Self: Sized,
E: ExtendLender<Self>,
fn collect_into<E>(self, collection: &mut E) -> &mut Ewhere
Self: Sized,
E: ExtendLender<Self>,
Source§fn is_partitioned<P>(self, predicate: P) -> bool
fn is_partitioned<P>(self, predicate: P) -> bool
Source§fn try_for_each<F, R>(&mut self, f: F) -> R
fn try_for_each<F, R>(&mut self, f: F) -> R
Source§fn try_reduce<T, F, R>(self, f: F) -> ChangeOutputType<R, Option<T>>
fn try_reduce<T, F, R>(self, f: F) -> ChangeOutputType<R, Option<T>>
Source§fn find_map<'a, F>(
&'a mut self,
f: F,
) -> Option<<F as FnMutHKAOpt<'a, Lend<'a, Self>>>::B>
fn find_map<'a, F>( &'a mut self, f: F, ) -> Option<<F as FnMutHKAOpt<'a, Lend<'a, Self>>>::B>
Source§fn max_by_key<B: Ord, T, F>(self, f: F) -> Option<T>
fn max_by_key<B: Ord, T, F>(self, f: F) -> Option<T>
Source§fn min_by_key<B: Ord, T, F>(self, f: F) -> Option<T>
fn min_by_key<B: Ord, T, F>(self, f: F) -> Option<T>
Source§fn unzip<ExtA, ExtB>(self) -> (ExtA, ExtB)where
Self: Sized,
for<'all> Lend<'all, Self>: TupleLend<'all>,
ExtA: Default + ExtendLender<FirstShunt<Self>>,
ExtB: Default + ExtendLender<SecondShunt<Self>>,
fn unzip<ExtA, ExtB>(self) -> (ExtA, ExtB)where
Self: Sized,
for<'all> Lend<'all, Self>: TupleLend<'all>,
ExtA: Default + ExtendLender<FirstShunt<Self>>,
ExtB: Default + ExtendLender<SecondShunt<Self>>,
Source§fn product<P>(self) -> Pwhere
Self: Sized,
P: ProductLender<Self>,
fn product<P>(self) -> Pwhere
Self: Sized,
P: ProductLender<Self>,
Source§fn partial_cmp<L>(self, other: L) -> Option<Ordering>
fn partial_cmp<L>(self, other: L) -> Option<Ordering>
Source§fn partial_cmp_by<L, F>(self, other: L, partial_cmp: F) -> Option<Ordering>
fn partial_cmp_by<L, F>(self, other: L, partial_cmp: F) -> Option<Ordering>
Source§fn is_sorted_by<T, F>(self, compare: F) -> bool
fn is_sorted_by<T, F>(self, compare: F) -> bool
Source§fn is_sorted_by_key<F, K>(self, f: F) -> bool
fn is_sorted_by_key<F, K>(self, f: F) -> bool
Source§fn lender_by_ref<'this>(self) -> FromIterRef<Iter<'this, Self>>
fn lender_by_ref<'this>(self) -> FromIterRef<Iter<'this, Self>>
Source§fn convert<E>(self) -> Convert<E, Self>where
Self: Sized,
fn convert<E>(self) -> Convert<E, Self>where
Self: Sized,
Converts a
Lender whose lend type is Result<T, E> into a
FallibleLender with error type E and lend type T. Read moreSource§fn into_fallible(self) -> IntoFallible<Self>where
Self: Sized,
fn into_fallible(self) -> IntoFallible<Self>where
Self: Sized,
Converts a
Lender into a FallibleLender
by wrapping into Result<Lend<'_, Self>, Infallible> where
Infallible is an error that can never actually happen. Read moreAuto Trait Implementations§
impl<L, St, F> Freeze for Scan<L, St, F>
impl<L, St, F> RefUnwindSafe for Scan<L, St, F>
impl<L, St, F> Send for Scan<L, St, F>
impl<L, St, F> Sync for Scan<L, St, F>
impl<L, St, F> Unpin for Scan<L, St, F>
impl<L, St, F> UnsafeUnpin for Scan<L, St, F>
impl<L, St, F> UnwindSafe for Scan<L, St, F>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<L> IntoFallibleLender for Lwhere
L: FallibleLender,
impl<L> IntoFallibleLender for Lwhere
L: FallibleLender,
Source§type Error = <L as FallibleLender>::Error
type Error = <L as FallibleLender>::Error
The error type of the resulting fallible lender.
Source§type FallibleLender = L
type FallibleLender = L
The fallible lender type that this type converts into.
Source§fn into_fallible_lender(self) -> L
fn into_fallible_lender(self) -> L
Converts this type into a
FallibleLender.