diff options
Diffstat (limited to 'src/db/lib.rs')
-rw-r--r-- | src/db/lib.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/db/lib.rs b/src/db/lib.rs index 9fae7cc9..e9d3ea18 100644 --- a/src/db/lib.rs +++ b/src/db/lib.rs @@ -63,6 +63,10 @@ pub fn unabort<R, E>(res: TxResult<R, E>) -> TxOpResult<std::result::Result<R, E // ---- impl Db { + pub fn engine(&self) -> String { + self.0.engine() + } + pub fn open_tree<S: AsRef<str>>(&self, name: S) -> Result<Tree> { let tree_id = self.0.open_tree(name.as_ref())?; Ok(Tree(self.0.clone(), tree_id)) @@ -298,6 +302,7 @@ impl<'a> Transaction<'a> { // ---- Internal interfaces pub(crate) trait IDb: Send + Sync { + fn engine(&self) -> String; fn open_tree(&self, name: &str) -> Result<usize>; fn list_trees(&self) -> Result<Vec<String>>; |