archunit

Function gather_custom_file_violations

Source
pub fn gather_custom_file_violations<P>(
    file_infos: &[FileInfo],
    predicate: &P,
    message: &str,
    is_negated: bool,
) -> Vec<Violation>
where P: Fn(&FileInfo) -> bool + ?Sized,
Expand description

Judges immutable file facts with one user-defined predicate.

The predicate is called exactly once per file. Positive rules report false; negated rules report true. Empty selections remain the terminal empty-test guard’s responsibility.