gdritter repos tansu-berkeleydb / 0a9fba4
Added a haddock Getty Ritter 8 years ago
1 changed file(s) with 4 addition(s) and 1 deletion(s). Collapse all Expand all
1 module Database.Tansu.Backend.BerkeleyDb where
1 module Database.Tansu.Backend.BerkeleyDb
2 (withBerkeleyDb) where
23
34 import Database.Berkeley.Db
45 import Data.ByteString (ByteString)
1415 bdbGet db key =
1516 db_get [] db Nothing key
1617
18 -- | Open or create a database at the supplied path
19 -- using the BerkeleyDB library.
1720 withBerkeleyDb :: FilePath -> (TansuDb -> IO a) -> IO a
1821 withBerkeleyDb path comp = do
1922 createDirectoryIfMissing True path