![]() |
Bitcoin Core
26.1.0
P2P Digital Currency
|
RAII class that provides access to a Berkeley database. More...
#include <bdb.h>
Public Member Functions | |
| BerkeleyBatch (BerkeleyDatabase &database, const bool fReadOnly, bool fFlushOnCloseIn=true) | |
| ~BerkeleyBatch () override | |
| BerkeleyBatch (const BerkeleyBatch &)=delete | |
| BerkeleyBatch & | operator= (const BerkeleyBatch &)=delete |
| void | Flush () override |
| void | Close () override |
| std::unique_ptr< DatabaseCursor > | GetNewCursor () override |
| std::unique_ptr< DatabaseCursor > | GetNewPrefixCursor (Span< const std::byte > prefix) override |
| bool | TxnBegin () override |
| bool | TxnCommit () override |
| bool | TxnAbort () override |
| DbTxn * | txn () const |
Public Member Functions inherited from wallet::DatabaseBatch | |
| DatabaseBatch () | |
| virtual | ~DatabaseBatch () |
| DatabaseBatch (const DatabaseBatch &)=delete | |
| DatabaseBatch & | operator= (const DatabaseBatch &)=delete |
| template<typename K , typename T > | |
| bool | Read (const K &key, T &value) |
| template<typename K , typename T > | |
| bool | Write (const K &key, const T &value, bool fOverwrite=true) |
| template<typename K > | |
| bool | Erase (const K &key) |
| template<typename K > | |
| bool | Exists (const K &key) |
Protected Attributes | |
| Db * | pdb {nullptr} |
| std::string | strFile |
| DbTxn * | activeTxn {nullptr} |
| bool | fReadOnly |
| bool | fFlushOnClose |
| BerkeleyEnvironment * | env |
| BerkeleyDatabase & | m_database |
Private Member Functions | |
| bool | ReadKey (DataStream &&key, DataStream &value) override |
| bool | WriteKey (DataStream &&key, DataStream &&value, bool overwrite=true) override |
| bool | EraseKey (DataStream &&key) override |
| bool | HasKey (DataStream &&key) override |
| bool | ErasePrefix (Span< const std::byte > prefix) override |
|
explicit |
|
override |
|
delete |
|
overridevirtual |
Implements wallet::DatabaseBatch.
Definition at line 440 of file bdb.cpp.
|
overrideprivatevirtual |
Implements wallet::DatabaseBatch.
Definition at line 864 of file bdb.cpp.
|
overrideprivatevirtual |
Implements wallet::DatabaseBatch.
Definition at line 888 of file bdb.cpp.
|
overridevirtual |
Implements wallet::DatabaseBatch.
Definition at line 414 of file bdb.cpp.
|
overridevirtual |
Implements wallet::DatabaseBatch.
Definition at line 769 of file bdb.cpp.
|
overridevirtual |
Implements wallet::DatabaseBatch.
|
overrideprivatevirtual |
Implements wallet::DatabaseBatch.
|
delete |
|
overrideprivatevirtual |
Implements wallet::DatabaseBatch.
Definition at line 832 of file bdb.cpp.
|
inline |
|
overridevirtual |
Implements wallet::DatabaseBatch.
|
overridevirtual |
Implements wallet::DatabaseBatch.
Definition at line 781 of file bdb.cpp.
|
overridevirtual |
Implements wallet::DatabaseBatch.
Definition at line 792 of file bdb.cpp.
|
overrideprivatevirtual |
Implements wallet::DatabaseBatch.
Definition at line 849 of file bdb.cpp.
|
protected |
|
protected |
1.8.14