Bitcoin Core  24.99.0
P2P Digital Currency
Public Member Functions | Private Member Functions | Private Attributes | List of all members
wallet::FailBatch Class Reference

RAII class that provides access to a FailDatabase. More...

Inheritance diagram for wallet::FailBatch:
[legend]
Collaboration diagram for wallet::FailBatch:
[legend]

Public Member Functions

 FailBatch (bool pass)
 
void Flush () override
 
void Close () override
 
bool StartCursor () override
 
bool ReadAtCursor (CDataStream &ssKey, CDataStream &ssValue, bool &complete) override
 
void CloseCursor () override
 
bool TxnBegin () override
 
bool TxnCommit () override
 
bool TxnAbort () override
 
- Public Member Functions inherited from wallet::DatabaseBatch
 DatabaseBatch ()
 
virtual ~DatabaseBatch ()
 
 DatabaseBatch (const DatabaseBatch &)=delete
 
DatabaseBatchoperator= (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)
 

Private Member Functions

bool ReadKey (CDataStream &&key, CDataStream &value) override
 
bool WriteKey (CDataStream &&key, CDataStream &&value, bool overwrite=true) override
 
bool EraseKey (CDataStream &&key) override
 
bool HasKey (CDataStream &&key) override
 

Private Attributes

bool m_pass {true}
 

Detailed Description

RAII class that provides access to a FailDatabase.

Which fails if needed.

Definition at line 871 of file wallet_tests.cpp.

Constructor & Destructor Documentation

◆ FailBatch()

wallet::FailBatch::FailBatch ( bool  pass)
inlineexplicit

Definition at line 881 of file wallet_tests.cpp.

Member Function Documentation

◆ Close()

void wallet::FailBatch::Close ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 883 of file wallet_tests.cpp.

◆ CloseCursor()

void wallet::FailBatch::CloseCursor ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 887 of file wallet_tests.cpp.

◆ EraseKey()

bool wallet::FailBatch::EraseKey ( CDataStream &&  key)
inlineoverrideprivatevirtual

Implements wallet::DatabaseBatch.

Definition at line 877 of file wallet_tests.cpp.

◆ Flush()

void wallet::FailBatch::Flush ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 882 of file wallet_tests.cpp.

◆ HasKey()

bool wallet::FailBatch::HasKey ( CDataStream &&  key)
inlineoverrideprivatevirtual

Implements wallet::DatabaseBatch.

Definition at line 878 of file wallet_tests.cpp.

◆ ReadAtCursor()

bool wallet::FailBatch::ReadAtCursor ( CDataStream ssKey,
CDataStream ssValue,
bool &  complete 
)
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 886 of file wallet_tests.cpp.

◆ ReadKey()

bool wallet::FailBatch::ReadKey ( CDataStream &&  key,
CDataStream value 
)
inlineoverrideprivatevirtual

Implements wallet::DatabaseBatch.

Definition at line 875 of file wallet_tests.cpp.

◆ StartCursor()

bool wallet::FailBatch::StartCursor ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 885 of file wallet_tests.cpp.

◆ TxnAbort()

bool wallet::FailBatch::TxnAbort ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 890 of file wallet_tests.cpp.

◆ TxnBegin()

bool wallet::FailBatch::TxnBegin ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 888 of file wallet_tests.cpp.

◆ TxnCommit()

bool wallet::FailBatch::TxnCommit ( )
inlineoverridevirtual

Implements wallet::DatabaseBatch.

Definition at line 889 of file wallet_tests.cpp.

◆ WriteKey()

bool wallet::FailBatch::WriteKey ( CDataStream &&  key,
CDataStream &&  value,
bool  overwrite = true 
)
inlineoverrideprivatevirtual

Implements wallet::DatabaseBatch.

Definition at line 876 of file wallet_tests.cpp.

Member Data Documentation

◆ m_pass

bool wallet::FailBatch::m_pass {true}
private

Definition at line 874 of file wallet_tests.cpp.


The documentation for this class was generated from the following file: