コード例 #1
0
        public override int GetHashCode()
        {
            int hash = 1;

            hash ^= armament_.GetHashCode();
            if (Class.Length != 0)
            {
                hash ^= Class.GetHashCode();
            }
            hash ^= equipment_.GetHashCode();
            if (Height != 0)
            {
                hash ^= Height.GetHashCode();
            }
            if (Manufacturer.Length != 0)
            {
                hash ^= Manufacturer.GetHashCode();
            }
            if (Model.Length != 0)
            {
                hash ^= Model.GetHashCode();
            }
            hash ^= platingColor_.GetHashCode();
            if (Price != 0)
            {
                hash ^= Price.GetHashCode();
            }
            hash ^= sensorColor_.GetHashCode();
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #2
0
 /// <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 (Barcode != null)
         {
             hashCode = hashCode * 59 + Barcode.GetHashCode();
         }
         if (Name != null)
         {
             hashCode = hashCode * 59 + Name.GetHashCode();
         }
         if (Manufacturer != null)
         {
             hashCode = hashCode * 59 + Manufacturer.GetHashCode();
         }
         if (Images != null)
         {
             hashCode = hashCode * 59 + Images.GetHashCode();
         }
         if (Category != null)
         {
             hashCode = hashCode * 59 + Category.GetHashCode();
         }
         return(hashCode);
     }
 }
コード例 #3
0
 public override int GetHashCode()
 {
     unchecked
     {
         var result = 0;
         result = (result * 397) ^ Manufacturer.GetHashCode();
         result = (result * 397) ^ AlternativeNames.GetHashCode();
         result = (result * 397) ^ Models.GetHashCode();
         return(result);
     }
 }
コード例 #4
0
        public override int GetHashCode()
        {
            // Generated by IntelliJ
            int result = Manufacturer.GetHashCode();

            result = 31 * result + ModelNumber.GetHashCode();
            result = 31 * result + SerialNumber.GetHashCode();
            result = 31 * result + FirmwareRevision.GetHashCode();
            result = 31 * result + HardwareRevision.GetHashCode();

            return(result);
        }
コード例 #5
0
 public override int GetHashCode()
 {
     return(base.GetHashCode() ^
            IsSuccess.GetHashCode() ^
            State.GetHashCode() ^
            Manufacturer.GetHashCode() ^
            ModelName.GetHashCode() ^
            SerialNumber.GetHashCode() ^
            SignalQuality.GetHashCode() ^
            Imsi.GetHashCode() ^
            Imei.GetHashCode() ^
            OperatorName.GetHashCode());
 }
コード例 #6
0
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = Id.GetHashCode();
         hashCode = (hashCode * 397) ^ (Manufacturer?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Model?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (Description?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ PurchasePrice.GetHashCode();
         hashCode = (hashCode * 397) ^ PurchaseDate.GetHashCode();
         return(hashCode);
     }
 }
