Add Rules to ReadView:

An instance of Rules provides information on the tx
processing rules in a particular ledger.

* OpenView allows rules to be set on construction.

Conflicts:
	src/ripple/unity/ledger.cpp
This commit is contained in:
Vinnie Falco
2015-07-16 09:54:10 -07:00
parent eb49e1bf47
commit 0cf58cc505
19 changed files with 269 additions and 56 deletions

View File

@@ -1322,7 +1322,14 @@ void NetworkOPsImp::switchLastClosedLedger (
#if RIPPLE_OPEN_LEDGER
auto retries = localTx;
getApp().openLedger().accept(
auto const lastVal =
getApp().getLedgerMaster().getValidatedLedger();
boost::optional<Rules> rules;
if (lastVal)
rules.emplace(*lastVal);
else
rules.emplace();
getApp().openLedger().accept(*rules,
newLCL, OrderedTxs({}), false, retries,
tapNONE, getApp().getHashRouter(), "jump");
getApp().openLedger().verify(