use crate::database::hashmap_store::HashMapStore;
use std::sync::Arc;
#[derive(Clone, Debug)]
pub struct DbContext {
store: Arc<HashMapStore>,
}
impl DbContext {
pub fn new() -> Result<Self, crate::error::RepositoryError> {
Ok(DbContext {
store: Arc::new(HashMapStore::default()),
})
}
pub fn get_store(&self) -> &Arc<HashMapStore> {
&self.store
}
}