コード例 #7
0
ファイル: DeviceInfo.cs プロジェクト: wpscott/AcFunDanmaku
        public override int GetHashCode()
        {
            int hash = 1;

            if (PlatformType != global::AcFunDanmu.DeviceInfo.Types.PlatformType.KInvalid)
            {
                hash ^= PlatformType.GetHashCode();
            }
            if (OsVersion.Length != 0)
            {
                hash ^= OsVersion.GetHashCode();
            }
            if (DeviceModel.Length != 0)
            {
                hash ^= DeviceModel.GetHashCode();
            }
            if (ImeiMd5.Length != 0)
            {
                hash ^= ImeiMd5.GetHashCode();
            }
            if (DeviceId.Length != 0)
            {
                hash ^= DeviceId.GetHashCode();
            }
            if (SoftDid.Length != 0)
            {
                hash ^= SoftDid.GetHashCode();
            }
            if (KwaiDid.Length != 0)
            {
                hash ^= KwaiDid.GetHashCode();
            }
            if (Manufacturer.Length != 0)
            {
                hash ^= Manufacturer.GetHashCode();
            }
            if (DeviceName.Length != 0)
            {
                hash ^= DeviceName.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
コード例 #8
0
ファイル: Info.cs プロジェクト: valerybokov/MyAutoruns
        public override int GetHashCode()
        {
            var hashCode = 304851041;

            if (Manufacturer == null)
            {
                hashCode = hashCode * -1521134295;
            }
            else
            {
                hashCode = hashCode * -1521134295 + Manufacturer.GetHashCode();
            }

            if (CmdArguments == null)
            {
                hashCode = hashCode * -1521134295;
            }
            else
            {
                hashCode = hashCode * -1521134295 + CmdArguments.GetHashCode();
            }

            return(hashCode * -1521134295 + FileName.GetHashCode());
        }
コード例 #9
0
        /// <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 (Upc != null)
                {
                    hashCode = hashCode * 59 + Upc.GetHashCode();
                }
                if (Ean != null)
                {
                    hashCode = hashCode * 59 + Ean.GetHashCode();
                }
                if (Isbn != null)
                {
                    hashCode = hashCode * 59 + Isbn.GetHashCode();
                }
                if (Asin != null)
                {
                    hashCode = hashCode * 59 + Asin.GetHashCode();
                }
                if (Title != null)
                {
                    hashCode = hashCode * 59 + Title.GetHashCode();
                }
                if (Sku != null)
                {
                    hashCode = hashCode * 59 + Sku.GetHashCode();
                }
                if (Mpn != null)
                {
                    hashCode = hashCode * 59 + Mpn.GetHashCode();
                }
                if (PartNumber != null)
                {
                    hashCode = hashCode * 59 + PartNumber.GetHashCode();
                }
                if (Upcs != null)
                {
                    hashCode = hashCode * 59 + Upcs.GetHashCode();
                }
                if (Description != null)
                {
                    hashCode = hashCode * 59 + Description.GetHashCode();
                }
                if (Brand != null)
                {
                    hashCode = hashCode * 59 + Brand.GetHashCode();
                }
                if (Manufacturer != null)
                {
                    hashCode = hashCode * 59 + Manufacturer.GetHashCode();
                }
                if (Color != null)
                {
                    hashCode = hashCode * 59 + Color.GetHashCode();
                }

                hashCode = hashCode * 59 + NewPrice.GetHashCode();

                hashCode = hashCode * 59 + UsedPrice.GetHashCode();
                if (CurrencyCode != null)
                {
                    hashCode = hashCode * 59 + CurrencyCode.GetHashCode();
                }
                if (Url != null)
                {
                    hashCode = hashCode * 59 + Url.GetHashCode();
                }
                if (Features != null)
                {
                    hashCode = hashCode * 59 + Features.GetHashCode();
                }
                if (Dimensions != null)
                {
                    hashCode = hashCode * 59 + Dimensions.GetHashCode();
                }
                if (Images != null)
                {
                    hashCode = hashCode * 59 + Images.GetHashCode();
                }
                if (MatchedItems != null)
                {
                    hashCode = hashCode * 59 + MatchedItems.GetHashCode();
                }
                if (IsoCountryCodes != null)
                {
                    hashCode = hashCode * 59 + IsoCountryCodes.GetHashCode();
                }
                if (CompanyName != null)
                {
                    hashCode = hashCode * 59 + CompanyName.GetHashCode();
                }
                if (CompanyAddress != null)
                {
                    hashCode = hashCode * 59 + CompanyAddress.GetHashCode();
                }
                if (Categories != null)
                {
                    hashCode = hashCode * 59 + Categories.GetHashCode();
                }
                if (CategoryHierarchies != null)
                {
                    hashCode = hashCode * 59 + CategoryHierarchies.GetHashCode();
                }
                return(hashCode);
            }
        }
コード例 #10
0
 public override int GetHashCode()
 {
     return(Manufacturer.GetHashCode() ^ Model.GetHashCode());
 }