git_next_core/git/generation.rs
1use derive_more::Display;
2
3use crate::newtype;
4
5newtype!(
6 Generation,
7 u32,
8 Display,
9 Default,
10 Copy,
11 r#"A counter for the server generation.
12
13This counter is increased by one each time the server restarts itself when the configuration file is updated."#
14);
15impl Generation {
16 pub fn inc(&mut self) {
17 self.0 += 1;
18 }
19}