continuwuity/src/service/rooms/auth_chain/data.rs
Jason Volk c42209c0b3 use Arc<[u64]> rather than Arc<HashSet<u64>> for auth_chain_cache value.
Signed-off-by: Jason Volk <jason@zemos.net>
2024-04-09 15:26:45 -04:00

8 lines
257 B
Rust

use std::sync::Arc;
use crate::Result;
pub trait Data: Send + Sync {
fn get_cached_eventid_authchain(&self, shorteventid: &[u64]) -> Result<Option<Arc<[u64]>>>;
fn cache_auth_chain(&self, shorteventid: Vec<u64>, auth_chain: Arc<[u64]>) -> Result<()>;
}