![]() |
Bitcoin Core
28.1.0
P2P Digital Currency
|
A class representing a BerkeleyDB file from which we can only read records. More...
#include <migrate.h>
Public Member Functions | |
| BerkeleyRODatabase (const fs::path &filepath, bool open=true) | |
| Create DB handle. More... | |
| ~BerkeleyRODatabase ()=default | |
| void | Open () override |
| Open the database if it is not already opened. More... | |
| void | AddRef () override |
| Indicate the a new database user has began using the database. More... | |
| void | RemoveRef () override |
| Indicate that database user has stopped using the database and that it could be flushed or closed. More... | |
| bool | Rewrite (const char *pszSkip=nullptr) override |
| Rewrite the entire database on disk, with the exception of key pszSkip if non-zero. More... | |
| bool | Backup (const std::string &strDest) const override |
| Back up the entire database to a file. More... | |
| void | Flush () override |
| Make sure all changes are flushed to database file. More... | |
| void | Close () override |
| Flush to the database file and close the database. More... | |
| bool | PeriodicFlush () override |
| void | IncrementUpdateCounter () override |
| void | ReloadDbEnv () override |
| std::string | Filename () override |
| Return path to main database file for logs and error messages. More... | |
| std::string | Format () override |
| std::unique_ptr< DatabaseBatch > | MakeBatch (bool flush_on_close=true) override |
| Make a DatabaseBatch connected to this database. More... | |
Public Member Functions inherited from wallet::WalletDatabase | |
| WalletDatabase () | |
| Create dummy DB handle. More... | |
| virtual | ~WalletDatabase ()=default |
Public Attributes | |
| BerkeleyROData | m_records |
Public Attributes inherited from wallet::WalletDatabase | |
| std::atomic< int > | m_refcount {0} |
| Counts the number of active database users to be sure that the database is not closed while someone is using it. More... | |
| std::atomic< unsigned int > | nUpdateCounter |
| unsigned int | nLastSeen {0} |
| unsigned int | nLastFlushed {0} |
| int64_t | nLastWalletUpdate {0} |
Private Attributes | |
| const fs::path | m_filepath |
A class representing a BerkeleyDB file from which we can only read records.
This is used only for migration of legacy to descriptor wallets
|
inline |
|
default |
|
inlineoverridevirtual |
Indicate the a new database user has began using the database.
Increments m_refcount
Implements wallet::WalletDatabase.
|
overridevirtual |
Back up the entire database to a file.
Implements wallet::WalletDatabase.
Definition at line 707 of file migrate.cpp.
|
inlineoverridevirtual |
Flush to the database file and close the database.
Also close the environment if no other databases are open in it.
Implements wallet::WalletDatabase.
|
inlineoverridevirtual |
Return path to main database file for logs and error messages.
Implements wallet::WalletDatabase.
Definition at line 67 of file migrate.h.
|
inlineoverridevirtual |
Make sure all changes are flushed to database file.
Implements wallet::WalletDatabase.
|
inlineoverridevirtual |
Implements wallet::WalletDatabase.
|
inlineoverridevirtual |
Implements wallet::WalletDatabase.
|
overridevirtual |
Make a DatabaseBatch connected to this database.
Implements wallet::WalletDatabase.
Definition at line 702 of file migrate.cpp.
|
overridevirtual |
Open the database if it is not already opened.
Implements wallet::WalletDatabase.
Definition at line 524 of file migrate.cpp.
|
inlineoverridevirtual |
Implements wallet::WalletDatabase.
|
inlineoverridevirtual |
Implements wallet::WalletDatabase.
|
inlineoverridevirtual |
Indicate that database user has stopped using the database and that it could be flushed or closed.
Decrement m_refcount
Implements wallet::WalletDatabase.
|
inlineoverridevirtual |
Rewrite the entire database on disk, with the exception of key pszSkip if non-zero.
Implements wallet::WalletDatabase.
|
private |
| BerkeleyROData wallet::BerkeleyRODatabase::m_records |
1.8.14