pub trait IIndexAware {
// Required methods
fn index(&self) -> usize;
fn set_index(&self, index: usize);
}Expand description
An item that knows its index in a sorted collection (IIndexAware), which UpdateIndex sets.
Deviation (DEVIATIONS.md, DynamicData): the setter takes &self, as the items are shared
(Rc) and keep the index in a Cell; the index is a usize.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".