@Override
  public int hashCode() {
    final int prime = 31;
    int result = 1;

    result = prime * result + ((value == null) ? 0 : value.hashCode());
    result = prime * result + ((mask == null) ? 0 : mask.hashCode());
    return result;
  }
  @Override
  public int hashCode() {
    final int prime = 31;
    int result = 1;

    result = prime * result + ((nwAddr == null) ? 0 : nwAddr.hashCode());
    return result;
  }
Example #3
0
File: ARP.java Project: jmdbo/CGR
 @Override
 public int hashCode() {
   final int prime = 31;
   int result = super.hashCode();
   result = prime * result + hardwareAddressLength;
   result = prime * result + hardwareType;
   result = prime * result + ((opCode == null) ? 0 : opCode.hashCode());
   result = prime * result + protocolAddressLength;
   result = prime * result + protocolType;
   result =
       prime * result + ((senderHardwareAddress == null) ? 0 : senderHardwareAddress.hashCode());
   result =
       prime * result + ((senderProtocolAddress == null) ? 0 : senderProtocolAddress.hashCode());
   result =
       prime * result + ((targetHardwareAddress == null) ? 0 : targetHardwareAddress.hashCode());
   result =
       prime * result + ((targetProtocolAddress == null) ? 0 : targetProtocolAddress.hashCode());
   return result;
 }