1 2 3 4 5 6 7
use kv::{Transaction, KeyState, Key, Value}; pub trait KeyValueDatabase: Send + Sync { fn write(&self, tx: Transaction) -> Result<(), String>; fn get(&self, key: &Key) -> Result<KeyState<Value>, String>; }
1 2 3 4 5 6 7
use kv::{Transaction, KeyState, Key, Value}; pub trait KeyValueDatabase: Send + Sync { fn write(&self, tx: Transaction) -> Result<(), String>; fn get(&self, key: &Key) -> Result<KeyState<Value>, String>; }