Bitcoin Core  0.18.99
P2P Digital Currency
Functions
MapWallet

Functions

std::vector< CKeyIDGetAffectedKeys (const CScript &spk, const SigningProvider &provider)
 
int64_t CalculateMaximumSignedTxSize (const CTransaction &tx, const CWallet *wallet, bool use_max_sig)
 
int64_t CalculateMaximumSignedTxSize (const CTransaction &tx, const CWallet *wallet, const std::vector< CTxOut > &txouts, bool use_max_sig)
 
int CalculateMaximumSignedInputSize (const CTxOut &txout, const CWallet *wallet, bool use_max_sig)
 
std::string COutput::ToString () const
 
const CWalletTxCWallet::GetWalletTx (const uint256 &hash) const
 
CPubKey CWallet::GenerateNewKey (WalletBatch &batch, bool internal=false) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 keystore implementation Generate a new key More...
 
void CWallet::DeriveNewChildKey (WalletBatch &batch, CKeyMetadata &metadata, CKey &secret, bool internal=false) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::AddKeyPubKeyWithDB (WalletBatch &batch, const CKey &key, const CPubKey &pubkey) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::AddKeyPubKey (const CKey &key, const CPubKey &pubkey) override EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Adds a key to the store, and saves it to disk. More...
 
bool CWallet::AddCryptedKey (const CPubKey &vchPubKey, const std::vector< unsigned char > &vchCryptedSecret) override
 Adds an encrypted key to the store, and saves it to disk. More...
 
void CWallet::LoadKeyMetadata (const CKeyID &keyID, const CKeyMetadata &metadata) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Load metadata (used by LoadWallet) More...
 
void CWallet::LoadScriptMetadata (const CScriptID &script_id, const CKeyMetadata &metadata) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::WriteKeyMetadata (const CKeyMetadata &meta, const CPubKey &pubkey, bool overwrite)
 
void CWallet::UpgradeKeyMetadata () EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Upgrade stored CKeyMetadata objects to store key origin info as KeyOriginInfo. More...
 
bool CWallet::LoadCryptedKey (const CPubKey &vchPubKey, const std::vector< unsigned char > &vchCryptedSecret)
 Adds an encrypted key to the store, without saving it to disk (used by LoadWallet) More...
 
void CWallet::UpdateTimeFirstKey (int64_t nCreateTime) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Update wallet first key creation time. More...
 
bool CWallet::AddCScript (const CScript &redeemScript) override
 Support for BIP 0013 : see https://github.com/bitcoin/bips/blob/master/bip-0013.mediawiki. More...
 
bool CWallet::LoadCScript (const CScript &redeemScript)
 
bool CWallet::AddWatchOnly (const CScript &dest) override EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Private version of AddWatchOnly method which does not accept a timestamp, and which will reset the wallet's nTimeFirstKey value to 1 if the watch key did not previously have a timestamp associated with it. More...
 
bool CWallet::AddWatchOnly (const CScript &dest, int64_t nCreateTime) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Adds a watch-only address to the store, and saves it to disk. More...
 
bool CWallet::RemoveWatchOnly (const CScript &dest) override EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::LoadWatchOnly (const CScript &dest)
 Adds a watch-only address to the store, without saving it to disk (used by LoadWallet) More...
 
bool CWallet::Unlock (const SecureString &strWalletPassphrase, bool accept_no_keys=false)
 
bool CWallet::ChangeWalletPassphrase (const SecureString &strOldWalletPassphrase, const SecureString &strNewWalletPassphrase)
 
void CWallet::ChainStateFlushed (const CBlockLocator &loc) override
 
void CWallet::SetMinVersion (enum WalletFeature, WalletBatch *batch_in=nullptr, bool fExplicit=false)
 signify that a particular wallet feature is now used. this may change nWalletVersion and nWalletMaxVersion if those are lower More...
 
bool CWallet::SetMaxVersion (int nVersion)
 change which version we're allowed to upgrade to (note that this does not immediately imply upgrading to that format) More...
 
std::set< uint256CWallet::GetConflicts (const uint256 &txid) const EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Get wallet transactions that conflict with given transaction (spend same outputs) More...
 
bool CWallet::HasWalletSpend (const uint256 &txid) const EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Check if a given transaction has any of its outputs spent by another transaction in the wallet. More...
 
void CWallet::Flush (bool shutdown=false)
 Flush wallet (bitdb flush) More...
 
