![]() |
Bitcoin Core 31.0.0
P2P Digital Currency
|
Access to the wallet database. More...
#include <walletdb.h>
Private Member Functions | |
| template<typename K , typename T > | |
| bool | WriteIC (const K &key, const T &value, bool fOverwrite=true) |
| template<typename K > | |
| bool | EraseIC (const K &key) |
Private Attributes | |
| std::unique_ptr< DatabaseBatch > | m_batch |
| std::vector< DbTxnListener > | m_txn_listeners |
Access to the wallet database.
Opens the database and provides read and write access to it. Each read and write is its own transaction. Multiple operation transactions can be started using TxnBegin() and committed using TxnCommit() Otherwise the transaction will be committed when the object goes out of scope. Optionally (on by default) it will flush to disk on close. Every 1000 writes will automatically trigger a flush to disk.
Definition at line 192 of file walletdb.h.
|
inlineexplicit |
Definition at line 214 of file walletdb.h.
|
delete |
| bool wallet::WalletBatch::EraseAddressData | ( | const CTxDestination & | dest | ) |
Definition at line 1242 of file walletdb.cpp.
| bool wallet::WalletBatch::EraseAddressReceiveRequest | ( | const CTxDestination & | dest, |
| const std::string & | id ) |
Definition at line 1237 of file walletdb.cpp.
Definition at line 287 of file walletdb.cpp.
| bool wallet::WalletBatch::EraseName | ( | const std::string & | strAddress | ) |
Definition at line 81 of file walletdb.cpp.
| bool wallet::WalletBatch::ErasePurpose | ( | const std::string & | strAddress | ) |
Definition at line 93 of file walletdb.cpp.
| bool wallet::WalletBatch::EraseRecords | ( | const std::unordered_set< std::string > & | types | ) |
Delete records of the given types.
Definition at line 1254 of file walletdb.cpp.
Definition at line 103 of file walletdb.cpp.
|
inline |
| bool wallet::WalletBatch::IsEncrypted | ( | ) |
Definition at line 1103 of file walletdb.cpp.
|
delete |
| bool wallet::WalletBatch::ReadBestBlock | ( | CBlockLocator & | locator | ) |
| void wallet::WalletBatch::RegisterTxnListener | ( | const DbTxnListener & | l | ) |
Registers db txn callback functions.
Definition at line 1292 of file walletdb.cpp.
| bool wallet::WalletBatch::TxnAbort | ( | ) |
Abort current transaction.
Definition at line 1279 of file walletdb.cpp.
| bool wallet::WalletBatch::TxnBegin | ( | ) |
Begin a new transaction.
Definition at line 1261 of file walletdb.cpp.
| bool wallet::WalletBatch::TxnCommit | ( | ) |
Commit current transaction.
Definition at line 1266 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteActiveScriptPubKeyMan | ( | uint8_t | type, |
| const uint256 & | id, | ||
| bool | internal ) |
Definition at line 205 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteAddressPreviouslySpent | ( | const CTxDestination & | dest, |
| bool | previously_spent ) |
Definition at line 1226 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteAddressReceiveRequest | ( | const CTxDestination & | dest, |
| const std::string & | id, | ||
| const std::string & | receive_request ) |
Definition at line 1232 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteBestBlock | ( | const CBlockLocator & | locator | ) |
Definition at line 177 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteCryptedDescriptorKey | ( | const uint256 & | desc_id, |
| const CPubKey & | pubkey, | ||
| const std::vector< unsigned char > & | secret ) |
Definition at line 225 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteCryptedKey | ( | const CPubKey & | vchPubKey, |
| const std::vector< unsigned char > & | vchCryptedSecret, | ||
| const CKeyMetadata & | keyMeta ) |
Definition at line 125 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteDescriptor | ( | const uint256 & | desc_id, |
| const WalletDescriptor & | descriptor ) |
Definition at line 234 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteDescriptorCacheItems | ( | const uint256 & | desc_id, |
| const DescriptorCache & | cache ) |
Definition at line 260 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteDescriptorDerivedCache | ( | const CExtPubKey & | xpub, |
| const uint256 & | desc_id, | ||
| uint32_t | key_exp_index, | ||
| uint32_t | der_index ) |
Definition at line 239 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteDescriptorKey | ( | const uint256 & | desc_id, |
| const CPubKey & | pubkey, | ||
| const CPrivKey & | privkey ) |
Definition at line 217 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteDescriptorLastHardenedCache | ( | const CExtPubKey & | xpub, |
| const uint256 & | desc_id, | ||
| uint32_t | key_exp_index ) |
Definition at line 253 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteDescriptorParentCache | ( | const CExtPubKey & | xpub, |
| const uint256 & | desc_id, | ||
| uint32_t | key_exp_index ) |
Definition at line 246 of file walletdb.cpp.
|
inlineprivate |
Definition at line 196 of file walletdb.h.
| bool wallet::WalletBatch::WriteKey | ( | const CPubKey & | vchPubKey, |
| const CPrivKey & | vchPrivKey, | ||
| const CKeyMetadata & | keyMeta ) |
| bool wallet::WalletBatch::WriteKeyMetadata | ( | const CKeyMetadata & | meta, |
| const CPubKey & | pubkey, | ||
| bool | overwrite ) |
Definition at line 108 of file walletdb.cpp.
Definition at line 282 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteMasterKey | ( | unsigned int | nID, |
| const CMasterKey & | kMasterKey ) |
Definition at line 151 of file walletdb.cpp.
| bool wallet::WalletBatch::WriteName | ( | const std::string & | strAddress, |
| const std::string & | strName ) |
Definition at line 76 of file walletdb.cpp.
Definition at line 200 of file walletdb.cpp.
| bool wallet::WalletBatch::WritePurpose | ( | const std::string & | strAddress, |
| const std::string & | purpose ) |
Definition at line 88 of file walletdb.cpp.
Definition at line 98 of file walletdb.cpp.
Write the given client_version.
Definition at line 269 of file walletdb.h.
| bool wallet::WalletBatch::WriteWatchOnly | ( | const CScript & | script, |
| const CKeyMetadata & | keymeta ) |
|
private |
Definition at line 287 of file walletdb.h.
|
private |
Definition at line 291 of file walletdb.h.