pub trait EqualityIndex<T> {
    fn lookup<'a>(&'a self, _: &T) -> Box<dyn Iterator<Item = usize> + 'a>;
    fn index(&mut self, _: T, _: usize);
    fn undex(&mut self, _: &T, _: usize);
    fn estimate(&self) -> usize;
}
Expand description

An EqualityIndex is an index that can perform efficient equality lookups.

Required Methods§

Return an iterator that yields the indices of all rows that match the given value.

Add the given row index to the index under the given value.

Remove the given row index under the given value from the index.

Give the expected number of rows returned for a key. This method may be called often, and in rapid succession, and so should return quickly.

Implementors§