void CWallet::SyncMetaData (std::pair< TxSpends::iterator, TxSpends::iterator >) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::IsSpent (interfaces::Chain::Lock &locked_chain, const uint256 &hash, unsigned int n) const EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Outpoint is spent if any non-conflicted transaction spends it: More...
 
void CWallet::AddToSpends (const COutPoint &outpoint, const uint256 &wtxid) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
void CWallet::AddToSpends (const uint256 &wtxid) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::EncryptWallet (const SecureString &strWalletPassphrase)
 
DBErrors CWallet::ReorderTransactions ()
 
int64_t CWallet::IncOrderPosNext (WalletBatch *batch=nullptr) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Increment the next transaction order id. More...
 
void CWallet::MarkDirty ()
 
bool CWallet::MarkReplaced (const uint256 &originalHash, const uint256 &newHash)
 Mark a transaction as replaced by another transaction (e.g., BIP 125). More...
 
bool CWallet::AddToWallet (const CWalletTx &wtxIn, bool fFlushOnClose=true)
 
void CWallet::LoadToWallet (const CWalletTx &wtxIn) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::AddToWalletIfInvolvingMe (const CTransactionRef &tx, const uint256 &block_hash, int posInBlock, bool fUpdate) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 Add a transaction to the wallet, or update it. More...
 
bool CWallet::TransactionCanBeAbandoned (const uint256 &hashTx) const
 Return whether transaction can be abandoned. More...
 
void CWallet::MarkInputsDirty (const CTransactionRef &tx) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWallet::AbandonTransaction (interfaces::Chain::Lock &locked_chain, const uint256 &hashTx)
 
void CWallet::MarkConflicted (const uint256 &hashBlock, const uint256 &hashTx)
 
void CWallet::SyncTransaction (const CTransactionRef &tx, const uint256 &block_hash, int posInBlock=0, bool update_tx=true) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
void CWallet::TransactionAddedToMempool (const CTransactionRef &tx) override
 
void CWallet::TransactionRemovedFromMempool (const CTransactionRef &ptx) override
 
void CWallet::BlockConnected (const CBlock &block, const std::vector< CTransactionRef > &vtxConflicted) override
 
void CWallet::BlockDisconnected (const CBlock &block) override
 
void CWallet::UpdatedBlockTip () override
 
void CWallet::BlockUntilSyncedToCurrentChain () LOCKS_EXCLUDED(cs_main
 Blocks until the wallet state is up-to-date to /at least/ the current chain at the time this function is entered Obviously holding cs_main/cs_wallet when going into this call may cause deadlock. More...
 
isminetype CWallet::IsMine (const CTxIn &txin) const
 
CAmount CWallet::GetDebit (const CTxIn &txin, const isminefilter &filter) const
 Returns amount of debit if the input matches the filter, otherwise returns 0. More...
 
isminetype CWallet::IsMine (const CTxOut &txout) const
 
CAmount CWallet::GetCredit (const CTxOut &txout, const isminefilter &filter) const
 
bool CWallet::IsChange (const CTxOut &txout) const
 
bool CWallet::IsChange (const CScript &script) const
 
CAmount CWallet::GetChange (const CTxOut &txout) const
 
bool CWallet::IsMine (const CTransaction &tx) const
 
bool CWallet::IsFromMe (const CTransaction &tx) const
 should probably be renamed to IsRelevantToMe More...
 
CAmount CWallet::GetDebit (const CTransaction &tx, const isminefilter &filter) const
 
bool CWallet::IsAllFromMe (const CTransaction &tx, const isminefilter &filter) const
 Returns whether all of the inputs match the filter. More...
 
CAmount CWallet::GetCredit (const CTransaction &tx, const isminefilter &filter) const
 
CAmount CWallet::GetChange (const CTransaction &tx) const
 
CPubKey CWallet::GenerateNewSeed ()
 
CPubKey CWallet::DeriveNewSeed (const CKey &key)
 
void CWallet::SetHDSeed (const CPubKey &key)
 
void CWallet::SetHDChain (const CHDChain &chain, bool memonly)
 
bool CWallet::IsHDEnabled () const
 
bool CWallet::CanGenerateKeys ()
 
bool CWallet::CanGetAddresses (bool internal=false)
 
void CWallet::SetWalletFlag (uint64_t flags)
 set a single wallet flag More...
 
void CWallet::UnsetWalletFlag (uint64_t flag)
 Unsets a single wallet flag. More...
 
bool CWallet::IsWalletFlagSet (uint64_t flag)
 check if a certain wallet flag is set More...
 
bool CWallet::SetWalletFlags (uint64_t overwriteFlags, bool memOnly)
 overwrite all flags by the given uint64_t returns false if unknown, non-tolerable flags are present More...
 
int64_t CWalletTx::GetTxTime () const
 
bool CWallet::DummySignInput (CTxIn &tx_in, const CTxOut &txout, bool use_max_sig=false) const
 
bool CWallet::DummySignTx (CMutableTransaction &txNew, const std::vector< CTxOut > &txouts, bool use_max_sig=false) const
 
void CWalletTx::GetAmounts (std::list< COutputEntry > &listReceived, std::list< COutputEntry > &listSent, CAmount &nFee, const isminefilter &filter) const
 
int64_t CWallet::RescanFromTime (int64_t startTime, const WalletRescanReserver &reserver, bool update)
 Scan active chain for relevant transactions after importing keys. More...
 
ScanResult CWallet::ScanForWalletTransactions (const uint256 &first_block, const uint256 &last_block, const WalletRescanReserver &reserver, bool fUpdate)
 Scan the block chain (starting in start_block) for transactions from or to us. More...
 
void CWallet::ReacceptWalletTransactions (interfaces::Chain::Lock &locked_chain) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet)
 
