/// <summary>
 /// Gets the hash code
 /// </summary>
 /// <returns>Hash code</returns>
 public override int GetHashCode()
 {
     unchecked // Overflow is fine, just wrap
     {
         var hashCode = 41;
         // Suitable nullity checks etc, of course :)
         if (FeatureType != null)
         {
             hashCode = hashCode * 59 + FeatureType.GetHashCode();
         }
         if (AdditionalValue != null)
         {
             hashCode = hashCode * 59 + AdditionalValue.GetHashCode();
         }
         return(hashCode);
     }
 }
Пример #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (FeatureName.Length != 0)
            {
                hash ^= FeatureName.GetHashCode();
            }
            if (FeatureType != global::Asgt.Type.FeatureStat.Types.Type.Int)
            {
                hash ^= FeatureType.GetHashCode();
            }
            if (InformationGain != 0F)
            {
                hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(InformationGain);
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }