pub struct Predicate<F>(/* private fields */);Expand description
Run a closure over each candidate; the first true wins.
The escape hatch for application-specific logic that does not warrant its own type — matching a serial number out of the manufacturer data, say.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<F> Forget for Predicate<F>
impl<F> Freeze for Predicate<F>
impl<F> Move for Predicate<F>
impl<F> RefUnwindSafe for Predicate<F>where
Arc<F>: RefUnwindSafe,
impl<F> Send for Predicate<F>
impl<F> Sync for Predicate<F>
impl<F> Unpin for Predicate<F>
impl<F> UnsafeUnpin for Predicate<F>where
Arc<F>: UnsafeUnpin,
impl<F> UnwindSafe for Predicate<F>where
Arc<F>: UnwindSafe,
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