Struct intrusive_collections::rbtree::Cursor [] [src]

pub struct Cursor<'a, A: for<'b> TreeAdaptor<'b> + 'a> {
    // some fields omitted
}

A cursor which provides read-only access to a RBTree.

Methods

impl<'a, A: for<'b> TreeAdaptor<'b> + 'a> Cursor<'a, A>
[src]

fn is_null(&self) -> bool

Checks if the cursor is currently pointing to the null object.

fn get_raw(&self) -> Option<*const A::Container>

Returns a raw pointer to the object that the cursor is currently pointing to.

This returns None if the cursor is currently pointing to the null object.

fn get(&self) -> Option<&'a A::Container>

Returns a reference to the object that the cursor is currently pointing to.

This returns None if the cursor is currently pointing to the null object.

fn move_next(&mut self)

Moves the cursor to the next element of the RBTree.

If the cursor is pointer to the null object then this will move it to the first element of the RBTree. If it is pointing to the last element of the RBTree then this will move it to the null object.

fn move_prev(&mut self)

Moves the cursor to the previous element of the RBTree.

If the cursor is pointer to the null object then this will move it to the last element of the RBTree. If it is pointing to the first element of the RBTree then this will move it to the null object.

Trait Implementations

impl<'a, A: for<'b> TreeAdaptor<'b> + 'a> Copy for Cursor<'a, A>
[src]

impl<'a, A: for<'b> TreeAdaptor<'b> + 'a> Clone for Cursor<'a, A>
[src]

fn clone(&self) -> Cursor<'a, A>

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more