aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/walletdb.h
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2020-06-17 12:25:22 -0400
committerAndrew Chow <achow101-github@achow101.com>2020-06-17 12:31:29 -0400
commit45c08f8a7b89dda6afb7d7cf9573a8ae8290ac92 (patch)
tree714f6ecf6acd0250c62dca1bd5a0629d00c0df85 /src/wallet/walletdb.h
parent39bd9ddb8783807b9cde6288233e86ad7c85d61f (diff)
Add Create*WalletDatabase functions
These functions doing the same things as WalletDatabase::Create, CreateMock, and CreateDummy
Diffstat (limited to 'src/wallet/walletdb.h')
-rw-r--r--src/wallet/walletdb.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/wallet/walletdb.h b/src/wallet/walletdb.h
index 1037bd579f..61e0f19e56 100644
--- a/src/wallet/walletdb.h
+++ b/src/wallet/walletdb.h
@@ -293,4 +293,13 @@ bool ReadKeyValue(CWallet* pwallet, CDataStream& ssKey, CDataStream& ssValue, st
/** Return whether a wallet database is currently loaded. */
bool IsWalletLoaded(const fs::path& wallet_path);
+/** Return object for accessing database at specified path. */
+std::unique_ptr<BerkeleyDatabase> CreateWalletDatabase(const fs::path& path);
+
+/** Return object for accessing dummy database with no read/write capabilities. */
+std::unique_ptr<BerkeleyDatabase> CreateDummyWalletDatabase();
+
+/** Return object for accessing temporary in-memory database. */
+std::unique_ptr<BerkeleyDatabase> CreateMockWalletDatabase();
+
#endif // BITCOIN_WALLET_WALLETDB_H