Struct mod3d_base::hierarchy::Node
source · pub struct Node<T>where
T: Debug,{
pub data: T,
/* private fields */
}Expand description
A node in the hierarchy
Fields§
§data: TData associated with the node
Implementations§
source§impl<T> Node<T>where
T: Debug,
impl<T> Node<T>where
T: Debug,
sourcepub fn has_parent(&self) -> bool
pub fn has_parent(&self) -> bool
Returns true if the node has a parent - i.e. it is not the root of the hierarchy
sourcepub fn set_parent(&mut self, parent: Option<usize>)
pub fn set_parent(&mut self, parent: Option<usize>)
Set the parent of a node
sourcepub fn has_children(&self) -> bool
pub fn has_children(&self) -> bool
Return true if the node has children
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for Node<T>where
T: Freeze,
impl<T> RefUnwindSafe for Node<T>where
T: RefUnwindSafe,
impl<T> Send for Node<T>where
T: Send,
impl<T> Sync for Node<T>where
T: Sync,
impl<T> Unpin for Node<T>where
T: Unpin,
impl<T> UnwindSafe for Node<T>where
T: UnwindSafe,
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)