pub trait IGenID<Gen = u32>:
From<(usize, Gen)>
+ Into<(usize, Gen)>
+ Clone
+ Copy
+ PartialEq
+ Eq
+ Hash
+ Ord
+ PartialOrd
+ Defaultwhere
Gen: IGeneration,{
const NULL: Self;
// Required methods
fn index(self) -> usize;
fn generation(self) -> Gen;
// Provided methods
fn from_index_and_generation(index: usize, generation: Gen) -> Self { ... }
fn index_and_generation(self) -> (usize, Gen) { ... }
fn is_null(self) -> bool { ... }
fn is_not_null(self) -> bool { ... }
fn reset(&mut self) { ... }
fn typed<T>(self) -> GenIDOf<T, Gen> { ... }
fn untyped(self) -> UntypedGenIDOf<Gen> { ... }
}Required Associated Constants§
Required Methods§
fn index(self) -> usize
fn generation(self) -> Gen
Provided Methods§
fn from_index_and_generation(index: usize, generation: Gen) -> Self
fn index_and_generation(self) -> (usize, Gen)
fn is_null(self) -> bool
fn is_not_null(self) -> bool
fn typed<T>(self) -> GenIDOf<T, Gen>
fn untyped(self) -> UntypedGenIDOf<Gen>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.