sqlx_cache/
db_cache_config.rs

1#[derive(Copy, Clone)]
2pub struct DbCacheConfig {
3    cache_id: &'static str,
4    expires_in: u64,
5}
6
7impl DbCacheConfig {
8    pub fn new(cache_id: &'static str, expires_in: u64) -> Self {
9        Self { cache_id, expires_in }
10    }
11    pub fn expires_in(&self) -> u64 {
12        self.expires_in
13    }
14
15    pub fn cache_id(&self) -> &'static str {
16        self.cache_id
17    }
18}
19
20