1 2 3 4 5 6 7 8 9 10 11
#[derive(Hash, PartialEq, Eq, Clone, Copy, Debug)] pub struct ActionID(&'static str); impl ActionID { pub fn new(id: &'static str) -> Self { ActionID(id) } } pub trait ActionIdentifier { fn action_id() -> ActionID; }