pub struct TreeNode {
pub name: String,
pub kind: NodeKind,
pub total_size: u64,
pub file_count: u64,
pub parent: Option<NodeId>,
pub depth: u16,
}Expand description
A node in the arena-allocated file tree.
Fields§
§name: StringFile or directory name (just the component, not full path)
kind: NodeKindKind-specific data
total_size: u64Total size of this node and all descendants (bytes)
file_count: u64Number of files in this subtree (1 for files, sum for dirs)
parent: Option<NodeId>Parent node (None for root)
depth: u16Depth from root (root = 0)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TreeNode
impl RefUnwindSafe for TreeNode
impl Send for TreeNode
impl Sync for TreeNode
impl Unpin for TreeNode
impl UnsafeUnpin for TreeNode
impl UnwindSafe for TreeNode
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