rippled
BuildLedger.h
1 //------------------------------------------------------------------------------
2 /*
3  This file is part of rippled: https://github.com/ripple/rippled
4  Copyright (c) 2018 Ripple Labs Inc.
5 
6  Permission to use, copy, modify, and/or distribute this software for any
7  purpose with or without fee is hereby granted, provided that the above
8  copyright notice and this permission notice appear in all copies.
9 
10  THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11  WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12  MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13  ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14  WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15  ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16  OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 */
18 //==============================================================================
19 
20 #ifndef RIPPLE_APP_LEDGER_BUILD_LEDGER_H_INCLUDED
21 #define RIPPLE_APP_LEDGER_BUILD_LEDGER_H_INCLUDED
22 
23 #include <ripple/basics/chrono.h>
24 #include <ripple/beast/utility/Journal.h>
25 #include <ripple/ledger/ApplyView.h>
26 #include <chrono>
27 #include <memory>
28 
29 namespace ripple {
30 
31 class Application;
32 class CanonicalTXSet;
33 class Ledger;
34 class LedgerReplay;
35 class SHAMap;
36 
55  std::shared_ptr<Ledger const> const& parent,
56  NetClock::time_point closeTime,
57  const bool closeTimeCorrect,
58  NetClock::duration closeResolution,
59  Application& app,
60  CanonicalTXSet& txns,
61  std::set<TxID>& failedTxs,
62  beast::Journal j);
63 
76  LedgerReplay const& replayData,
77  ApplyFlags applyFlags,
78  Application& app,
79  beast::Journal j);
80 
81 } // namespace ripple
82 #endif
std::shared_ptr< Ledger >
ripple::ApplyFlags
ApplyFlags
Definition: ApplyView.h:29
ripple::ProtocolFeature::LedgerReplay
@ LedgerReplay
chrono
beast::Journal
A generic endpoint for log messages.
Definition: Journal.h:58
memory
ripple
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
Definition: RCLCensorshipDetector.h:29
ripple::buildLedger
std::shared_ptr< Ledger > buildLedger(std::shared_ptr< Ledger const > const &parent, NetClock::time_point closeTime, const bool closeTimeCorrect, NetClock::duration closeResolution, Application &app, CanonicalTXSet &txns, std::set< TxID > &failedTxs, beast::Journal j)
Build a new ledger by applying consensus transactions.
Definition: BuildLedger.cpp:178
ripple::NetClock::duration
std::chrono::duration< rep, period > duration
Definition: chrono.h:55
ripple::NetClock::time_point
std::chrono::time_point< NetClock > time_point
Definition: chrono.h:56
std::set
STL class.