|
rippled
|
An entry in the routing table. More...


Public Member Functions | |
| Entry () | |
| void | addPeer (PeerShortID peer) |
| int | getFlags (void) const |
| void | setFlags (int flagsToSet) |
| std::set< PeerShortID > | releasePeerSet () |
| Return set of peers we've relayed to and reset tracking. More... | |
| std::optional< Stopwatch::time_point > | relayed () const |
| Return seated relay time point if the message has been relayed. More... | |
| bool | shouldRelay (Stopwatch::time_point const &now, std::chrono::seconds relayTime) |
| Determines if this item should be relayed. More... | |
| bool | shouldProcess (Stopwatch::time_point now, std::chrono::seconds interval) |
Static Private Member Functions | |
| static auto & | getCounter () noexcept |
Private Attributes | |
| int | flags_ = 0 |
| std::set< PeerShortID > | peers_ |
| std::optional< Stopwatch::time_point > | relayed_ |
| std::optional< Stopwatch::time_point > | processed_ |
An entry in the routing table.
Definition at line 90 of file HashRouter.h.
| ripple::HashRouter::Entry::Entry | ( | ) |
Definition at line 93 of file HashRouter.h.
| void ripple::HashRouter::Entry::addPeer | ( | PeerShortID | peer | ) |
Definition at line 98 of file HashRouter.h.
| int ripple::HashRouter::Entry::getFlags | ( | void | ) | const |
Definition at line 105 of file HashRouter.h.
| void ripple::HashRouter::Entry::setFlags | ( | int | flagsToSet | ) |
Definition at line 111 of file HashRouter.h.
| std::set< PeerShortID > ripple::HashRouter::Entry::releasePeerSet | ( | ) |
Return set of peers we've relayed to and reset tracking.
Definition at line 118 of file HashRouter.h.
| std::optional< Stopwatch::time_point > ripple::HashRouter::Entry::relayed | ( | ) | const |
Return seated relay time point if the message has been relayed.
Definition at line 125 of file HashRouter.h.
| bool ripple::HashRouter::Entry::shouldRelay | ( | Stopwatch::time_point const & | now, |
| std::chrono::seconds | relayTime | ||
| ) |
Determines if this item should be relayed.
Checks whether the item has been recently relayed. If it has, return false. If it has not, update the last relay timestamp and return true.
Definition at line 137 of file HashRouter.h.
| bool ripple::HashRouter::Entry::shouldProcess | ( | Stopwatch::time_point | now, |
| std::chrono::seconds | interval | ||
| ) |
Definition at line 148 of file HashRouter.h.
|
staticprivatenoexceptinherited |
Definition at line 129 of file CountedObject.h.
|
private |
Definition at line 157 of file HashRouter.h.
|
private |
Definition at line 158 of file HashRouter.h.
|
private |
Definition at line 161 of file HashRouter.h.
|
private |
Definition at line 162 of file HashRouter.h.