bool CWalletTx::RelayWalletTransaction (interfaces::Chain::Lock &locked_chain)
 
std::set< uint256CWalletTx::GetConflicts () const NO_THREAD_SAFETY_ANALYSIS
 
CAmount CWalletTx::GetCachableAmount (AmountType type, const isminefilter &filter, bool recalculate=false) const
 
CAmount CWalletTx::GetDebit (const isminefilter &filter) const
 filter decides which addresses will count towards the debit More...
 
CAmount CWalletTx::GetCredit (interfaces::Chain::Lock &locked_chain, const isminefilter &filter) const
 
CAmount CWalletTx::GetImmatureCredit (interfaces::Chain::Lock &locked_chain, bool fUseCache=true) const
 
CAmount CWalletTx::GetAvailableCredit (interfaces::Chain::Lock &locked_chain, bool fUseCache=true, const isminefilter &filter=ISMINE_SPENDABLE) const NO_THREAD_SAFETY_ANALYSIS
 
CAmount CWalletTx::GetImmatureWatchOnlyCredit (interfaces::Chain::Lock &locked_chain, const bool fUseCache=true) const
 
CAmount CWalletTx::GetChange () const
 
bool CWalletTx::InMempool () const
 
bool CWalletTx::IsTrusted (interfaces::Chain::Lock &locked_chain) const
 
bool CWalletTx::IsEquivalentTo (const CWalletTx &tx) const
 
void CWallet::ResendWalletTransactions ()
 

Detailed Description

Function Documentation

◆ AbandonTransaction()

bool CWallet::AbandonTransaction ( interfaces::Chain::Lock locked_chain,
const uint256 hashTx 
)

Definition at line 1113 of file wallet.cpp.

Here is the call graph for this function:

◆ AddCryptedKey()

bool CWallet::AddCryptedKey ( const CPubKey vchPubKey,
const std::vector< unsigned char > &  vchCryptedSecret 
)
overridevirtual

Adds an encrypted key to the store, and saves it to disk.

Reimplemented from CCryptoKeyStore.

Definition at line 333 of file wallet.cpp.

Here is the call graph for this function:

◆ AddCScript()

bool CWallet::AddCScript ( const CScript redeemScript)
overridevirtual

Support for BIP 0013 : see https://github.com/bitcoin/bips/blob/master/bip-0013.mediawiki.

Reimplemented from CBasicKeyStore.

Definition at line 434 of file wallet.cpp.

Here is the call graph for this function:

◆ AddKeyPubKey()

bool CWallet::AddKeyPubKey ( const CKey key,
const CPubKey pubkey 
)
overridevirtual

Adds a key to the store, and saves it to disk.

Reimplemented from CCryptoKeyStore.

Definition at line 327 of file wallet.cpp.

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

◆ AddKeyPubKeyWithDB()

bool CWallet::AddKeyPubKeyWithDB ( WalletBatch batch,
const CKey key,
const CPubKey pubkey 
)

Definition at line 287 of file wallet.cpp.

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

◆ AddToSpends() [1/2]

void CWallet::AddToSpends ( const COutPoint outpoint,
const uint256 wtxid 
)
private

Definition at line 706 of file wallet.cpp.

