pub trait TreeNode: Sized {
// Required methods
fn children(&self) -> &[Self];
fn children_mut(&mut self) -> Option<&mut Vec<Self>>;
}Expand description
A recursive type whose children live in a Vec.
Required Methods§
fn children(&self) -> &[Self]
Sourcefn children_mut(&mut self) -> Option<&mut Vec<Self>>
fn children_mut(&mut self) -> Option<&mut Vec<Self>>
The child list, or None for leaf variants.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".