use revision::revisioned; use serde::{Deserialize, Serialize}; use std::fmt; use std::fmt::Display; #[derive(Clone, Debug, Eq, PartialEq, PartialOrd, Serialize, Deserialize, Hash)] #[revisioned(revision = 1)] pub enum Tokenizer { Blank, Camel, Class, Punct, } impl Display for Tokenizer { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { f.write_str(match self { Self::Blank => "BLANK", Self::Camel => "CAMEL", Self::Class => "CLASS", Self::Punct => "PUNCT", }) } }