◆ AddToSpends() [2/2]

void CWallet::AddToSpends ( const uint256 wtxid)
private

Definition at line 718 of file wallet.cpp.

◆ AddToWallet()

bool CWallet::AddToWallet ( const CWalletTx wtxIn,
bool  fFlushOnClose = true 
)

Definition at line 933 of file wallet.cpp.

Here is the call graph for this function:

◆ AddToWalletIfInvolvingMe()

bool CWallet::AddToWalletIfInvolvingMe ( const CTransactionRef tx,
const uint256 block_hash,
int  posInBlock,
bool  fUpdate 
)
private

Add a transaction to the wallet, or update it.

pIndex and posInBlock should be set when the transaction was known to be included in a block. When pIndex == nullptr, then wallet state is not updated in AddToWallet, but notifications happen and cached balances are marked dirty.

If fUpdate is true, existing transactions will be updated. TODO: One exception to this is that the abandoned state is cleared under the assumption that any further notification of a transaction that was considered abandoned is an indication that it is not safe to be considered abandoned. Abandoned state should probably be more carefully tracked via different posInBlock signals or by checking mempool presence when necessary.

Definition at line 1038 of file wallet.cpp.

Here is the call graph for this function:

◆ AddWatchOnly() [1/2]

bool CWallet::AddWatchOnly ( const CScript dest)
overrideprivatevirtual

Private version of AddWatchOnly method which does not accept a timestamp, and which will reset the wallet's nTimeFirstKey value to 1 if the watch key did not previously have a timestamp associated with it.

Because this is an inherited virtual method, it is accessible despite being marked private, but it is marked private anyway to encourage use of the other AddWatchOnly which accepts a timestamp and sets nTimeFirstKey more intelligently for more efficient rescans.

Reimplemented from CBasicKeyStore.

Definition at line 460 of file wallet.cpp.

Here is the call graph for this function:

◆ AddWatchOnly() [2/2]

bool CWallet::AddWatchOnly ( const CScript dest,
int64_t  nCreateTime 
)

Adds a watch-only address to the store, and saves it to disk.

Definition at line 474 of file wallet.cpp.

◆ BlockConnected()

void CWallet::BlockConnected ( const CBlock block,
const std::vector< CTransactionRef > &  vtxConflicted 
)
overridevirtual

Reimplemented from interfaces::Chain::Notifications.

Definition at line 1249 of file wallet.cpp.

Here is the call graph for this function:

◆ BlockDisconnected()

void CWallet::BlockDisconnected ( const CBlock block)
overridevirtual

Reimplemented from interfaces::Chain::Notifications.

Definition at line 1273 of file wallet.cpp.

◆ BlockUntilSyncedToCurrentChain()

void CWallet::BlockUntilSyncedToCurrentChain ( )

Blocks until the wallet state is up-to-date to /at least/ the current chain at the time this function is entered Obviously holding cs_main/cs_wallet when going into this call may cause deadlock.

Definition at line 1288 of file wallet.cpp.

Here is the caller graph for this function:

◆ CalculateMaximumSignedInputSize()

int CalculateMaximumSignedInputSize ( const CTxOut txout,
const CWallet wallet,
bool  use_max_sig 
)

Definition at line 1638 of file wallet.cpp.

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

◆ CalculateMaximumSignedTxSize() [1/2]

int64_t CalculateMaximumSignedTxSize ( const CTransaction tx,
const CWallet wallet,
bool  use_max_sig 
)

Definition at line 1609 of file wallet.cpp.

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

◆ CalculateMaximumSignedTxSize() [2/2]

int64_t CalculateMaximumSignedTxSize ( const CTransaction tx,
const CWallet wallet,
const std::vector< CTxOut > &  txouts,
bool  use_max_sig 
)

Definition at line 1627 of file wallet.cpp.

Here is the call graph for this function:

◆ CanGenerateKeys()

bool CWallet::CanGenerateKeys ( )

Definition at line 1512 of file wallet.cpp.

◆ CanGetAddresses()

bool CWallet::CanGetAddresses ( bool  internal = false)

Definition at line 1519 of file wallet.cpp.

◆ ChainStateFlushed()

void CWallet::ChainStateFlushed ( const CBlockLocator loc)
overridevirtual

Reimplemented from interfaces::Chain::Notifications.

Definition at line 567 of file wallet.cpp.

Here is the call graph for this function:

◆ ChangeWalletPassphrase()

