#include <db.h>
◆ KeyValPair
Salvage data from a file that Verify says is bad. fAggressive sets the DB_AGGRESSIVE flag (see berkeley DB->verify() method documentation). Appends binary key/value pairs to vResult, returns true if successful. NOTE: reads the entire database into memory, so cannot be used for huge databases.
◆ recoverFunc_type
typedef bool(* BerkeleyEnvironment::recoverFunc_type) (const fs::path &file_path, std::string &out_backup_filename) |
◆ VerifyResult
Verify that database file strFile is OK. If it is not, call the callback to try to recover. This must be called BEFORE strFile is opened. Returns true if strFile is OK.
Enumerator |
---|
VERIFY_OK | |
RECOVER_OK | |
RECOVER_FAIL | |
◆ BerkeleyEnvironment() [1/2]
BerkeleyEnvironment::BerkeleyEnvironment |
( |
const fs::path & |
env_directory | ) |
|
◆ BerkeleyEnvironment() [2/2]
BerkeleyEnvironment::BerkeleyEnvironment |
( |
| ) |
|
Construct an in-memory mock Berkeley environment for testing and as a place-holder for g_dbenvs emplace.
◆ ~BerkeleyEnvironment()
BerkeleyEnvironment::~BerkeleyEnvironment |
( |
| ) |
|
◆ CheckpointLSN()
void BerkeleyEnvironment::CheckpointLSN |
( |
const std::string & |
strFile | ) |
|
◆ Close()
void BerkeleyEnvironment::Close |
( |
| ) |
|
◆ CloseDb()
void BerkeleyEnvironment::CloseDb |
( |
const std::string & |
strFile | ) |
|
◆ Directory()
fs::path BerkeleyEnvironment::Directory |
( |
| ) |
const |
|
inline |
◆ Flush()
void BerkeleyEnvironment::Flush |
( |
bool |
fShutdown | ) |
|
◆ IsDatabaseLoaded()
bool BerkeleyEnvironment::IsDatabaseLoaded |
( |
const std::string & |
db_filename | ) |
const |
|
inline |
◆ IsInitialized()
bool BerkeleyEnvironment::IsInitialized |
( |
| ) |
const |
|
inline |
◆ IsMock()
bool BerkeleyEnvironment::IsMock |
( |
| ) |
const |
|
inline |
◆ Open()
bool BerkeleyEnvironment::Open |
( |
bool |
retry | ) |
|
◆ ReloadDbEnv()
void BerkeleyEnvironment::ReloadDbEnv |
( |
| ) |
|
◆ Reset()
void BerkeleyEnvironment::Reset |
( |
| ) |
|
◆ Salvage()
bool BerkeleyEnvironment::Salvage |
( |
const std::string & |
strFile, |
|
|
bool |
fAggressive, |
|
|
std::vector< KeyValPair > & |
vResult |
|
) |
| |
◆ TxnBegin()
DbTxn* BerkeleyEnvironment::TxnBegin |
( |
int |
flags = DB_TXN_WRITE_NOSYNC | ) |
|
|
inline |
◆ Verify()
◆ dbenv
std::unique_ptr<DbEnv> BerkeleyEnvironment::dbenv |
◆ fDbEnvInit
bool BerkeleyEnvironment::fDbEnvInit |
|
private |
◆ fMockDb
bool BerkeleyEnvironment::fMockDb |
|
private |
◆ m_databases
std::map<std::string, std::reference_wrapper<BerkeleyDatabase> > BerkeleyEnvironment::m_databases |
◆ m_db_in_use
std::condition_variable_any BerkeleyEnvironment::m_db_in_use |
◆ m_fileids
◆ mapFileUseCount
std::map<std::string, int> BerkeleyEnvironment::mapFileUseCount |
◆ strPath
std::string BerkeleyEnvironment::strPath |
|
private |
The documentation for this class was generated from the following files: