From 22dfd7359863217eb8caef75084cfa8fa8e1d8fb Mon Sep 17 00:00:00 2001 From: coderrr Date: Wed, 1 Aug 2012 12:48:42 -0400 Subject: Add address groupings RPC from the coincontrol patches. Signed-off-by: Gregory Maxwell --- src/wallet.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/wallet.h') diff --git a/src/wallet.h b/src/wallet.h index 9103aa675e..5f6a6a4444 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -10,6 +10,7 @@ #include +#include "base58.h" #include "main.h" #include "key.h" #include "keystore.h" @@ -176,6 +177,9 @@ public: int64 GetOldestKeyPoolTime(); void GetAllReserveKeys(std::set& setAddress); + std::set< std::set > GetAddressGroupings(); + std::map GetAddressBalances(); + bool IsMine(const CTxIn& txin) const; int64 GetDebit(const CTxIn& txin) const; bool IsMine(const CTxOut& txout) const @@ -643,6 +647,13 @@ public: return true; } + std::string GetAddressOfTxOut(int n) + { + CTxDestination addr; + ExtractDestination(vout[n].scriptPubKey, addr); + return CBitcoinAddress(addr).ToString(); + } + bool WriteToDisk(); int64 GetTxTime() const; -- cgit v1.2.3 From 92735bca313768dbc49789566c47e3a68ecef59a Mon Sep 17 00:00:00 2001 From: Gregory Maxwell Date: Mon, 6 Aug 2012 13:02:48 -0400 Subject: Add txout address filtering to listunspent. This applies on top of the coincontrol listaddressgroupings patch and makes finding eligible outputs from the groups returned by listaddressgroupings possible. --- src/wallet.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/wallet.h') diff --git a/src/wallet.h b/src/wallet.h index 5f6a6a4444..f02c1467b5 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -647,7 +647,7 @@ public: return true; } - std::string GetAddressOfTxOut(int n) + std::string GetAddressOfTxOut(int n) const { CTxDestination addr; ExtractDestination(vout[n].scriptPubKey, addr); -- cgit v1.2.3 From b1093efa833376a7883deb0cbcddd0aed364de84 Mon Sep 17 00:00:00 2001 From: Gregory Maxwell Date: Mon, 20 Aug 2012 13:43:33 -0400 Subject: Change CWallet addressgrouping to use CTxDestination instead of strings. This is cleanup for the listaddressgroupings code. Also add some real help text. --- src/wallet.h | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'src/wallet.h') diff --git a/src/wallet.h b/src/wallet.h index f02c1467b5..428cff7480 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -10,7 +10,6 @@ #include -#include "base58.h" #include "main.h" #include "key.h" #include "keystore.h" @@ -177,8 +176,8 @@ public: int64 GetOldestKeyPoolTime(); void GetAllReserveKeys(std::set& setAddress); - std::set< std::set > GetAddressGroupings(); - std::map GetAddressBalances(); + std::set< std::set > GetAddressGroupings(); + std::map GetAddressBalances(); bool IsMine(const CTxIn& txin) const; int64 GetDebit(const CTxIn& txin) const; @@ -647,13 +646,6 @@ public: return true; } - std::string GetAddressOfTxOut(int n) const - { - CTxDestination addr; - ExtractDestination(vout[n].scriptPubKey, addr); - return CBitcoinAddress(addr).ToString(); - } - bool WriteToDisk(); int64 GetTxTime() const; -- cgit v1.2.3