bool CWallet::ChangeWalletPassphrase ( const SecureString strOldWalletPassphrase,
const SecureString strNewWalletPassphrase 
)

Definition at line 521 of file wallet.cpp.

Here is the call graph for this function:

◆ DeriveNewChildKey()

void CWallet::DeriveNewChildKey ( WalletBatch batch,
CKeyMetadata metadata,
CKey secret,
bool  internal = false 
)
private

Definition at line 232 of file wallet.cpp.

Here is the call graph for this function:

◆ DeriveNewSeed()

CPubKey CWallet::DeriveNewSeed ( const CKey key)

Definition at line 1456 of file wallet.cpp.

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

◆ DummySignInput()

bool CWallet::DummySignInput ( CTxIn tx_in,
const CTxOut txout,
bool  use_max_sig = false 
) const

Definition at line 1580 of file wallet.cpp.

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

◆ DummySignTx()

bool CWallet::DummySignTx ( CMutableTransaction txNew,
const std::vector< CTxOut > &  txouts,
bool  use_max_sig = false 
) const

Definition at line 1594 of file wallet.cpp.

◆ EncryptWallet()

bool CWallet::EncryptWallet ( const SecureString strWalletPassphrase)

Definition at line 730 of file wallet.cpp.

Here is the call graph for this function:

◆ Flush()

void CWallet::Flush ( bool  shutdown = false)

Flush wallet (bitdb flush)

Definition at line 639 of file wallet.cpp.

◆ GenerateNewKey()

CPubKey CWallet::GenerateNewKey ( WalletBatch batch,
bool  internal = false 
)

keystore implementation Generate a new key

Definition at line 195 of file wallet.cpp.

Here is the call graph for this function:

◆ GenerateNewSeed()

CPubKey CWallet::GenerateNewSeed ( )

Definition at line 1448 of file wallet.cpp.

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

◆ GetAffectedKeys()

std::vector<CKeyID> GetAffectedKeys ( const CScript spk,
const SigningProvider provider 
)

Definition at line 174 of file wallet.cpp.

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

◆ GetAmounts()

void CWalletTx::GetAmounts ( std::list< COutputEntry > &  listReceived,
std::list< COutputEntry > &  listSent,
CAmount nFee,
const isminefilter filter 
) const

Definition at line 1648 of file wallet.cpp.

Here is the call graph for this function:

◆ GetAvailableCredit()

CAmount CWalletTx::GetAvailableCredit ( interfaces::Chain::Lock locked_chain,
bool  fUseCache = true,
const isminefilter filter = ISMINE_SPENDABLE 
) const

Definition at line 1974 of file wallet.cpp.

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

◆ GetCachableAmount()

CAmount CWalletTx::GetCachableAmount ( AmountType  type,
const isminefilter filter,
bool  recalculate = false 
) const

Definition at line 1924 of file wallet.cpp.

◆ GetChange() [1/3]

CAmount CWalletTx::GetChange ( ) const

Definition at line 2019 of file wallet.cpp.

◆ GetChange() [2/3]

CAmount CWallet::GetChange ( const CTxOut txout) const

Definition at line 1371 of file wallet.cpp.

Here is the call graph for this function:

◆ GetChange() [3/3]

CAmount CWallet::GetChange ( const CTransaction tx) const

Definition at line 1436 of file wallet.cpp.

Here is the call graph for this function:

◆ GetConflicts() [1/2]

std::set< uint256 > CWalletTx::GetConflicts ( ) const

Definition at line 1912 of file wallet.cpp.

◆ GetConflicts() [2/2]

std::set< uint256 > CWallet::GetConflicts ( const uint256 txid) const

Get wallet transactions that conflict with given transaction (spend same outputs)

Definition at line 609 of file wallet.cpp.

Here is the call graph for this function:

◆ GetCredit() [1/3]

CAmount CWalletTx::GetCredit ( interfaces::Chain::Lock locked_chain,
const isminefilter filter 
) const

Definition at line 1948 of file wallet.cpp.

Here is the caller graph for this function:

◆ GetCredit() [2/3]

CAmount CWallet::GetCredit ( const CTxOut txout,
const isminefilter filter 
) const

Definition at line 1337 of file wallet.cpp.

Here is the call graph for this function:

◆ GetCredit() [3/3]

CAmount CWallet::GetCredit ( const CTransaction tx,
const isminefilter filter 
) const

Definition at line 1424 of file wallet.cpp.

Here is the call graph for this function:

◆ GetDebit() [1/3]

