|
rippled
|
Trust graph. More...

Classes | |
| struct | ForkInfo |
| An example of nodes that fail the whitepaper no-forking condition. More... | |
Public Member Functions | |
| TrustGraph ()=default | |
| Create an empty trust graph. More... | |
| Graph const & | graph () |
| void | trust (Peer const &from, Peer const &to) |
| Create trust. More... | |
| void | untrust (Peer const &from, Peer const &to) |
| Remove trust. More... | |
| bool | trusts (Peer const &from, Peer const &to) const |
| auto | trustedPeers (Peer const &a) const |
| Range over trusted peers. More... | |
| std::vector< ForkInfo > | forkablePairs (double quorum) const |
| bool | canFork (double quorum) const |
| Check whether this trust graph satisfies the whitepaper no-forking condition. More... | |
Private Types | |
| using | Graph = Digraph< Peer > |
Private Attributes | |
| Graph | graph_ |
Trust graph.
Trust is a directed relationship from a node i to node j. If node i trusts node j, then node i has node j in its UNL. This class wraps a digraph representing the trust relationships for all peers in the simulation.
Definition at line 43 of file TrustGraph.h.
|
private |
Definition at line 45 of file TrustGraph.h.
|
default |
Create an empty trust graph.
| Graph const& ripple::test::csf::TrustGraph< Peer >::graph | ( | ) |
Definition at line 55 of file TrustGraph.h.
| void ripple::test::csf::TrustGraph< Peer >::trust | ( | Peer const & | from, |
| Peer const & | to | ||
| ) |
Create trust.
Establish trust between Peer from and Peer to; as if from put to in its UNL.
| from | The peer granting trust |
| to | The peer receiving trust |
Definition at line 70 of file TrustGraph.h.
| void ripple::test::csf::TrustGraph< Peer >::untrust | ( | Peer const & | from, |
| Peer const & | to | ||
| ) |
Remove trust.
Revoke trust from Peer from to Peer to; as if from removed to from its UNL.
| from | The peer revoking trust |
| to | The peer being revoked |
Definition at line 84 of file TrustGraph.h.
| bool ripple::test::csf::TrustGraph< Peer >::trusts | ( | Peer const & | from, |
| Peer const & | to | ||
| ) | const |
Definition at line 91 of file TrustGraph.h.
| auto ripple::test::csf::TrustGraph< Peer >::trustedPeers | ( | Peer const & | a | ) | const |
Range over trusted peers.
| a | The node granting trust |
a trusts, i.e. the nodes in its UNL Definition at line 103 of file TrustGraph.h.
| std::vector<ForkInfo> ripple::test::csf::TrustGraph< Peer >::forkablePairs | ( | double | quorum | ) | const |
Definition at line 120 of file TrustGraph.h.
| bool ripple::test::csf::TrustGraph< Peer >::canFork | ( | double | quorum | ) | const |
Check whether this trust graph satisfies the whitepaper no-forking condition.
Definition at line 167 of file TrustGraph.h.
|
private |
Definition at line 47 of file TrustGraph.h.
1.8.17