main: start of address index

Adds a configuration option for addressindex to search for txids by address. Includes
an additional rpc method for getting the txids for an address.
This commit is contained in:
Braydon Fuller
2016-03-05 16:31:10 -05:00
committed by Braydon Fuller
parent 075b416f56
commit 9babc7ff9f
10 changed files with 192 additions and 0 deletions

View File

@@ -17,6 +17,7 @@
class CBlockFileInfo;
class CBlockIndex;
struct CDiskTxPos;
struct CAddressIndexKey;
class uint256;
//! -dbcache default (MiB)
@@ -57,6 +58,8 @@ public:
bool ReadReindexing(bool &fReindex);
bool ReadTxIndex(const uint256 &txid, CDiskTxPos &pos);
bool WriteTxIndex(const std::vector<std::pair<uint256, CDiskTxPos> > &list);
bool WriteAddressIndex(const std::vector<std::pair<CAddressIndexKey, CAmount> > &vect);
bool ReadAddressIndex(uint160 addressHash, int type, std::vector<std::pair<CAddressIndexKey, CAmount> > &addressIndex);
bool WriteFlag(const std::string &name, bool fValue);
bool ReadFlag(const std::string &name, bool &fValue);
bool LoadBlockIndexGuts();