![]() |
BSHA3
0.17.99
P2P Blockchain, based on Bitcoin
|
Classes | |
class | CAffectedKeysVisitor |
A class to identify which pubkeys a script and a keystore have in common. More... | |
Functions | |
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 CWalletTx * | CWallet::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::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 | CWallet::ChangeWalletPassphrase (const SecureString &strOldWalletPassphrase, const SecureString &strNewWalletPassphrase) |
void | CWallet::ChainStateFlushed (const CBlockLocator &loc) override |
Notifies listeners of the new active block chain on-disk. More... | |
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< uint256 > | CWallet::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 (const uint256 &hash, unsigned int n) const EXCLUSIVE_LOCKS_REQUIRED(cs_main |
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 CBlockIndex *pIndex, 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 (const uint256 &hashTx) |
void | CWallet::MarkConflicted (const uint256 &hashBlock, const uint256 &hashTx) |
void | CWallet::SyncTransaction (const CTransactionRef &tx, const CBlockIndex *pindex=nullptr, int posInBlock=0, bool update_tx=true) EXCLUSIVE_LOCKS_REQUIRED(cs_wallet) |
void | CWallet::TransactionAddedToMempool (const CTransactionRef &tx) override |
Notifies listeners of a transaction having been added to mempool. More... | |
void | CWallet::TransactionRemovedFromMempool (const CTransactionRef &ptx) override |
Notifies listeners of a transaction leaving mempool. More... | |
void | CWallet::BlockConnected (const std::shared_ptr< const CBlock > &pblock, const CBlockIndex *pindex, const std::vector< CTransactionRef > &vtxConflicted) override |
Notifies listeners of a block being connected. More... | |
void | CWallet::BlockDisconnected (const std::shared_ptr< const CBlock > &pblock) override |
Notifies listeners of a block being disconnected. More... | |
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 |
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 |
void | CWallet::SetWalletFlag (uint64_t flags) |
set 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... | |
CBlockIndex * | CWallet::ScanForWalletTransactions (CBlockIndex *pindexStart, CBlockIndex *pindexStop, const WalletRescanReserver &reserver, bool fUpdate=false) |
Scan the block chain (starting in pindexStart) for transactions from or to us. More... | |
void | CWallet::ReacceptWalletTransactions () |
bool | CWalletTx::RelayWalletTransaction (CConnman *connman) EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
std::set< uint256 > | CWalletTx::GetConflicts () const NO_THREAD_SAFETY_ANALYSIS |
CAmount | CWalletTx::GetDebit (const isminefilter &filter) const |
filter decides which addresses will count towards the debit More... | |
CAmount | CWalletTx::GetCredit (const isminefilter &filter) const EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
CAmount | CWalletTx::GetImmatureCredit (bool fUseCache=true) const EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
CAmount | CWalletTx::GetAvailableCredit (bool fUseCache=true, const isminefilter &filter=ISMINE_SPENDABLE) const NO_THREAD_SAFETY_ANALYSIS |
CAmount | CWalletTx::GetImmatureWatchOnlyCredit (const bool fUseCache=true) const EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
CAmount | CWalletTx::GetChange () const |
bool | CWalletTx::InMempool () const |
bool | CWalletTx::IsTrusted () const EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
bool | CWalletTx::IsEquivalentTo (const CWalletTx &tx) const |
std::vector< uint256 > | CWallet::ResendWalletTransactionsBefore (int64_t nTime, CConnman *connman) EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
void | CWallet::ResendWalletTransactions (int64_t nBestBlockTime, CConnman *connman) override EXCLUSIVE_LOCKS_REQUIRED(cs_main) |
Tells listeners to broadcast their data. More... | |
bool CWallet::AbandonTransaction | ( | const uint256 & | hashTx | ) |
|
overridevirtual |
Adds an encrypted key to the store, and saves it to disk.
Reimplemented from CCryptoKeyStore.
Definition at line 302 of file wallet.cpp.
|
overridevirtual |
Support for BIP 0013 : see https://github.com/bitcoin/bips/blob/master/bip-0013.mediawiki.
Reimplemented from CBasicKeyStore.
Definition at line 355 of file wallet.cpp.
Adds a key to the store, and saves it to disk.
Reimplemented from CCryptoKeyStore.
Definition at line 296 of file wallet.cpp.
bool CWallet::AddKeyPubKeyWithDB | ( | WalletBatch & | batch, |
const CKey & | key, | ||
const CPubKey & | pubkey | ||
) |
Definition at line 260 of file wallet.cpp.
Definition at line 616 of file wallet.cpp.
|
private |
bool CWallet::AddToWallet | ( | const CWalletTx & | wtxIn, |
bool | fFlushOnClose = true |
||
) |
Definition at line 843 of file wallet.cpp.
|
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 948 of file wallet.cpp.
|
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 377 of file wallet.cpp.
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 387 of file wallet.cpp.
|
overridevirtual |
Notifies listeners of a block being connected.
Provides a vector of transactions evicted from the mempool as a result.
Called on a background thread.
Reimplemented from CValidationInterface.
Definition at line 1161 of file wallet.cpp.
|
overridevirtual |
Notifies listeners of a block being disconnected.
Called on a background thread.
Reimplemented from CValidationInterface.
Definition at line 1183 of file wallet.cpp.
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 1193 of file wallet.cpp.
int CalculateMaximumSignedInputSize | ( | const CTxOut & | txout, |
const CWallet * | wallet, | ||
bool | use_max_sig | ||
) |
Definition at line 1517 of file wallet.cpp.
int64_t CalculateMaximumSignedTxSize | ( | const CTransaction & | tx, |
const CWallet * | wallet, | ||
bool | use_max_sig | ||
) |
Definition at line 1488 of file wallet.cpp.
int64_t CalculateMaximumSignedTxSize | ( | const CTransaction & | tx, |
const CWallet * | wallet, | ||
const std::vector< CTxOut > & | txouts, | ||
bool | use_max_sig | ||
) |
|
overridevirtual |
Notifies listeners of the new active block chain on-disk.
Prior to this callback, any updates are not guaranteed to persist on disk (ie clients need to handle shutdown/restart safety by being able to understand when some updates were lost due to unclean shutdown).
When this callback is invoked, the validation changes done by any prior callback are guaranteed to exist on disk and survive a restart, including an unclean shutdown.
Provides a locator describing the best chain, which is likely useful for storing current state on disk in client DBs.
Called on a background thread.
Reimplemented from CValidationInterface.
Definition at line 477 of file wallet.cpp.
bool CWallet::ChangeWalletPassphrase | ( | const SecureString & | strOldWalletPassphrase, |
const SecureString & | strNewWalletPassphrase | ||
) |
|
private |
Definition at line 214 of file wallet.cpp.
Definition at line 1370 of file wallet.cpp.
bool CWallet::DummySignInput | ( | CTxIn & | tx_in, |
const CTxOut & | txout, | ||
bool | use_max_sig = false |
||
) | const |
Definition at line 1459 of file wallet.cpp.
bool CWallet::DummySignTx | ( | CMutableTransaction & | txNew, |
const std::vector< CTxOut > & | txouts, | ||
bool | use_max_sig = false |
||
) | const |
bool CWallet::EncryptWallet | ( | const SecureString & | strWalletPassphrase | ) |
void CWallet::Flush | ( | bool | shutdown = false | ) |
Flush wallet (bitdb flush)
Definition at line 549 of file wallet.cpp.
CPubKey CWallet::GenerateNewKey | ( | WalletBatch & | batch, |
bool | internal = false |
||
) |
keystore implementation Generate a new key
Definition at line 178 of file wallet.cpp.
CPubKey CWallet::GenerateNewSeed | ( | ) |
Definition at line 1362 of file wallet.cpp.
void CWalletTx::GetAmounts | ( | std::list< COutputEntry > & | listReceived, |
std::list< COutputEntry > & | listSent, | ||
CAmount & | nFee, | ||
const isminefilter & | filter | ||
) | const |
CAmount CWalletTx::GetAvailableCredit | ( | bool | fUseCache = true , |
const isminefilter & | filter = ISMINE_SPENDABLE |
||
) | const |
Definition at line 1851 of file wallet.cpp.
CAmount CWalletTx::GetChange | ( | ) | const |
Definition at line 1285 of file wallet.cpp.
CAmount CWallet::GetChange | ( | const CTransaction & | tx | ) | const |
std::set< uint256 > CWalletTx::GetConflicts | ( | ) | const |
Get wallet transactions that conflict with given transaction (spend same outputs)
Definition at line 519 of file wallet.cpp.
CAmount CWalletTx::GetCredit | ( | const isminefilter & | filter | ) | const |
CAmount CWallet::GetCredit | ( | const CTxOut & | txout, |
const isminefilter & | filter | ||
) | const |
Definition at line 1256 of file wallet.cpp.
CAmount CWallet::GetCredit | ( | const CTransaction & | tx, |
const isminefilter & | filter | ||
) | const |
CAmount CWalletTx::GetDebit | ( | const isminefilter & | filter | ) | const |
filter decides which addresses will count towards the debit
Definition at line 1774 of file wallet.cpp.
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 1235 of file wallet.cpp.
CAmount CWallet::GetDebit | ( | const CTransaction & | tx, |
const isminefilter & | filter | ||
) | const |
CAmount CWalletTx::GetImmatureCredit | ( | bool | fUseCache = true | ) | const |
Definition at line 1838 of file wallet.cpp.
CAmount CWalletTx::GetImmatureWatchOnlyCredit | ( | const bool | fUseCache = true | ) | const |
Definition at line 1896 of file wallet.cpp.
int64_t CWalletTx::GetTxTime | ( | ) | const |
Definition at line 1451 of file wallet.cpp.
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 542 of file wallet.cpp.
int64_t CWallet::IncOrderPosNext | ( | WalletBatch * | batch = nullptr | ) |
Increment the next transaction order id.
Definition at line 793 of file wallet.cpp.
bool CWalletTx::InMempool | ( | ) | const |
bool CWallet::IsAllFromMe | ( | const CTransaction & | tx, |
const isminefilter & | filter | ||
) | const |
Returns whether all of the inputs match the filter.
Definition at line 1317 of file wallet.cpp.
bool CWallet::IsChange | ( | const CTxOut & | txout | ) | const |
Definition at line 1263 of file wallet.cpp.
bool CWalletTx::IsEquivalentTo | ( | const CWalletTx & | tx | ) | const |
bool CWallet::IsFromMe | ( | const CTransaction & | tx | ) | const |
should probably be renamed to IsRelevantToMe
Definition at line 1300 of file wallet.cpp.
bool CWallet::IsHDEnabled | ( | ) | const |
Definition at line 1418 of file wallet.cpp.
isminetype CWallet::IsMine | ( | const CTxIn & | txin | ) | const |
isminetype CWallet::IsMine | ( | const CTxOut & | txout | ) | const |
bool CWallet::IsMine | ( | const CTransaction & | tx | ) | const |
bool CWallet::IsSpent | ( | const uint256 & | hash, |
unsigned int | n | ||
) | const |
Outpoint is spent if any non-conflicted transaction spends it:
Definition at line 597 of file wallet.cpp.
bool CWalletTx::IsTrusted | ( | ) | const |
Definition at line 1923 of file wallet.cpp.
bool CWallet::IsWalletFlagSet | ( | uint64_t | flag | ) |
check if a certain wallet flag is set
Definition at line 1431 of file wallet.cpp.
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 334 of file wallet.cpp.
bool CWallet::LoadCScript | ( | const CScript & | redeemScript | ) |
void CWallet::LoadKeyMetadata | ( | const CKeyID & | keyID, |
const CKeyMetadata & | metadata | ||
) |
Load metadata (used by LoadWallet)
Definition at line 320 of file wallet.cpp.
void CWallet::LoadScriptMetadata | ( | const CScriptID & | script_id, |
const CKeyMetadata & | metadata | ||
) |
void CWallet::LoadToWallet | ( | const CWalletTx & | wtxIn | ) |
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 406 of file wallet.cpp.
Definition at line 1079 of file wallet.cpp.
void CWallet::MarkDirty | ( | ) |
|
private |
Mark a transaction as replaced by another transaction (e.g., BIP 125).
Definition at line 814 of file wallet.cpp.
void CWallet::ReacceptWalletTransactions | ( | ) |
Definition at line 1710 of file wallet.cpp.
bool CWalletTx::RelayWalletTransaction | ( | CConnman * | connman | ) |
Definition at line 1740 of file wallet.cpp.
|
overridevirtual |
Reimplemented from CBasicKeyStore.
Definition at line 393 of file wallet.cpp.
DBErrors CWallet::ReorderTransactions | ( | ) |
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.
Definition at line 1592 of file wallet.cpp.
|
overridevirtual |
Tells listeners to broadcast their data.
Reimplemented from CValidationInterface.
Definition at line 1988 of file wallet.cpp.
std::vector< uint256 > CWallet::ResendWalletTransactionsBefore | ( | int64_t | nTime, |
CConnman * | connman | ||
) |
Definition at line 1963 of file wallet.cpp.
CBlockIndex * CWallet::ScanForWalletTransactions | ( | CBlockIndex * | pindexStart, |
CBlockIndex * | pindexStop, | ||
const WalletRescanReserver & | reserver, | ||
bool | fUpdate = false |
||
) |
Scan the block chain (starting in pindexStart) for transactions from or to us.
If fUpdate is true, found transactions that already exist in the wallet will be updated.
Returns null if scan was successful. Otherwise, if a complete rescan was not possible (due to pruning or corruption), returns pointer to the most recent block that could not be scanned.
If pindexStop is not a nullptr, the scan will stop at the block-index defined by pindexStop
Caller needs to make sure pindexStop (and the optional pindexStart) are on the main chain after to the addition of any new keys you want to detect transactions for.
Definition at line 1629 of file wallet.cpp.
void CWallet::SetHDChain | ( | const CHDChain & | chain, |
bool | memonly | ||
) |
Definition at line 1409 of file wallet.cpp.
void CWallet::SetHDSeed | ( | const CPubKey & | key | ) |
Definition at line 1397 of file wallet.cpp.
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 507 of file wallet.cpp.
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 483 of file wallet.cpp.
void CWallet::SetWalletFlag | ( | uint64_t | flags | ) |
set a single wallet flag
Definition at line 1423 of file wallet.cpp.
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 1436 of file wallet.cpp.
|
private |
Definition at line 554 of file wallet.cpp.
|
private |
Definition at line 1133 of file wallet.cpp.
std::string COutput::ToString | ( | ) | const |
|
overridevirtual |
Notifies listeners of a transaction having been added to mempool.
Called on a background thread.
Reimplemented from CValidationInterface.
Definition at line 1143 of file wallet.cpp.
bool CWallet::TransactionCanBeAbandoned | ( | const uint256 & | hashTx | ) | const |
Return whether transaction can be abandoned.
Definition at line 1007 of file wallet.cpp.
|
overridevirtual |
Notifies listeners of a transaction leaving mempool.
This only fires for transactions which leave mempool because of expiry, size limiting, reorg (changes in lock times/coinbase maturity), or replacement. This does not include any transactions which are included in BlockConnectedDisconnected either in block->vtx or in txnConflicted.
Called on a background thread.
Reimplemented from CValidationInterface.
Definition at line 1153 of file wallet.cpp.
bool CWallet::Unlock | ( | const SecureString & | strWalletPassphrase | ) |
Definition at line 411 of file wallet.cpp.
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 343 of file wallet.cpp.