Skip to main content

for_each_candidate

Function for_each_candidate 

Source
fn for_each_candidate(
    root: &Path,
    walk_root: &Path,
    respect_gitignore: bool,
    cancel: Option<&Arc<AtomicBool>>,
    emit: &mut impl FnMut(FileCandidate) -> bool,
) -> bool
Expand description

Walk walk_root (rooted relative to root), invoking emit for each FileCandidate. emit returning false cancels the walk. Returns true when the walk completed naturally, false when cancelled (either by emit’s return or the optional cancel flag).