files_in_dir

Function files_in_dir 

Source
fn files_in_dir(
    path: impl AsRef<Path>,
    list: &mut Vec<PathBuf>,
) -> Result<(), Error>
Expand description

Collects all regular files in a directory path.

ยงErrors

Returns an error if

  • path is not a directory,
  • an entry in path cannot be read,
  • metadata for an entry in path cannot be retrieved,
  • or any path in path does not represent a regular file.