[][src]Trait intrusive_collections::rbtree::RBTreeOps

pub unsafe trait RBTreeOps: LinkOps {
    unsafe fn left(&self, ptr: Self::LinkPtr) -> Option<Self::LinkPtr>;
unsafe fn right(&self, ptr: Self::LinkPtr) -> Option<Self::LinkPtr>;
unsafe fn parent(&self, ptr: Self::LinkPtr) -> Option<Self::LinkPtr>;
unsafe fn color(&self, ptr: Self::LinkPtr) -> Color;
unsafe fn set_left(
        &mut self,
        ptr: Self::LinkPtr,
        left: Option<Self::LinkPtr>
    );
unsafe fn set_right(
        &mut self,
        ptr: Self::LinkPtr,
        right: Option<Self::LinkPtr>
    );
unsafe fn set_parent(
        &mut self,
        ptr: Self::LinkPtr,
        parent: Option<Self::LinkPtr>
    );
unsafe fn set_color(&mut self, ptr: Self::LinkPtr, color: Color); }

Link operations for RBTree.

Required methods

unsafe fn left(&self, ptr: Self::LinkPtr) -> Option<Self::LinkPtr>

Returns the left child of ptr.

Safety

An implementation of left must not panic.

unsafe fn right(&self, ptr: Self::LinkPtr) -> Option<Self::LinkPtr>

Returns the right child of ptr.

Safety

An implementation of right must not panic.

unsafe fn parent(&self, ptr: Self::LinkPtr) -> Option<Self::LinkPtr>

Returns the parent of ptr.

Safety

An implementation of parent must not panic.

unsafe fn color(&self, ptr: Self::LinkPtr) -> Color

Returns the color of ptr.

Safety

An implementation of color must not panic.

unsafe fn set_left(&mut self, ptr: Self::LinkPtr, left: Option<Self::LinkPtr>)

Sets the left child of ptr.

Safety

An implementation of set_left must not panic.

unsafe fn set_right(&mut self, ptr: Self::LinkPtr, right: Option<Self::LinkPtr>)

Sets the right child of ptr.

Safety

An implementation of set_right must not panic.

unsafe fn set_parent(
    &mut self,
    ptr: Self::LinkPtr,
    parent: Option<Self::LinkPtr>
)

Sets the parent of ptr.

Safety

An implementation of set_parent must not panic.

unsafe fn set_color(&mut self, ptr: Self::LinkPtr, color: Color)

Sets the color of ptr.

Safety

An implementation of set_color must not panic.

Loading content...

Implementors

impl RBTreeOps for LinkOps[src]

Loading content...