pub trait DisplayTreeNode: Sized {
// Required methods
fn tree_children(&self) -> &[Self];
fn tree_child_name(&self, index: usize) -> ChildName;
fn fmt_tree_node(&self, f: &mut Formatter<'_>) -> Result;
}Expand description
A node of an expression tree that DisplayTreeExpr can render.
Required Methods§
Sourcefn tree_children(&self) -> &[Self]
fn tree_children(&self) -> &[Self]
The children of this node, in argument order.
Sourcefn tree_child_name(&self, index: usize) -> ChildName
fn tree_child_name(&self, index: usize) -> ChildName
The display name of the child at index.
Sourcefn fmt_tree_node(&self, f: &mut Formatter<'_>) -> Result
fn fmt_tree_node(&self, f: &mut Formatter<'_>) -> Result
Write this node’s own label.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".