![]() |
Bitcoin Core 22.99.0
P2P Digital Currency
|
#include <script/sign.h>#include <wallet/db.h>#include <wallet/walletutil.h>#include <key.h>#include <stdint.h>#include <string>#include <vector>Go to the source code of this file.
Classes | |
| class | CHDChain |
| class | CKeyMetadata |
| class | WalletBatch |
| Access to the wallet database. More... | |
Namespaces | |
| namespace | DBKeys |
Typedefs | |
| using | KeyFilterFn = std::function< bool(const std::string &)> |
| Callback for filtering key types to deserialize in ReadKeyValue. More... | |
Enumerations | |
| enum class | DBErrors { LOAD_OK , CORRUPT , NONCRITICAL_ERROR , TOO_NEW , LOAD_FAIL , NEED_REWRITE , NEED_RESCAN } |
| Error statuses for the wallet database. More... | |
Functions | |
| void | MaybeCompactWalletDB (WalletContext &context) |
| Compacts BDB state so that wallet.dat is self-contained (if there are changes) More... | |
| bool | ReadKeyValue (CWallet *pwallet, CDataStream &ssKey, CDataStream &ssValue, std::string &strType, std::string &strErr, const KeyFilterFn &filter_fn=nullptr) |
| Unserialize a given Key-Value pair and load it into the wallet. More... | |
| std::unique_ptr< WalletDatabase > | CreateDummyWalletDatabase () |
| Return object for accessing dummy database with no read/write capabilities. More... | |
| std::unique_ptr< WalletDatabase > | CreateMockWalletDatabase () |
| Return object for accessing temporary in-memory database. More... | |
Variables | |
| static const bool | DEFAULT_FLUSHWALLET = true |
| Overview of wallet database classes: More... | |
| using KeyFilterFn = std::function<bool(const std::string&)> |
Callback for filtering key types to deserialize in ReadKeyValue.
Definition at line 290 of file walletdb.h.
|
strong |
Error statuses for the wallet database.
| Enumerator | |
|---|---|
| LOAD_OK | |
| CORRUPT | |
| NONCRITICAL_ERROR | |
| TOO_NEW | |
| LOAD_FAIL | |
| NEED_REWRITE | |
| NEED_RESCAN | |
Definition at line 43 of file walletdb.h.
| std::unique_ptr< WalletDatabase > CreateDummyWalletDatabase | ( | ) |
Return object for accessing dummy database with no read/write capabilities.
Definition at line 1183 of file walletdb.cpp.
| std::unique_ptr< WalletDatabase > CreateMockWalletDatabase | ( | ) |
Return object for accessing temporary in-memory database.
Definition at line 1189 of file walletdb.cpp.
| void MaybeCompactWalletDB | ( | WalletContext & | context | ) |
Compacts BDB state so that wallet.dat is self-contained (if there are changes)
Definition at line 1040 of file walletdb.cpp.
| bool ReadKeyValue | ( | CWallet * | pwallet, |
| CDataStream & | ssKey, | ||
| CDataStream & | ssValue, | ||
| std::string & | strType, | ||
| std::string & | strErr, | ||
| const KeyFilterFn & | filter_fn = nullptr |
||
| ) |
Unserialize a given Key-Value pair and load it into the wallet.
Definition at line 748 of file walletdb.cpp.
|
static |
Overview of wallet database classes:
The following classes are implementation specific:
Definition at line 30 of file walletdb.h.