rippled
Public Types | Public Member Functions | List of all members
ripple::InboundLedgers Class Referenceabstract

Manages the lifetime of inbound ledgers. More...

Inheritance diagram for ripple::InboundLedgers:
Inheritance graph
[legend]

Public Types

using clock_type = beast::abstract_clock< std::chrono::steady_clock >
 

Public Member Functions

virtual ~InboundLedgers ()=default
 
virtual std::shared_ptr< Ledger const > acquire (uint256 const &hash, std::uint32_t seq, InboundLedger::Reason)=0
 
virtual std::shared_ptr< InboundLedgerfind (LedgerHash const &hash)=0
 
virtual bool gotLedgerData (LedgerHash const &ledgerHash, std::shared_ptr< Peer >, std::shared_ptr< protocol::TMLedgerData >)=0
 
virtual void gotStaleData (std::shared_ptr< protocol::TMLedgerData > packet)=0
 
virtual void logFailure (uint256 const &h, std::uint32_t seq)=0
 
virtual bool isFailure (uint256 const &h)=0
 
virtual void clearFailures ()=0
 
virtual Json::Value getInfo ()=0
 
virtual std::size_t fetchRate ()=0
 Returns the rate of historical ledger fetches per minute. More...
 
virtual void onLedgerFetched ()=0
 Called when a complete ledger is obtained. More...
 
virtual void gotFetchPack ()=0
 
virtual void sweep ()=0
 
virtual void stop ()=0
 

Detailed Description

Manages the lifetime of inbound ledgers.

See also
InboundLedger

Definition at line 33 of file InboundLedgers.h.

Member Typedef Documentation

◆ clock_type

Definition at line 36 of file InboundLedgers.h.

Constructor & Destructor Documentation

◆ ~InboundLedgers()

virtual ripple::InboundLedgers::~InboundLedgers ( )
virtualdefault

Member Function Documentation

◆ acquire()

virtual std::shared_ptr<Ledger const> ripple::InboundLedgers::acquire ( uint256 const &  hash,
std::uint32_t  seq,
InboundLedger::Reason   
)
pure virtual

◆ find()

virtual std::shared_ptr<InboundLedger> ripple::InboundLedgers::find ( LedgerHash const &  hash)
pure virtual

◆ gotLedgerData()

virtual bool ripple::InboundLedgers::gotLedgerData ( LedgerHash const &  ledgerHash,
std::shared_ptr< Peer ,
std::shared_ptr< protocol::TMLedgerData >   
)
pure virtual

◆ gotStaleData()

virtual void ripple::InboundLedgers::gotStaleData ( std::shared_ptr< protocol::TMLedgerData >  packet)
pure virtual

◆ logFailure()

virtual void ripple::InboundLedgers::logFailure ( uint256 const &  h,
std::uint32_t  seq 
)
pure virtual

◆ isFailure()

virtual bool ripple::InboundLedgers::isFailure ( uint256 const &  h)
pure virtual

◆ clearFailures()

virtual void ripple::InboundLedgers::clearFailures ( )
pure virtual

◆ getInfo()

virtual Json::Value ripple::InboundLedgers::getInfo ( )
pure virtual

◆ fetchRate()

virtual std::size_t ripple::InboundLedgers::fetchRate ( )
pure virtual

Returns the rate of historical ledger fetches per minute.

Implemented in ripple::InboundLedgersImp, and ripple::test::MagicInboundLedgers.

◆ onLedgerFetched()

virtual void ripple::InboundLedgers::onLedgerFetched ( )
pure virtual

Called when a complete ledger is obtained.

Implemented in ripple::InboundLedgersImp, and ripple::test::MagicInboundLedgers.

◆ gotFetchPack()

virtual void ripple::InboundLedgers::gotFetchPack ( )
pure virtual

◆ sweep()

virtual void ripple::InboundLedgers::sweep ( )
pure virtual

◆ stop()

virtual void ripple::InboundLedgers::stop ( )
pure virtual