CAmount CWalletTx::GetDebit ( const isminefilter filter) const

filter decides which addresses will count towards the debit

Definition at line 1933 of file wallet.cpp.

◆ GetDebit() [2/3]

CAmount CWallet::GetDebit ( const CTxIn txin,
const isminefilter filter 
) const

Returns amount of debit if the input matches the filter, otherwise returns 0.

Definition at line 1316 of file wallet.cpp.

Here is the call graph for this function:

◆ GetDebit() [3/3]

CAmount CWallet::GetDebit ( const CTransaction tx,
const isminefilter filter 
) const

Definition at line 1391 of file wallet.cpp.

Here is the call graph for this function:

◆ GetImmatureCredit()

CAmount CWalletTx::GetImmatureCredit ( interfaces::Chain::Lock locked_chain,
bool  fUseCache = true 
) const

Definition at line 1965 of file wallet.cpp.

Here is the caller graph for this function:

◆ GetImmatureWatchOnlyCredit()

CAmount CWalletTx::GetImmatureWatchOnlyCredit ( interfaces::Chain::Lock locked_chain,
const bool  fUseCache = true 
) const

Definition at line 2010 of file wallet.cpp.

Here is the caller graph for this function:

◆ GetTxTime()

int64_t CWalletTx::GetTxTime ( ) const

Definition at line 1572 of file wallet.cpp.

◆ GetWalletTx()

const CWalletTx * CWallet::GetWalletTx ( const uint256 hash) const

Definition at line 186 of file wallet.cpp.

Here is the caller graph for this function:

◆ HasWalletSpend()

bool CWallet::HasWalletSpend ( const uint256 txid) const

Check if a given transaction has any of its outputs spent by another transaction in the wallet.

Definition at line 632 of file wallet.cpp.

Here is the call graph for this function:

◆ IncOrderPosNext()

int64_t CWallet::IncOrderPosNext ( WalletBatch batch = nullptr)

Increment the next transaction order id.

Returns
next transaction order id

Definition at line 883 of file wallet.cpp.

Here is the call graph for this function:

◆ InMempool()

bool CWalletTx::InMempool ( ) const

Definition at line 2028 of file wallet.cpp.

Here is the caller graph for this function:

◆ IsAllFromMe()

bool CWallet::IsAllFromMe ( const CTransaction tx,
const isminefilter filter 
) const

Returns whether all of the inputs match the filter.

Definition at line 1403 of file wallet.cpp.

Here is the call graph for this function:

◆ IsChange() [1/2]

bool CWallet::IsChange ( const CTxOut txout) const

Definition at line 1344 of file wallet.cpp.

◆ IsChange() [2/2]

bool CWallet::IsChange ( const CScript script) const

Definition at line 1349 of file wallet.cpp.

Here is the call graph for this function:

◆ IsEquivalentTo()

bool CWalletTx::IsEquivalentTo ( const CWalletTx tx) const

Definition at line 2065 of file wallet.cpp.

Here is the caller graph for this function:

◆ IsFromMe()

bool CWallet::IsFromMe ( const CTransaction tx) const

should probably be renamed to IsRelevantToMe

Definition at line 1386 of file wallet.cpp.

◆ IsHDEnabled()

bool CWallet::IsHDEnabled ( ) const

Definition at line 1507 of file wallet.cpp.

◆ IsMine() [1/3]

isminetype CWallet::IsMine ( const CTxIn txin) const

Definition at line 1299 of file wallet.cpp.

Here is the call graph for this function:

◆ IsMine() [2/3]

isminetype CWallet::IsMine ( const CTxOut txout) const

Definition at line 1332 of file wallet.cpp.

Here is the call graph for this function:

◆ IsMine() [3/3]

bool CWallet::IsMine ( const CTransaction tx) const

Definition at line 1378 of file wallet.cpp.

Here is the call graph for this function:

◆ IsSpent()

bool CWallet::IsSpent ( interfaces::Chain::Lock locked_chain,
const uint256 hash,
unsigned int  n 
) const

Outpoint is spent if any non-conflicted transaction spends it:

Definition at line 687 of file wallet.cpp.

◆ IsTrusted()

bool CWalletTx::IsTrusted ( interfaces::Chain::Lock locked_chain) const

Definition at line 2033 of file wallet.cpp.

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

◆ IsWalletFlagSet()

bool CWallet::IsWalletFlagSet ( uint64_t  flag)

check if a certain wallet flag is set

Definition at line 1552 of file wallet.cpp.

