pub struct RepositoryDirectoryFormalization {
pub path: String,
pub direct_file_count: usize,
pub direct_directory_count: usize,
pub total_file_count: usize,
pub total_directory_count: usize,
pub total_line_count: usize,
pub total_byte_count: usize,
pub children: Vec<RepositoryResourceFormalization>,
}Expand description
Link-native representation of a formalized repository directory.
Fields§
§path: String§direct_file_count: usizeNumber of files directly inside this directory (non-recursive).
direct_directory_count: usizeNumber of subdirectories directly inside this directory (non-recursive).
total_file_count: usizeNumber of files anywhere in the subtree (recursive).
total_directory_count: usizeNumber of directories anywhere in the subtree, excluding this one.
total_line_count: usizeSum of line counts across every file in the subtree.
total_byte_count: usizeSum of byte counts across every file in the subtree.
children: Vec<RepositoryResourceFormalization>Ordered formalized children (files and subdirectories).
Implementations§
Source§impl RepositoryDirectoryFormalization
impl RepositoryDirectoryFormalization
Sourcepub fn summary(&self, config: &SummarizationConfig) -> String
pub fn summary(&self, config: &SummarizationConfig) -> String
Compose a prose summary for this directory by recursively summarizing its children and joining the results behind an aggregate identity sentence.
Sourcepub fn links_notation(&self) -> String
pub fn links_notation(&self) -> String
Render the formalized directory as compact indented Links Notation.
Trait Implementations§
Source§impl Clone for RepositoryDirectoryFormalization
impl Clone for RepositoryDirectoryFormalization
Source§fn clone(&self) -> RepositoryDirectoryFormalization
fn clone(&self) -> RepositoryDirectoryFormalization
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 RepositoryDirectoryFormalization
impl RefUnwindSafe for RepositoryDirectoryFormalization
impl Send for RepositoryDirectoryFormalization
impl Sync for RepositoryDirectoryFormalization
impl Unpin for RepositoryDirectoryFormalization
impl UnsafeUnpin for RepositoryDirectoryFormalization
impl UnwindSafe for RepositoryDirectoryFormalization
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