Skip to main content

budoux_phf_rs/
model.rs

1pub type ScoreMap = phf::Map<&'static str, i16>;
2
3pub struct Model {
4    pub total_score: i32,
5    pub uw1: &'static ScoreMap,
6    pub uw2: &'static ScoreMap,
7    pub uw3: &'static ScoreMap,
8    pub uw4: &'static ScoreMap,
9    pub uw5: &'static ScoreMap,
10    pub uw6: &'static ScoreMap,
11    pub bw1: &'static ScoreMap,
12    pub bw2: &'static ScoreMap,
13    pub bw3: &'static ScoreMap,
14    pub tw1: &'static ScoreMap,
15    pub tw2: &'static ScoreMap,
16    pub tw3: &'static ScoreMap,
17    pub tw4: &'static ScoreMap,
18}
19
20impl Model {
21    pub fn total_score(&self) -> i32 {
22        self.total_score
23    }
24}