Here is the caller graph for this function:

◆ LoadCryptedKey()

bool CWallet::LoadCryptedKey ( const CPubKey vchPubKey,
const std::vector< unsigned char > &  vchCryptedSecret 
)

Adds an encrypted key to the store, without saving it to disk (used by LoadWallet)

Definition at line 413 of file wallet.cpp.

Here is the call graph for this function:

◆ LoadCScript()

bool CWallet::LoadCScript ( const CScript redeemScript)

Definition at line 445 of file wallet.cpp.

Here is the call graph for this function:

◆ LoadKeyMetadata()

void CWallet::LoadKeyMetadata ( const CKeyID keyID,
const CKeyMetadata metadata 
)

Load metadata (used by LoadWallet)

Definition at line 351 of file wallet.cpp.

Here is the call graph for this function:

◆ LoadScriptMetadata()

void CWallet::LoadScriptMetadata ( const CScriptID script_id,
const CKeyMetadata metadata 
)

Definition at line 358 of file wallet.cpp.

Here is the call graph for this function:

◆ LoadToWallet()

void CWallet::LoadToWallet ( const CWalletTx wtxIn)

Definition at line 1017 of file wallet.cpp.

Here is the call graph for this function:

◆ LoadWatchOnly()

bool CWallet::LoadWatchOnly ( const CScript dest)

Adds a watch-only address to the store, without saving it to disk (used by LoadWallet)

Definition at line 493 of file wallet.cpp.

Here is the call graph for this function:

◆ MarkConflicted()

void CWallet::MarkConflicted ( const uint256 hashBlock,
const uint256 hashTx 
)
private

Definition at line 1169 of file wallet.cpp.

Here is the call graph for this function:

◆ MarkDirty()

void CWallet::MarkDirty ( )

Definition at line 895 of file wallet.cpp.

Here is the caller graph for this function:

◆ MarkInputsDirty()

void CWallet::MarkInputsDirty ( const CTransactionRef tx)
private

Definition at line 1103 of file wallet.cpp.

◆ MarkReplaced()

bool CWallet::MarkReplaced ( const uint256 originalHash,
const uint256 newHash 
)

Mark a transaction as replaced by another transaction (e.g., BIP 125).

Definition at line 904 of file wallet.cpp.

Here is the call graph for this function:

◆ ReacceptWalletTransactions()

void CWallet::ReacceptWalletTransactions ( interfaces::Chain::Lock locked_chain)

Definition at line 1860 of file wallet.cpp.

Here is the call graph for this function:

◆ RelayWalletTransaction()

bool CWalletTx::RelayWalletTransaction ( interfaces::Chain::Lock locked_chain)

Definition at line 1889 of file wallet.cpp.

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

◆ RemoveWatchOnly()

bool CWallet::RemoveWatchOnly ( const CScript dest)
overridevirtual

Reimplemented from CBasicKeyStore.

Definition at line 480 of file wallet.cpp.

Here is the call graph for this function:

◆ ReorderTransactions()

DBErrors CWallet::ReorderTransactions ( )

Definition at line 826 of file wallet.cpp.

Here is the call graph for this function:

◆ RescanFromTime()

int64_t CWallet::RescanFromTime ( int64_t  startTime,
const WalletRescanReserver reserver,
bool  update 
)

Scan active chain for relevant transactions after importing keys.

This should be called whenever new keys are added to the wallet, with the oldest key creation time.

Returns
Earliest timestamp that could be successfully scanned from. Timestamp returned will be higher than startTime if relevant blocks could not be read.

Definition at line 1711 of file wallet.cpp.

◆ ResendWalletTransactions()

void CWallet::ResendWalletTransactions ( )

Definition at line 2083 of file wallet.cpp.

Here is the call graph for this function:

◆ ScanForWalletTransactions()

CWallet::ScanResult CWallet::ScanForWalletTransactions ( const uint256 start_block,
const uint256 stop_block,
const WalletRescanReserver reserver,
bool  fUpdate 
)

Scan the block chain (starting in start_block) for transactions from or to us.

If fUpdate is true, found transactions that already exist in the wallet will be updated.

Parameters
[in]start_blockScan starting block. If block is not on the active chain, the scan will return SUCCESS immediately.
[in]stop_blockScan ending block. If block is not on the active chain, the scan will continue until it reaches the chain tip.
Returns
ScanResult returning scan information and indicating success or failure. Return status will be set to SUCCESS if scan was successful. FAILURE if a complete rescan was not possible (due to pruning or corruption). USER_ABORT if the rescan was aborted before it could complete.
Precondition
Caller needs to make sure start_block (and the optional stop_block) are on the main chain after to the addition of any new keys you want to detect transactions for.

