pub struct SearchConfig { /* private fields */ }Expand description
This struct holds the configuration for searching directories.
It includes options for regex matching, hiding hidden files, keeping directories, matching file extensions, whether to search file names only, depth of search, and whether to follow symlinks.
Implementations§
Source§impl SearchConfig
impl SearchConfig
pub fn matches_with<F: FnOnce(&[u8]) -> bool>( &self, path: &[u8], predicate: F, ) -> bool
pub fn matches_extension<S>(&self, entry: &S) -> bool
pub fn matches_path<S>(&self, dir: &DirEntry<S>, full_path: bool) -> boolwhere
S: BytesStorage,
Trait Implementations§
Source§impl Clone for SearchConfig
impl Clone for SearchConfig
Source§fn clone(&self) -> SearchConfig
fn clone(&self) -> SearchConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SearchConfig
impl RefUnwindSafe for SearchConfig
impl Send for SearchConfig
impl Sync for SearchConfig
impl Unpin for SearchConfig
impl UnwindSafe for SearchConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> CloneUnsized for Twhere
T: Clone,
impl<T> CloneUnsized for Twhere
T: Clone,
Source§fn unsized_clone_from(&mut self, source: &T)
fn unsized_clone_from(&mut self, source: &T)
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more