pub struct AnalyzeBuilder { /* private fields */ }Implementations§
Source§impl AnalyzeBuilder
impl AnalyzeBuilder
Sourcepub fn extensions(
self,
exts: impl IntoIterator<Item = impl Into<String>>,
) -> Self
pub fn extensions( self, exts: impl IntoIterator<Item = impl Into<String>>, ) -> Self
Only files with one of these extensions (case-insensitive, without the leading dot) are matched. Unset matches any extension, including files with none.
Sourcepub fn exclude_globs(
self,
patterns: impl IntoIterator<Item = impl Into<String>>,
) -> Self
pub fn exclude_globs( self, patterns: impl IntoIterator<Item = impl Into<String>>, ) -> Self
Glob patterns (matched against the path relative to the analyzed root) that prune traversal entirely — an excluded directory is never descended into, not merely omitted from the report.
pub fn min_size(self, bytes: u64) -> Self
pub fn max_size(self, bytes: u64) -> Self
Sourcepub fn modified_after(self, t: SystemTime) -> Self
pub fn modified_after(self, t: SystemTime) -> Self
Only files modified at or after t are matched. A file with no
readable modified time never matches once this is set.
Sourcepub fn modified_before(self, t: SystemTime) -> Self
pub fn modified_before(self, t: SystemTime) -> Self
Only files modified at or before t are matched. A file with no
readable modified time never matches once this is set.
Sourcepub fn max_depth(self, depth: usize) -> Self
pub fn max_depth(self, depth: usize) -> Self
Bounds how far the walk descends: the analyzed root is depth 0,
its immediate children depth 1, and so on — passed straight
through to jwalk’s own max_depth, which prunes traversal past
the bound rather than filtering after the fact.
Sourcepub fn follow_symlinks(self, follow: bool) -> Self
pub fn follow_symlinks(self, follow: bool) -> Self
Off by default. When enabled, jwalk’s own loop detection
surfaces a symlink cycle as a per-entry error, handled like any
other error via .on_error().
Sourcepub fn walk_concurrency(self, n: usize) -> Self
pub fn walk_concurrency(self, n: usize) -> Self
How many worker threads jwalk uses to read directories and stat
entries concurrently while walking. Defaults to
available_parallelism(), matching hash_concurrency.
Traversal is still reported (and aggregated into AnalysisReport)
in a single stream on the calling task — this only parallelizes
the underlying directory reads and stat calls, which is where
wall time actually goes on large trees or slow/network
filesystems.
Sourcepub fn top_n_largest(self, n: usize) -> Self
pub fn top_n_largest(self, n: usize) -> Self
How many of the largest matched files to keep in
AnalysisReport::largest_files. 0 disables the tracking
entirely.
Sourcepub fn detect_mime_types(self, enable: bool) -> Self
pub fn detect_mime_types(self, enable: bool) -> Self
Off by default — sniffing every matched file’s header via infer
is an extra read per file, on top of the metadata walkdir
already reads for every entry.
pub fn on_error(self, strategy: AnalysisErrorStrategy) -> Self
Sourcepub fn max_reported_errors(self, n: usize) -> Self
pub fn max_reported_errors(self, n: usize) -> Self
Caps AnalysisReport::errors; AnalysisReport::errors_total
stays uncapped regardless of this setting.
pub fn start(self) -> Result<AnalysisHandle>
Auto Trait Implementations§
impl Freeze for AnalyzeBuilder
impl RefUnwindSafe for AnalyzeBuilder
impl Send for AnalyzeBuilder
impl Sync for AnalyzeBuilder
impl Unpin for AnalyzeBuilder
impl UnsafeUnpin for AnalyzeBuilder
impl UnwindSafe for AnalyzeBuilder
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
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> ⓘ
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> ⓘ
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