/// <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 (Brand != null)
         {
             hashCode = hashCode * 59 + Brand.GetHashCode();
         }
         if (Ingredients != null)
         {
             hashCode = hashCode * 59 + Ingredients.GetHashCode();
         }
         if (Package != null)
         {
             hashCode = hashCode * 59 + Package.GetHashCode();
         }
         if (Serving != null)
         {
             hashCode = hashCode * 59 + Serving.GetHashCode();
         }
         if (Categories != null)
         {
             hashCode = hashCode * 59 + Categories.GetHashCode();
         }
         if (Nutrients != null)
         {
             hashCode = hashCode * 59 + Nutrients.GetHashCode();
         }
         if (DietLabels != null)
         {
             hashCode = hashCode * 59 + DietLabels.GetHashCode();
         }
         if (DietFlags != null)
         {
             hashCode = hashCode * 59 + DietFlags.GetHashCode();
         }
         if (PackagingPhotos != null)
         {
             hashCode = hashCode * 59 + PackagingPhotos.GetHashCode();
         }
         if (Allergens != null)
         {
             hashCode = hashCode * 59 + Allergens.GetHashCode();
         }
         if (BrandList != null)
         {
             hashCode = hashCode * 59 + BrandList.GetHashCode();
         }
         if (Countries != null)
         {
             hashCode = hashCode * 59 + Countries.GetHashCode();
         }
         if (CountryDetails != null)
         {
             hashCode = hashCode * 59 + CountryDetails.GetHashCode();
         }
         if (PalmOilIngredients != null)
         {
             hashCode = hashCode * 59 + PalmOilIngredients.GetHashCode();
         }
         if (IngredientList != null)
         {
             hashCode = hashCode * 59 + IngredientList.GetHashCode();
         }
         if (HasEnglishIngredients != null)
         {
             hashCode = hashCode * 59 + HasEnglishIngredients.GetHashCode();
         }
         if (Minerals != null)
         {
             hashCode = hashCode * 59 + Minerals.GetHashCode();
         }
         if (Traces != null)
         {
             hashCode = hashCode * 59 + Traces.GetHashCode();
         }
         if (Vitamins != null)
         {
             hashCode = hashCode * 59 + Vitamins.GetHashCode();
         }
         if (Description != null)
         {
             hashCode = hashCode * 59 + Description.GetHashCode();
         }
         if (Keywords != null)
         {
             hashCode = hashCode * 59 + Keywords.GetHashCode();
         }
         return(hashCode);
     }
 }
        /// <summary>
        /// Returns true if BrandedFoodObjectItems instances are equal
        /// </summary>
        /// <param name="other">Instance of BrandedFoodObjectItems to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(BrandedFoodObjectItems other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     Barcode == other.Barcode ||
                     Barcode != null &&
                     Barcode.Equals(other.Barcode)
                     ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ) &&
                 (
                     Brand == other.Brand ||
                     Brand != null &&
                     Brand.Equals(other.Brand)
                 ) &&
                 (
                     Ingredients == other.Ingredients ||
                     Ingredients != null &&
                     Ingredients.Equals(other.Ingredients)
                 ) &&
                 (
                     Package == other.Package ||
                     Package != null &&
                     Package.Equals(other.Package)
                 ) &&
                 (
                     Serving == other.Serving ||
                     Serving != null &&
                     Serving.Equals(other.Serving)
                 ) &&
                 (
                     Categories == other.Categories ||
                     Categories != null &&
                     Categories.SequenceEqual(other.Categories)
                 ) &&
                 (
                     Nutrients == other.Nutrients ||
                     Nutrients != null &&
                     Nutrients.SequenceEqual(other.Nutrients)
                 ) &&
                 (
                     DietLabels == other.DietLabels ||
                     DietLabels != null &&
                     DietLabels.Equals(other.DietLabels)
                 ) &&
                 (
                     DietFlags == other.DietFlags ||
                     DietFlags != null &&
                     DietFlags.SequenceEqual(other.DietFlags)
                 ) &&
                 (
                     PackagingPhotos == other.PackagingPhotos ||
                     PackagingPhotos != null &&
                     PackagingPhotos.Equals(other.PackagingPhotos)
                 ) &&
                 (
                     Allergens == other.Allergens ||
                     Allergens != null &&
                     Allergens.SequenceEqual(other.Allergens)
                 ) &&
                 (
                     BrandList == other.BrandList ||
                     BrandList != null &&
                     BrandList.SequenceEqual(other.BrandList)
                 ) &&
                 (
                     Countries == other.Countries ||
                     Countries != null &&
                     Countries.SequenceEqual(other.Countries)
                 ) &&
                 (
                     CountryDetails == other.CountryDetails ||
                     CountryDetails != null &&
                     CountryDetails.Equals(other.CountryDetails)
                 ) &&
                 (
                     PalmOilIngredients == other.PalmOilIngredients ||
                     PalmOilIngredients != null &&
                     PalmOilIngredients.SequenceEqual(other.PalmOilIngredients)
                 ) &&
                 (
                     IngredientList == other.IngredientList ||
                     IngredientList != null &&
                     IngredientList.SequenceEqual(other.IngredientList)
                 ) &&
                 (
                     HasEnglishIngredients == other.HasEnglishIngredients ||
                     HasEnglishIngredients != null &&
                     HasEnglishIngredients.Equals(other.HasEnglishIngredients)
                 ) &&
                 (
                     Minerals == other.Minerals ||
                     Minerals != null &&
                     Minerals.SequenceEqual(other.Minerals)
                 ) &&
                 (
                     Traces == other.Traces ||
                     Traces != null &&
                     Traces.SequenceEqual(other.Traces)
                 ) &&
                 (
                     Vitamins == other.Vitamins ||
                     Vitamins != null &&
                     Vitamins.SequenceEqual(other.Vitamins)
                 ) &&
                 (
                     Description == other.Description ||
                     Description != null &&
                     Description.Equals(other.Description)
                 ) &&
                 (
                     Keywords == other.Keywords ||
                     Keywords != null &&
                     Keywords.SequenceEqual(other.Keywords)
                 ));
        }