pub struct ValueFilter<Tuple, Val, Func: Fn(&Tuple, &Val) -> bool> { /* private fields */ }Expand description
A treefrog leaper based on a predicate of prefix and value.
Use like ValueFilter::from(|tuple, value| ...). The closure
should return true if value ought to be retained. The
value will be a value proposed elsewhere by an extend_with
leaper.
This leaper cannot be used in isolation, it must be combined with other leapers.
Implementations§
Trait Implementations§
Source§impl<'leap, Tuple, Val, Func> Leaper<'leap, Tuple, Val> for ValueFilter<Tuple, Val, Func>
impl<'leap, Tuple, Val, Func> Leaper<'leap, Tuple, Val> for ValueFilter<Tuple, Val, Func>
Auto Trait Implementations§
impl<Tuple, Val, Func> Freeze for ValueFilter<Tuple, Val, Func>where
Func: Freeze,
impl<Tuple, Val, Func> RefUnwindSafe for ValueFilter<Tuple, Val, Func>
impl<Tuple, Val, Func> Send for ValueFilter<Tuple, Val, Func>
impl<Tuple, Val, Func> Sync for ValueFilter<Tuple, Val, Func>
impl<Tuple, Val, Func> Unpin for ValueFilter<Tuple, Val, Func>
impl<Tuple, Val, Func> UnwindSafe for ValueFilter<Tuple, Val, Func>
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