Changeset View
Changeset View
Standalone View
Standalone View
src/wallet/wallet.h
Show First 20 Lines • Show All 518 Lines • ▼ Show 20 Lines | public: | ||||
bool IsFromMe(const isminefilter &filter) const { | bool IsFromMe(const isminefilter &filter) const { | ||||
return GetDebit(filter) > Amount::zero(); | return GetDebit(filter) > Amount::zero(); | ||||
} | } | ||||
// True if only scriptSigs are different | // True if only scriptSigs are different | ||||
bool IsEquivalentTo(const CWalletTx &tx) const; | bool IsEquivalentTo(const CWalletTx &tx) const; | ||||
bool InMempool() const; | bool InMempool() const; | ||||
bool IsTrusted(interfaces::Chain::Lock &locked_chain) const; | bool IsTrusted() const; | ||||
bool IsTrusted(interfaces::Chain::Lock &locked_chain, | bool IsTrusted(std::set<TxId> &trusted_parents) const; | ||||
std::set<TxId> &trusted_parents) const; | |||||
int64_t GetTxTime() const; | int64_t GetTxTime() const; | ||||
// Pass this transaction to node for mempool insertion and relay to peers if | // Pass this transaction to node for mempool insertion and relay to peers if | ||||
// flag set to true | // flag set to true | ||||
bool SubmitMemoryPoolAndRelay(std::string &err_string, bool relay); | bool SubmitMemoryPoolAndRelay(std::string &err_string, bool relay); | ||||
// TODO: Remove "NO_THREAD_SAFETY_ANALYSIS" and replace it with the correct | // TODO: Remove "NO_THREAD_SAFETY_ANALYSIS" and replace it with the correct | ||||
▲ Show 20 Lines • Show All 365 Lines • ▼ Show 20 Lines | bool CanSupportFeature(enum WalletFeature wf) const override | ||||
EXCLUSIVE_LOCKS_REQUIRED(cs_wallet) { | EXCLUSIVE_LOCKS_REQUIRED(cs_wallet) { | ||||
AssertLockHeld(cs_wallet); | AssertLockHeld(cs_wallet); | ||||
return nWalletMaxVersion >= wf; | return nWalletMaxVersion >= wf; | ||||
} | } | ||||
/** | /** | ||||
* populate vCoins with vector of available COutputs. | * populate vCoins with vector of available COutputs. | ||||
*/ | */ | ||||
void AvailableCoins(interfaces::Chain::Lock &locked_chain, | void AvailableCoins(std::vector<COutput> &vCoins, bool fOnlySafe = true, | ||||
std::vector<COutput> &vCoins, bool fOnlySafe = true, | |||||
const CCoinControl *coinControl = nullptr, | const CCoinControl *coinControl = nullptr, | ||||
const Amount nMinimumAmount = SATOSHI, | const Amount nMinimumAmount = SATOSHI, | ||||
const Amount nMaximumAmount = MAX_MONEY, | const Amount nMaximumAmount = MAX_MONEY, | ||||
const Amount nMinimumSumAmount = MAX_MONEY, | const Amount nMinimumSumAmount = MAX_MONEY, | ||||
const uint64_t nMaximumCount = 0) const | const uint64_t nMaximumCount = 0) const | ||||
EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); | EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); | ||||
/** | /** | ||||
* Return list of available coins and locked coins grouped by non-change | * Return list of available coins and locked coins grouped by non-change | ||||
* output address. | * output address. | ||||
*/ | */ | ||||
std::map<CTxDestination, std::vector<COutput>> | std::map<CTxDestination, std::vector<COutput>> ListCoins() const | ||||
ListCoins(interfaces::Chain::Lock &locked_chain) const | |||||
EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); | EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); | ||||
/** | /** | ||||
* Find non-change parent output. | * Find non-change parent output. | ||||
*/ | */ | ||||
const CTxOut &FindNonChangeParentOutput(const CTransaction &tx, | const CTxOut &FindNonChangeParentOutput(const CTransaction &tx, | ||||
int output) const | int output) const | ||||
EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); | EXCLUSIVE_LOCKS_REQUIRED(cs_wallet); | ||||
▲ Show 20 Lines • Show All 598 Lines • Show Last 20 Lines |