Definition at line 1759 of file wallet.cpp.

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

◆ SetHDChain()

void CWallet::SetHDChain ( const CHDChain chain,
bool  memonly 
)

Definition at line 1498 of file wallet.cpp.

Here is the call graph for this function:

◆ SetHDSeed()

void CWallet::SetHDSeed ( const CPubKey key)

Definition at line 1484 of file wallet.cpp.

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

◆ SetMaxVersion()

bool CWallet::SetMaxVersion ( int  nVersion)

change which version we're allowed to upgrade to (note that this does not immediately imply upgrading to that format)

Definition at line 597 of file wallet.cpp.

◆ SetMinVersion()

void CWallet::SetMinVersion ( enum WalletFeature  nVersion,
WalletBatch batch_in = nullptr,
bool  fExplicit = false 
)

signify that a particular wallet feature is now used. this may change nWalletVersion and nWalletMaxVersion if those are lower

Definition at line 573 of file wallet.cpp.

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

◆ SetWalletFlag()

void CWallet::SetWalletFlag ( uint64_t  flags)

set a single wallet flag

Definition at line 1536 of file wallet.cpp.

Here is the call graph for this function:

◆ SetWalletFlags()

bool CWallet::SetWalletFlags ( uint64_t  overwriteFlags,
bool  memOnly 
)

overwrite all flags by the given uint64_t returns false if unknown, non-tolerable flags are present

Definition at line 1557 of file wallet.cpp.

◆ SyncMetaData()

void CWallet::SyncMetaData ( std::pair< TxSpends::iterator, TxSpends::iterator >  range)
private

Definition at line 644 of file wallet.cpp.

Here is the call graph for this function:

◆ SyncTransaction()

void CWallet::SyncTransaction ( const CTransactionRef tx,
const uint256 block_hash,
int  posInBlock = 0,
bool  update_tx = true 
)
private

Definition at line 1220 of file wallet.cpp.

◆ ToString()

std::string COutput::ToString ( ) const

Definition at line 169 of file wallet.cpp.

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

◆ TransactionAddedToMempool()

void CWallet::TransactionAddedToMempool ( const CTransactionRef tx)
overridevirtual

Reimplemented from interfaces::Chain::Notifications.

Definition at line 1230 of file wallet.cpp.

◆ TransactionCanBeAbandoned()

bool CWallet::TransactionCanBeAbandoned ( const uint256 hashTx) const

Return whether transaction can be abandoned.

Definition at line 1095 of file wallet.cpp.

Here is the call graph for this function:

◆ TransactionRemovedFromMempool()

void CWallet::TransactionRemovedFromMempool ( const CTransactionRef ptx)
overridevirtual

Reimplemented from interfaces::Chain::Notifications.

Definition at line 1241 of file wallet.cpp.

◆ Unlock()

bool CWallet::Unlock ( const SecureString strWalletPassphrase,
bool  accept_no_keys = false 
)

Definition at line 498 of file wallet.cpp.

Here is the call graph for this function:

◆ UnsetWalletFlag()

void CWallet::UnsetWalletFlag ( uint64_t  flag)

Unsets a single wallet flag.

Definition at line 1544 of file wallet.cpp.

Here is the call graph for this function:

◆ UpdatedBlockTip()

void CWallet::UpdatedBlockTip ( )
overridevirtual

Reimplemented from interfaces::Chain::Notifications.

Definition at line 1282 of file wallet.cpp.

Here is the call graph for this function:

◆ UpdateTimeFirstKey()

void CWallet::UpdateTimeFirstKey ( int64_t  nCreateTime)

Update wallet first key creation time.

This should be called whenever keys are added to the wallet, with the oldest key creation time.

Definition at line 422 of file wallet.cpp.

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

◆ UpgradeKeyMetadata()

void CWallet::UpgradeKeyMetadata ( )

Upgrade stored CKeyMetadata objects to store key origin info as KeyOriginInfo.

Definition at line 371 of file wallet.cpp.

Here is the call graph for this function:

◆ WriteKeyMetadata()

bool CWallet::WriteKeyMetadata ( const CKeyMetadata meta,
const CPubKey pubkey,
bool  overwrite 
)

Definition at line 366 of file wallet.cpp.

Here is the call graph for this function: