pub trait DupReadCursor<'txn, T: DupTable>: ReadCursor<'txn, T> {
// Required methods
fn first_duplicate(&mut self) -> Option<T::Value>;
fn last_duplicate(&mut self) -> Option<T::Value>;
fn next_duplicate(&mut self) -> Option<Row<T>>;
fn next_no_duplicate(&mut self) -> Option<Row<T>>;
fn prev_duplicate(&mut self) -> Option<Row<T>>;
fn prev_no_duplicate(&mut self) -> Option<Row<T>>;
fn set_subkey(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<T::Value>
where T::Value: DupTableValue;
fn set_lowerbound_both(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<Row<T>>
where T::Value: DupTableValue;
fn set_lowerbound_subkey(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<T::Value>
where T::Value: DupTableValue;
fn count_duplicates(&mut self) -> usize;
fn into_iter_dup_of(self, key: &T::Key) -> Self::IntoIter;
}Required Methods§
Sourcefn first_duplicate(&mut self) -> Option<T::Value>
fn first_duplicate(&mut self) -> Option<T::Value>
Positions the cursor at the first duplicate value for the current key.
Sourcefn last_duplicate(&mut self) -> Option<T::Value>
fn last_duplicate(&mut self) -> Option<T::Value>
Positions the cursor at the last duplicate value for the current key.
Sourcefn next_duplicate(&mut self) -> Option<Row<T>>
fn next_duplicate(&mut self) -> Option<Row<T>>
Positions the cursor at the next duplicate value for the current key. This does not jump keys.
Sourcefn next_no_duplicate(&mut self) -> Option<Row<T>>
fn next_no_duplicate(&mut self) -> Option<Row<T>>
Positions the cursor at the first duplicate of the next key.
Sourcefn prev_duplicate(&mut self) -> Option<Row<T>>
fn prev_duplicate(&mut self) -> Option<Row<T>>
Positions the cursor at the previous duplicate value for the current key.
Sourcefn prev_no_duplicate(&mut self) -> Option<Row<T>>
fn prev_no_duplicate(&mut self) -> Option<Row<T>>
Positions the cursor at the last duplicate of the previous key.
Sourcefn set_subkey(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<T::Value>where
T::Value: DupTableValue,
fn set_subkey(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<T::Value>where
T::Value: DupTableValue,
Positions the cursor at the entry with a given key and subkey.
Sourcefn set_lowerbound_both(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<Row<T>>where
T::Value: DupTableValue,
fn set_lowerbound_both(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<Row<T>>where
T::Value: DupTableValue,
Positions the cursor at the first duplicate entry that has a key >= key && subkey >= subkey.
Sourcefn set_lowerbound_subkey(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<T::Value>where
T::Value: DupTableValue,
fn set_lowerbound_subkey(
&mut self,
key: &T::Key,
subkey: &DupSubKey<T>,
) -> Option<T::Value>where
T::Value: DupTableValue,
Positions the cursor at the first duplicate entry that has a key == key && subkey >= subkey.
Sourcefn count_duplicates(&mut self) -> usize
fn count_duplicates(&mut self) -> usize
Counts the number of duplicates (linear operation!).
Sourcefn into_iter_dup_of(self, key: &T::Key) -> Self::IntoIter
fn into_iter_dup_of(self, key: &T::Key) -> Self::IntoIter
Iterates over all duplicates of the given key.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".