xrpld
Loading...
Searching...
No Matches
xrpl::PeerFinder::SlotImp::RecentT Class Reference

#include <SlotImp.h>

Collaboration diagram for xrpl::PeerFinder::SlotImp::RecentT:

Public Member Functions

 RecentT (clock_type &clock)
void insert (beast::IP::Endpoint const &ep, std::uint32_t hops)
 Called for each valid endpoint received for a slot.
bool filter (beast::IP::Endpoint const &ep, std::uint32_t hops)
 Returns true if we should not send endpoint to the slot.

Private Member Functions

void expire ()

Private Attributes

beast::aged_unordered_map< beast::IP::Endpoint, std::uint32_tcache_

Friends

class SlotImp

Detailed Description

Definition at line 128 of file SlotImp.h.

Constructor & Destructor Documentation

◆ RecentT()

xrpl::PeerFinder::SlotImp::RecentT::RecentT ( clock_type & clock)
explicit

Definition at line 100 of file SlotImp.cpp.

Member Function Documentation

◆ insert()

void xrpl::PeerFinder::SlotImp::RecentT::insert ( beast::IP::Endpoint const & ep,
std::uint32_t hops )

Called for each valid endpoint received for a slot.

We also insert messages that we send to the slot to prevent sending a slot the same address too frequently.

Definition at line 105 of file SlotImp.cpp.

◆ filter()

bool xrpl::PeerFinder::SlotImp::RecentT::filter ( beast::IP::Endpoint const & ep,
std::uint32_t hops )

Returns true if we should not send endpoint to the slot.

Definition at line 120 of file SlotImp.cpp.

◆ expire()

void xrpl::PeerFinder::SlotImp::RecentT::expire ( )
private

Definition at line 132 of file SlotImp.cpp.

◆ SlotImp

friend class SlotImp
friend

Definition at line 148 of file SlotImp.h.

Member Data Documentation

◆ cache_

beast::aged_unordered_map<beast::IP::Endpoint, std::uint32_t> xrpl::PeerFinder::SlotImp::RecentT::cache_
private

Definition at line 149 of file SlotImp.h.