pub struct NoFilter;Expand description
A Filter, FileFilter,
FolderFilter, and FolderRecurseFilter that allows all paths.
This can be passed as a filter to DirChildren and DirDescendants to read all paths; custom
filtering will require a new filter type.
assert!(NoFilter::allows(Path::new("foo.txt")));
assert!(NoFilter::allows(Path::new("foo/bar.txt")));
assert!(NoFilter::allows(Path::new("foo/bar/baz.txt")));
assert!(NoFilter::allows(Path::new("foo/bar/baz")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/.")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/..")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/../..")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/../../..")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/../../../..")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/../../../../..")));
assert!(NoFilter::allows(Path::new("foo/bar/baz/../../../../../..")));Trait Implementations§
impl Copy for NoFilter
impl Eq for NoFilter
impl StructuralPartialEq for NoFilter
Auto Trait Implementations§
impl Freeze for NoFilter
impl RefUnwindSafe for NoFilter
impl Send for NoFilter
impl Sync for NoFilter
impl Unpin for NoFilter
impl UnwindSafe for NoFilter
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> DirStructureItem for T
impl<T> DirStructureItem for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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