On this page
query.Matcher
- Module
- query
- Package
- libtmux
- Source
- crates/libtmux/src/query.rs
-
A predicate that evaluates a borrowed candidate.
Functions and closures with the same signature implement this trait.
Examples
use libtmux::query::Matcher; struct IsEven; impl Matcher<i32> for IsEven { fn matches(&self, candidate: &i32) -> bool { candidate % 2 == 0 } } assert!(IsEven.matches(&2)); assert!(!IsEven.matches(&3));
0 declared, 0 inherited