Struct TakeWhileRef
#[must_use = "iterator adaptors are lazy and do nothing unless consumed"]
pub struct TakeWhileRef<'a, I: 'a, F> { /* private fields */ }
An iterator adaptor that borrows from a Clone-able iterator
to only pick off elements while the predicate returns true.
See .take_while_ref() for more information.
Trait Implementations
impl<I, F> Debug for TakeWhileRef<'_, I, F>
where
I: Iterator + Debug,
fn fmt(&self, f: &mut Formatter<'_>) -> Result
impl<I, F> Iterator for TakeWhileRef<'_, I, F>
where
I: Iterator + Clone,
F: FnMut(&I::Item) -> bool,
type Item = <I as Iterator>::Item;fn next(&mut self) -> Option<Self::Item>fn size_hint(&self) -> (usize, Option<usize>)