aboutsummaryrefslogtreecommitdiff
path: root/src/wallet.h
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2014-01-22 08:07:19 +0100
committerWladimir J. van der Laan <laanwj@gmail.com>2014-01-22 08:07:56 +0100
commitceab53b41da4e812a63a7a7d6d05e9ed246a5cd5 (patch)
treefafe0f2960aff0fa77f2a30c5aadc436a76b7f01 /src/wallet.h
parent6586bc3b51ac0a3891ff6297e1aea791ff331cd3 (diff)
parent4d901023b732efb492d89cebd8555c689ab7663e (diff)
downloadbitcoin-ceab53b41da4e812a63a7a7d6d05e9ed246a5cd5.tar.xz
Merge pull request #3521
4d90102 [Qt] Add sorting feature to the requested payments table (Cozz Lovan) 8476d5d [Qt] Permanently store requested payments in wallet (Cozz Lovan) b10e147 wallet: add interface for storing generic data on destinations (Wladimir J. van der Laan)
Diffstat (limited to 'src/wallet.h')
-rw-r--r--src/wallet.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/wallet.h b/src/wallet.h
index e4452a3093..dc8c007ac8 100644
--- a/src/wallet.h
+++ b/src/wallet.h
@@ -83,6 +83,9 @@ public:
{
purpose = "unknown";
}
+
+ typedef std::map<std::string, std::string> StringMap;
+ StringMap destdata;
};
/** A CWallet is an extension of a keystore, which also maintains a set of transactions and balances,
@@ -189,6 +192,15 @@ public:
bool AddCScript(const CScript& redeemScript);
bool LoadCScript(const CScript& redeemScript) { return CCryptoKeyStore::AddCScript(redeemScript); }
+ /// Adds a destination data tuple to the store, and saves it to disk
+ bool AddDestData(const CTxDestination &dest, const std::string &key, const std::string &value);
+ /// Erases a destination data tuple in the store and on disk
+ bool EraseDestData(const CTxDestination &dest, const std::string &key);
+ /// Adds a destination data tuple to the store, without saving it to disk
+ bool LoadDestData(const CTxDestination &dest, const std::string &key, const std::string &value);
+ /// Look up a destination data tuple in the store, return true if found false otherwise
+ bool GetDestData(const CTxDestination &dest, const std::string &key, std::string *value) const;
+
bool Unlock(const SecureString& strWalletPassphrase);
bool ChangeWalletPassphrase(const SecureString& strOldWalletPassphrase, const SecureString& strNewWalletPassphrase);
bool EncryptWallet(const SecureString& strWalletPassphrase);