diff options
| author | Jeff Garzik <[email protected]> | 2012-05-18 02:49:50 -0400 |
|---|---|---|
| committer | Jeff Garzik <[email protected]> | 2012-05-19 20:46:52 -0400 |
| commit | ffe8b77a617efd802a9d4ba7e42b163fbd9a250b (patch) | |
| tree | 38bef9570c2b71b299cd5d54bfb6f178ce59cf32 /src/db.h | |
| parent | CDB::CDB: properly initialize activeTxn to NULL (diff) | |
| download | discoin-ffe8b77a617efd802a9d4ba7e42b163fbd9a250b.tar.xz discoin-ffe8b77a617efd802a9d4ba7e42b163fbd9a250b.zip | |
Further CDBEnv encapsulation work.
Diffstat (limited to 'src/db.h')
| -rw-r--r-- | src/db.h | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -42,6 +42,8 @@ private: public: mutable CCriticalSection cs_db; DbEnv dbenv; + std::map<std::string, int> mapFileUseCount; + std::map<std::string, Db*> mapDb; CDBEnv(); ~CDBEnv(); @@ -51,6 +53,8 @@ public: void CheckpointLSN(std::string strFile); void SetDetach(bool fDetachDB_) { fDetachDB = fDetachDB_; } + void CloseDb(const std::string& strFile); + DbTxn *TxnBegin(int flags=DB_TXN_WRITE_NOSYNC) { DbTxn* ptxn = NULL; |