pub struct KeyValueStore { /* private fields */ }Implementations§
Source§impl KeyValueStore
impl KeyValueStore
pub fn new(store_type: KvStoreType) -> Self
Trait Implementations§
Source§impl KeyValueStorage for KeyValueStore
impl KeyValueStorage for KeyValueStore
fn read_storage(&self) -> Result<HashMap<ConfigKeys, String>, KSMRError>
fn save_storage( &mut self, updated_config: HashMap<ConfigKeys, String>, ) -> Result<bool, KSMRError>
fn get(&self, key: ConfigKeys) -> Result<Option<String>, KSMRError>
fn set( &mut self, key: ConfigKeys, value: String, ) -> Result<HashMap<ConfigKeys, String>, KSMRError>
fn delete( &mut self, key: ConfigKeys, ) -> Result<HashMap<ConfigKeys, String>, KSMRError>
fn delete_all(&mut self) -> Result<HashMap<ConfigKeys, String>, KSMRError>
fn contains(&self, key: ConfigKeys) -> Result<bool, KSMRError>
fn create_config_file_if_missing(&self) -> Result<(), KSMRError>
fn is_empty(&self) -> Result<bool, KSMRError>
Auto Trait Implementations§
impl Freeze for KeyValueStore
impl RefUnwindSafe for KeyValueStore
impl Send for KeyValueStore
impl Sync for KeyValueStore
impl Unpin for KeyValueStore
impl UnwindSafe for KeyValueStore
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more