Struct itree::options::FsOptions [−][src]
pub struct FsOptions<P: AsRef<Path>> { pub root: P, pub max_depth: Option<usize>, pub follow_links: bool, pub max_filesize: Option<u64>, pub hidden: bool, pub only_dirs: bool, pub no_ignore: bool, pub no_git_exclude: bool, pub custom_ignore: Vec<String>, }
Fields
root: P
max_depth: Option<usize>
follow_links: bool
max_filesize: Option<u64>
only_dirs: bool
no_ignore: bool
no_git_exclude: bool
custom_ignore: Vec<String>
Methods
impl<P: AsRef<Path>> FsOptions<P>
[src]
impl<P: AsRef<Path>> FsOptions<P>
pub fn new(root: P) -> Self
[src]
pub fn new(root: P) -> Self
ⓘImportant traits for &'a mut Rpub fn root(&mut self, root: P) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn root(&mut self, root: P) -> &mut Self
Set the root directory from which to build the tree.
ⓘImportant traits for &'a mut Rpub fn max_depth(&mut self, max_depth: Option<usize>) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn max_depth(&mut self, max_depth: Option<usize>) -> &mut Self
Set a maximum depth for the tree to search. None
indicates no limit.
None
by default.
ⓘImportant traits for &'a mut Rpub fn follow_links(&mut self, follow_links: bool) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn follow_links(&mut self, follow_links: bool) -> &mut Self
Set whether or not to follow links.
Disabled by default.
ⓘImportant traits for &'a mut Rpub fn max_filesize(&mut self, max_filesize: Option<u64>) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn max_filesize(&mut self, max_filesize: Option<u64>) -> &mut Self
Set a maximum file size to include. None
indicates no limit.
None
by default.
ⓘImportant traits for &'a mut R
ⓘImportant traits for &'a mut R
Set whether or not to ignore hidden files.
Enabled by default.
ⓘImportant traits for &'a mut Rpub fn only_dirs(&mut self, only_dirs: bool) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn only_dirs(&mut self, only_dirs: bool) -> &mut Self
Set whether or not to consider directories only.
Disabled by default.
ⓘImportant traits for &'a mut Rpub fn no_ignore(&mut self, no_ignore: bool) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn no_ignore(&mut self, no_ignore: bool) -> &mut Self
Set whether or not to read .[git]ignore
files.
Enabled by default.
ⓘImportant traits for &'a mut Rpub fn no_git_exclude(&mut self, no_git_exclude: bool) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn no_git_exclude(&mut self, no_git_exclude: bool) -> &mut Self
Set whether or not to read .git/info/exclude
files.
Enabled by default.
ⓘImportant traits for &'a mut Rpub fn add_custom_ignore(&mut self, path: &str) -> &mut Self
[src]
ⓘImportant traits for &'a mut R
pub fn add_custom_ignore(&mut self, path: &str) -> &mut Self
Add a custom ignore path.