pub trait Variants: Copy + 'static {
const TYPE: &'static str;
const VARIANTS: &'static [(&'static str, Self)];
const PATH: &'static str = Self::TYPE;
const TRANSITIONS: &'static [(Self, Self)] = _;
// Provided methods
fn name(self) -> &'static str { ... }
fn to(self, next: Self) -> Result<Self> { ... }
}Required Associated Constants§
Provided Associated Constants§
Sourceconst PATH: &'static str = Self::TYPE
const PATH: &'static str = Self::TYPE
Module-qualified, so two enums of one name keep their recorded moves apart.
const TRANSITIONS: &'static [(Self, Self)] = _
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".