3#include <xrpld/overlay/Message.h>
4#include <xrpld/overlay/Peer.h>
36template <
typename Predicate>
59template <
typename Predicate>
71template <
typename Predicate>
94template <
typename Predicate>
95SendIfNotPred<Predicate>
140 if (!peer->cluster())
163 return peerSet.contains(peer->id());
Represents a peer connection in the overlay.
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
SendIfPred< Predicate > sendIf(std::shared_ptr< Message > const &m, Predicate const &f)
Helper function to aid in type deduction.
SendIfNotPred< Predicate > sendIfNot(std::shared_ptr< Message > const &m, Predicate const &f)
Helper function to aid in type deduction.
Select the specific peer.
bool operator()(std::shared_ptr< Peer > const &peer) const
MatchPeer(Peer const *match=nullptr)
bool operator()(std::shared_ptr< Peer > const &peer) const
PeerInCluster(Peer const *skip=nullptr)
bool operator()(std::shared_ptr< Peer > const &peer) const
PeerInSet(std::set< Peer::id_t > const &peers)
std::set< Peer::id_t > const & peerSet
void operator()(std::shared_ptr< Peer > const &peer) const
std::shared_ptr< Message > const & msg
SendAlways(std::shared_ptr< Message > const &m)
Sends a message to non-matching peers.
Predicate const & predicate
std::shared_ptr< Message > const & msg
SendIfNotPred(std::shared_ptr< Message > const &m, Predicate const &p)
void operator()(std::shared_ptr< Peer > const &peer) const
Sends a message to match peers.
void operator()(std::shared_ptr< Peer > const &peer) const
std::shared_ptr< Message > const & msg
Predicate const & predicate
SendIfPred(std::shared_ptr< Message > const &m, Predicate const &p)