Struct indextree_ng::Arena
[−]
[src]
pub struct Arena<T> { /* fields omitted */ }
An Arena
structure containing certain Nodes
Methods
impl<T> Arena<T>
[src]
fn new() -> Arena<T>
[src]
Create a new empty Arena
fn new_node(&mut self, data: T) -> NodeId
[src]
Create a new node from its associated data.
fn remove_node(&mut self, node: NodeId)
[src]
Removes a node from the arena. Detaches all children before.
fn len(&self) -> usize
[src]
Returns the number of nodes in Arena
fn is_empty(&self) -> bool
[src]
Returns true if arena has no nodes, false otherwise
Trait Implementations
impl<T: Clone> Clone for Arena<T>
[src]
fn clone(&self) -> Arena<T>
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<T: Debug> Debug for Arena<T>
[src]
impl<T> Index<NodeId> for Arena<T>
[src]
type Output = Node<T>
The returned type after indexing.
fn index(&self, node: NodeId) -> &Node<T>
[src]
Performs the indexing (container[index]
) operation.