Bitcoin Core 28.99.0
P2P Digital Currency
Public Member Functions | Private Types | Private Attributes | List of all members
wallet::WalletRescanReserver Class Reference

RAII object to check and reserve a wallet rescan. More...

#include <wallet.h>

Collaboration diagram for wallet::WalletRescanReserver:
[legend]

Public Member Functions

 WalletRescanReserver (CWallet &w)
 
bool reserve (bool with_passphrase=false)
 
bool isReserved () const
 
Clock::time_point now () const
 
void setNow (NowFn now)
 
 ~WalletRescanReserver ()
 

Private Types

using Clock = std::chrono::steady_clock
 
using NowFn = std::function< Clock::time_point()>
 

Private Attributes

CWalletm_wallet
 
bool m_could_reserve {false}
 
NowFn m_now
 

Detailed Description

RAII object to check and reserve a wallet rescan.

Definition at line 1079 of file wallet.h.

Member Typedef Documentation

◆ Clock

using wallet::WalletRescanReserver::Clock = std::chrono::steady_clock
private

Definition at line 1082 of file wallet.h.

◆ NowFn

using wallet::WalletRescanReserver::NowFn = std::function<Clock::time_point()>
private

Definition at line 1083 of file wallet.h.

Constructor & Destructor Documentation

◆ WalletRescanReserver()

wallet::WalletRescanReserver::WalletRescanReserver ( CWallet w)
inlineexplicit

Definition at line 1088 of file wallet.h.

◆ ~WalletRescanReserver()

wallet::WalletRescanReserver::~WalletRescanReserver ( )
inline

Definition at line 1112 of file wallet.h.

Member Function Documentation

◆ isReserved()

bool wallet::WalletRescanReserver::isReserved ( ) const
inline

Definition at line 1103 of file wallet.h.

Here is the caller graph for this function:

◆ now()

Clock::time_point wallet::WalletRescanReserver::now ( ) const
inline

Definition at line 1108 of file wallet.h.

Here is the caller graph for this function:

◆ reserve()

bool wallet::WalletRescanReserver::reserve ( bool  with_passphrase = false)
inline

Definition at line 1090 of file wallet.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setNow()

void wallet::WalletRescanReserver::setNow ( NowFn  now)
inline

Definition at line 1110 of file wallet.h.

Here is the caller graph for this function:

Member Data Documentation

◆ m_could_reserve

bool wallet::WalletRescanReserver::m_could_reserve {false}
private

Definition at line 1085 of file wallet.h.

◆ m_now

NowFn wallet::WalletRescanReserver::m_now
private

Definition at line 1086 of file wallet.h.

◆ m_wallet

CWallet& wallet::WalletRescanReserver::m_wallet
private

Definition at line 1084 of file wallet.h.


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