pub struct MemoryStorage { /* private fields */ }Expand description
In-memory storage for testing.
Not secure - only use for tests!
Implementations§
Source§impl MemoryStorage
impl MemoryStorage
Trait Implementations§
Source§impl Default for MemoryStorage
Available on crate features std only.
impl Default for MemoryStorage
Available on crate features
std only.Source§impl SecureStorage for MemoryStorage
Available on crate features std only.
impl SecureStorage for MemoryStorage
Available on crate features
std only.Source§fn store(&self, key: &str, value: &[u8]) -> Result<(), PersistenceError>
fn store(&self, key: &str, value: &[u8]) -> Result<(), PersistenceError>
Store bytes under the given key. Read more
Source§fn retrieve(&self, key: &str) -> Result<Option<Vec<u8>>, PersistenceError>
fn retrieve(&self, key: &str) -> Result<Option<Vec<u8>>, PersistenceError>
Retrieve bytes for the given key. Read more
Auto Trait Implementations§
impl !Freeze for MemoryStorage
impl RefUnwindSafe for MemoryStorage
impl Send for MemoryStorage
impl Sync for MemoryStorage
impl Unpin for MemoryStorage
impl UnwindSafe for MemoryStorage
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