Struct rin::ecs::NodeId [−][src]
pub struct NodeId { /* fields omitted */ }
A node identifier within a particular Arena
.
Implementations
impl NodeId
[src]
impl NodeId
[src]pub fn ancestors<T>(self, arena: &Arena<T>) -> Ancestors<'_, T>
[src]
Return an iterator of references to this node and its ancestors.
Call .next().unwrap()
once on the iterator to skip the node itself.
pub fn preceding_siblings<T>(self, arena: &Arena<T>) -> PrecedingSiblings<'_, T>
[src]
Return an iterator of references to this node and the siblings before it.
Call .next().unwrap()
once on the iterator to skip the node itself.
pub fn following_siblings<T>(self, arena: &Arena<T>) -> FollowingSiblings<'_, T>
[src]
Return an iterator of references to this node and the siblings after it.
Call .next().unwrap()
once on the iterator to skip the node itself.
pub fn children<T>(self, arena: &Arena<T>) -> Children<'_, T>
[src]
Return an iterator of references to this node’s children.
pub fn reverse_children<T>(self, arena: &Arena<T>) -> ReverseChildren<'_, T>
[src]
Return an iterator of references to this node’s children, in reverse order.
pub fn descendants<T>(self, arena: &Arena<T>) -> Descendants<'_, T>
[src]
Return an iterator of references to this node and its descendants, in tree order.
Parent nodes appear before the descendants.
Call .next().unwrap()
once on the iterator to skip the node itself.
pub fn traverse<T>(self, arena: &Arena<T>) -> Traverse<'_, T>
[src]
Return an iterator of references to this node and its descendants, in tree order.
pub fn reverse_traverse<T>(self, arena: &Arena<T>) -> ReverseTraverse<'_, T>
[src]
Return an iterator of references to this node and its descendants, in tree order.
pub fn detach<T>(self, arena: &mut Arena<T>) -> NodeRefMut<'_, T>
[src]
Detach a node from its parent and siblings. Children are not affected.
pub fn append<T>(
self,
new_child: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_child: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
Append a new child to this node, after existing children.
pub fn append_new<T>(
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
pub fn prepend<T>(
self,
new_child: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_child: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
Prepend a new child to this node, before existing children.
pub fn prepend_new<T>(
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
pub fn insert_after<T>(
self,
new_sibling: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_sibling: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
Insert a new sibling after this node.
pub fn insert_after_new<T>(
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
pub fn insert_before<T>(
self,
new_sibling: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_sibling: NodeId,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
Insert a new sibling before this node.
pub fn insert_before_new<T>(
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
[src]
self,
new_data: T,
arena: &mut Arena<T>
) -> NodeRefMut<'_, T>
Trait Implementations
impl<'a, T> From<NodeRefMut<'a, T>> for NodeId
[src]
impl<'a, T> From<NodeRefMut<'a, T>> for NodeId
[src]pub fn from(node: NodeRefMut<'a, T>) -> NodeId
[src]
impl Copy for NodeId
[src]
impl Eq for NodeId
[src]
impl StructuralEq for NodeId
[src]
impl StructuralPartialEq for NodeId
[src]
Auto Trait Implementations
impl RefUnwindSafe for NodeId
impl Send for NodeId
impl Sync for NodeId
impl Unpin for NodeId
impl UnwindSafe for NodeId
Blanket Implementations
impl<T> DowncastSync for T where
T: Any + Send + Sync,
[src]
impl<T> DowncastSync for T where
T: Any + Send + Sync,
[src]impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]
impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]pub fn equivalent(&self, key: &K) -> bool
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]pub fn to_subset(&self) -> Option<SS>
[src]
pub fn is_in_subset(&self) -> bool
[src]
pub fn to_subset_unchecked(&self) -> SS
[src]
pub fn from_subset(element: &SS) -> SP
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]pub fn to_subset(&self) -> Option<SS>
[src]
pub fn is_in_subset(&self) -> bool
[src]
pub fn to_subset_unchecked(&self) -> SS
[src]
pub fn from_subset(element: &SS) -> SP
[src]
impl<T> Slottable for T where
T: Copy,
[src]
T: Copy,