本文整理汇总了C++中LedgerDelta::getLiveEntries方法的典型用法代码示例。如果您正苦于以下问题:C++ LedgerDelta::getLiveEntries方法的具体用法?C++ LedgerDelta::getLiveEntries怎么用?C++ LedgerDelta::getLiveEntries使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LedgerDelta
的用法示例。
在下文中一共展示了LedgerDelta::getLiveEntries方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: has
void
LedgerManagerImpl::closeLedgerHelper(LedgerDelta const& delta)
{
delta.markMeters(mApp);
mApp.getBucketManager().addBatch(mApp, mCurrentLedger->mHeader.ledgerSeq,
delta.getLiveEntries(),
delta.getDeadEntries());
mApp.getBucketManager().snapshotLedger(mCurrentLedger->mHeader);
mCurrentLedger->storeInsert(*this);
mApp.getPersistentState().setState(PersistentState::kLastClosedLedger,
binToHex(mCurrentLedger->getHash()));
// Store the current HAS in the database; this is really just to checkpoint
// the bucketlist so we can survive a restart and re-attach to the buckets.
HistoryArchiveState has(mCurrentLedger->mHeader.ledgerSeq,
mApp.getBucketManager().getBucketList());
// We almost always want to try to resolve completed merges to single
// buckets, as it makes restarts less fragile: fewer saved/restored shadows,
// fewer buckets for the user to accidentally delete from their buckets
// dir. But we support the option of not-doing so, only for the sake of
// testing. Note: this is nonblocking in any case.
if (!mApp.getConfig().ARTIFICIALLY_PESSIMIZE_MERGES_FOR_TESTING)
{
has.resolveAnyReadyFutures();
}
mApp.getPersistentState().setState(PersistentState::kHistoryArchiveState,
has.toString());
advanceLedgerPointers();
}