Skip to main content

Filter

Trait Filter 

Source
pub trait Filter<F, V>: Sized {
    // Required method
    fn select_filtered(filter: F) -> V;
}
Expand description

Collection-level filtering for selection options.

Enables filtering Select options based on runtime predicates.

Required Methods§

Source

fn select_filtered(filter: F) -> V

Filter options based on the given predicate.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<T, F> Filter<F, Vec<T>> for T
where T: Select, F: Fn(&T) -> bool,

Blanket implementation for closure-based filtering.