aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet.h
diff options
context:
space:
mode:
authorSuhas Daftuar <[email protected]>2016-12-09 15:31:06 -0500
committerSuhas Daftuar <[email protected]>2017-01-10 08:14:50 -0500
commit766e8a40b478353a89622f42809ddb11e695a0c9 (patch)
tree9684f52d1c11174b940e36e3f0ea5c209ef2d367 /src/wallet/wallet.h
parentMerge #8811: rpc: Add support for JSON-RPC named arguments (diff)
downloaddiscoin-766e8a40b478353a89622f42809ddb11e695a0c9.tar.xz
discoin-766e8a40b478353a89622f42809ddb11e695a0c9.zip
[wallet] Add IsAllFromMe: true if all inputs are from wallet
Diffstat (limited to 'src/wallet/wallet.h')
-rw-r--r--src/wallet/wallet.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h
index b9fa6bb24..8a587f4ed 100644
--- a/src/wallet/wallet.h
+++ b/src/wallet/wallet.h
@@ -825,6 +825,10 @@ public:
std::set<CTxDestination> GetAccountAddresses(const std::string& strAccount) const;
isminetype IsMine(const CTxIn& txin) const;
+ /**
+ * Returns amount of debit if the input matches the
+ * filter, otherwise returns 0
+ */
CAmount GetDebit(const CTxIn& txin, const isminefilter& filter) const;
isminetype IsMine(const CTxOut& txout) const;
CAmount GetCredit(const CTxOut& txout, const isminefilter& filter) const;
@@ -834,6 +838,8 @@ public:
/** should probably be renamed to IsRelevantToMe */
bool IsFromMe(const CTransaction& tx) const;
CAmount GetDebit(const CTransaction& tx, const isminefilter& filter) const;
+ /** Returns whether all of the inputs match the filter */
+ bool IsAllFromMe(const CTransaction& tx, const isminefilter& filter) const;
CAmount GetCredit(const CTransaction& tx, const isminefilter& filter) const;
CAmount GetChange(const CTransaction& tx) const;
void SetBestChain(const CBlockLocator& loc);