Struct rax::RaxSet[][src]

pub struct RaxSet<K: RaxKey> { /* fields omitted */ }

RaxMap but without the values. The "isnull" bit will be set for all entries. #Examples

let mut r = RaxSet::new();
r.insert(1);
r.insert(2);

r.iter(|r, iter| {
    // Place iterator at the first entry.
    if !iter.seek_min() {
        // EOF
        return
    }

    // Can test EOF at any time.
    if iter.eof() {
        // EOF
        return
    }

    while iter.forward() {
        iter.key();
    }
    // In reverse
    // Place iterator at the end.
    if !iter.end() {
        // EOF
        return
    }
    while iter.back() {
        iter.key();
    }

    // Seek
    if !iter.seek(">=", 2) {
        // EOF
    }
    while iter.forward() {
        iter.key();
    }
});

Methods

impl<K: RaxKey> RaxSet<K>
[src]

The number of entries in the RAX

The number of entries in the RAX

Prints the Rax as ASCII art to stdout.

Insert a new entry into the RAX replacing and returning the existing entry for the supplied key.

Determines if the supplied key exists in the Rax.

Trait Implementations

impl<K: RaxKey> Drop for RaxSet<K>
[src]

Executes the destructor for this type. Read more

Auto Trait Implementations

impl<K> !Send for RaxSet<K>

impl<K> !Sync for RaxSet<K>