Changeset View
Changeset View
Standalone View
Standalone View
src/wallet/db.h
Show First 20 Lines • Show All 66 Lines • ▼ Show 20 Lines | public: | ||||
* Salvage data from a file that Verify says is bad. | * Salvage data from a file that Verify says is bad. | ||||
* fAggressive sets the DB_AGGRESSIVE flag (see berkeley DB->verify() method | * fAggressive sets the DB_AGGRESSIVE flag (see berkeley DB->verify() method | ||||
* documentation). | * documentation). | ||||
* Appends binary key/value pairs to vResult, returns true if successful. | * Appends binary key/value pairs to vResult, returns true if successful. | ||||
* NOTE: reads the entire database into memory, so cannot be used | * NOTE: reads the entire database into memory, so cannot be used | ||||
* for huge databases. | * for huge databases. | ||||
*/ | */ | ||||
typedef std::pair<std::vector<uint8_t>, std::vector<uint8_t>> KeyValPair; | typedef std::pair<std::vector<uint8_t>, std::vector<uint8_t>> KeyValPair; | ||||
bool Salvage(const std::string &strFile, bool fAggressive, | bool Salvage(const std::string &strFile, std::vector<KeyValPair> &vResult); | ||||
std::vector<KeyValPair> &vResult); | |||||
bool Open(bool retry); | bool Open(bool retry); | ||||
void Close(); | void Close(); | ||||
void Flush(bool fShutdown); | void Flush(bool fShutdown); | ||||
void CheckpointLSN(const std::string &strFile); | void CheckpointLSN(const std::string &strFile); | ||||
void CloseDb(const std::string &strFile); | void CloseDb(const std::string &strFile); | ||||
void ReloadDbEnv(); | void ReloadDbEnv(); | ||||
▲ Show 20 Lines • Show All 346 Lines • Show Last 20 Lines |