pub trait BuildIndex:
BuildIndex
+ Copy
+ Eq
+ Ord
+ Debug
+ Hash {
// Required methods
fn to_usize(self) -> Option<usize>;
fn from_usize(value: usize) -> Option<Self>;
}Expand description
Unsigned dense ID width usable by graph and hypergraph builders.
§Performance
Implementations perform checked conversions in O(1).
Required Methods§
Sourcefn to_usize(self) -> Option<usize>
fn to_usize(self) -> Option<usize>
Converts this ID to usize when representable on the current target.
§Performance
This function is O(1).
Sourcefn from_usize(value: usize) -> Option<Self>
fn from_usize(value: usize) -> Option<Self>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".