Exemple #1
0
        public override bool Equals(object obj)
        {
            var m = obj as Member;

            if (m == null)
            {
                return(false);
            }
            return(_uniqueAddress.Equals(m.UniqueAddress));
        }
Exemple #2
0
            /// <inheritdoc/>
            public override bool Equals(object obj)
            {
                var other = obj as Record;

                if (other == null)
                {
                    return(false);
                }
                return(_version.Equals(other._version) &&
                       _status == other.Status &&
                       _observer.Equals(other._observer) &&
                       _subject.Equals(other._subject));
            }
Exemple #3
0
 /// <inheritdoc/>
 protected bool Equals(GossipStatus other)
 {
     return(_from.Equals(other._from) && _version.IsSameAs(other._version));
 }
Exemple #4
0
 /// <summary>
 /// Never gossip to self and not to node marked as unreachable by self (heartbeat
 /// messages are not getting through so no point in trying to gossip).
 ///
 ///  Nodes marked as unreachable by others are still valid targets for gossip.
 /// </summary>
 /// <param name="node">The node to check for gossip validity.</param>
 /// <returns><c>true</c> if we can gossip to this node, <c>false</c> otherwise.</returns>
 public bool ValidNodeForGossip(UniqueAddress node)
 {
     return(!node.Equals(SelfUniqueAddress) && Overview.Reachability.IsReachable(SelfUniqueAddress, node));
 }