Add 'walkLedger' function.

This commit is contained in:
JoelKatz
2012-10-14 21:32:23 -07:00
parent 319c6fbe54
commit f286621d17
2 changed files with 9 additions and 1 deletions

View File

@@ -957,6 +957,12 @@ uint256 Ledger::getRippleStateIndex(const NewcoinAddress& naA, const NewcoinAddr
return s.getSHA512Half();
}
bool Ledger::walkLedger()
{
std::vector<SHAMapMissingNode> missingNodes;
mAccountStateMap->walkMap(missingNodes, 1);
mTransactionMap->walkMap(missingNodes, 1);
return missingNodes.empty();
}
// vim:ts=4

View File

@@ -280,6 +280,8 @@ public:
void addJson(Json::Value&, int options);
bool walkLedger();
static bool unitTest();
};