Пример #1
0
 /// <summary>
 /// ICMP layers are equal if they have the same message type, code, checksum, variable and payload.
 /// </summary>
 public bool Equals(IcmpLayer other)
 {
     return(other != null &&
            MessageType == other.MessageType && CodeValue == other.CodeValue &&
            Checksum == other.Checksum &&
            Variable == other.Variable &&
            EqualPayload(other));
 }
Пример #2
0
 /// <summary>
 /// True iff the ICMP payload is equal to the other ICMP payload.
 /// </summary>
 protected virtual bool EqualPayload(IcmpLayer other)
 {
     return(true);
 }
Пример #3
0
 /// <summary>
 /// True iff the OriginateTimestamp, ReceiveTimestamp and the TransmitTimestamp fields are equal.
 /// </summary>
 protected sealed override bool EqualPayload(IcmpLayer other)
 {
     return(EqualPayload(other as IcmpTimestampLayer));
 }
Пример #4
0
 /// <summary>
 /// True iff the address mask is equal to the other address mask.
 /// </summary>
 protected sealed override bool EqualPayload(IcmpLayer other)
 {
     return(EqualPayload(other as IcmpAddressMaskRequestLayer));
 }
 /// <summary>
 /// True iff the Entries are equal to the other ICMP entries.
 /// </summary>
 protected override bool EqualPayload(IcmpLayer other)
 {
     return(EqualPayload(other as IcmpRouterAdvertisementLayer));
 }