walletdb: Introduce WalletDatabase abstract class

Make WalletDatabase actually an abstract class and not just a typedef
for BerkeleyDatabase. Have BerkeleyDatabase inherit this class.
This commit is contained in:
Andrew Chow
2020-06-15 16:24:00 -04:00
parent 2179dbcbcd
commit d416ae560e
6 changed files with 84 additions and 33 deletions

View File

@@ -862,7 +862,7 @@ void BerkeleyDatabase::RemoveRef()
env->m_db_in_use.notify_all();
}
std::unique_ptr<BerkeleyBatch> BerkeleyDatabase::MakeBatch(const char* mode, bool flush_on_close)
std::unique_ptr<DatabaseBatch> BerkeleyDatabase::MakeBatch(const char* mode, bool flush_on_close)
{
return MakeUnique<BerkeleyBatch>(*this, mode, flush_on_close);
}