Beispiel #1
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 (AssetNumber != null)
         {
             hashCode = hashCode * 59 + AssetNumber.GetHashCode();
         }
         if (SubNumber != null)
         {
             hashCode = hashCode * 59 + SubNumber.GetHashCode();
         }
         if (CompanyCode != null)
         {
             hashCode = hashCode * 59 + CompanyCode.GetHashCode();
         }
         if (Status != null)
         {
             hashCode = hashCode * 59 + Status.GetHashCode();
         }
         if (Checked != null)
         {
             hashCode = hashCode * 59 + Checked.GetHashCode();
         }
         return(hashCode);
     }
 }
Beispiel #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 (InventoryVariantName != null)
         {
             hashCode = hashCode * 59 + InventoryVariantName.GetHashCode();
         }
         if (TagId != null)
         {
             hashCode = hashCode * 59 + TagId.GetHashCode();
         }
         if (AssetNumber != null)
         {
             hashCode = hashCode * 59 + AssetNumber.GetHashCode();
         }
         if (SubNumber != null)
         {
             hashCode = hashCode * 59 + SubNumber.GetHashCode();
         }
         if (CompanyCode != null)
         {
             hashCode = hashCode * 59 + CompanyCode.GetHashCode();
         }
         if (Description != null)
         {
             hashCode = hashCode * 59 + Description.GetHashCode();
         }
         return(hashCode);
     }
 }
        /// <summary>
        /// Returns true if InventoryOrderAssetPutResource instances are equal
        /// </summary>
        /// <param name="other">Instance of InventoryOrderAssetPutResource to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(InventoryOrderAssetPutResource other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                     ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ) &&
                 (
                     Status == other.Status ||
                     Status != null &&
                     Status.Equals(other.Status)
                 ) &&
                 (
                     Checked == other.Checked ||
                     Checked != null &&
                     Checked.Equals(other.Checked)
                 ) &&
                 (
                     CommentCostCenter == other.CommentCostCenter ||
                     CommentCostCenter != null &&
                     CommentCostCenter.Equals(other.CommentCostCenter)
                 ) &&
                 (
                     CommentLocation == other.CommentLocation ||
                     CommentLocation != null &&
                     CommentLocation.Equals(other.CommentLocation)
                 ) &&
                 (
                     CommentOther == other.CommentOther ||
                     CommentOther != null &&
                     CommentOther.Equals(other.CommentOther)
                 ) &&
                 (
                     CommentPlant == other.CommentPlant ||
                     CommentPlant != null &&
                     CommentPlant.Equals(other.CommentPlant)
                 ));
        }
Beispiel #4
0
        /// <summary>
        /// Returns true if TagSearchAsset instances are equal
        /// </summary>
        /// <param name="other">Instance of TagSearchAsset to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(TagSearchAsset other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     InventoryVariantName == other.InventoryVariantName ||
                     InventoryVariantName != null &&
                     InventoryVariantName.Equals(other.InventoryVariantName)
                     ) &&
                 (
                     TagId == other.TagId ||
                     TagId != null &&
                     TagId.Equals(other.TagId)
                 ) &&
                 (
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                 ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ) &&
                 (
                     Description == other.Description ||
                     Description != null &&
                     Description.Equals(other.Description)
                 ));
        }
Beispiel #5
0
        /// <summary>
        /// Returns true if InventoryOrderAssetStatusPutResource instances are equal
        /// </summary>
        /// <param name="other">Instance of InventoryOrderAssetStatusPutResource to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(InventoryOrderAssetStatusPutResource other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                     ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ) &&
                 (
                     Status == other.Status ||
                     Status != null &&
                     Status.Equals(other.Status)
                 ) &&
                 (
                     Checked == other.Checked ||
                     Checked != null &&
                     Checked.Equals(other.Checked)
                 ));
        }
 /// <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 (SearchString != null)
         {
             hashCode = hashCode * 59 + SearchString.GetHashCode();
         }
         if (SortingColumn != null)
         {
             hashCode = hashCode * 59 + SortingColumn.GetHashCode();
         }
         if (TagId != null)
         {
             hashCode = hashCode * 59 + TagId.GetHashCode();
         }
         if (Name != null)
         {
             hashCode = hashCode * 59 + Name.GetHashCode();
         }
         if (AssetNumber != null)
         {
             hashCode = hashCode * 59 + AssetNumber.GetHashCode();
         }
         if (Latitude != null)
         {
             hashCode = hashCode * 59 + Latitude.GetHashCode();
         }
         if (Longitude != null)
         {
             hashCode = hashCode * 59 + Longitude.GetHashCode();
         }
         if (AssetClass != null)
         {
             hashCode = hashCode * 59 + AssetClass.GetHashCode();
         }
         if (LastModified != null)
         {
             hashCode = hashCode * 59 + LastModified.GetHashCode();
         }
         if (Created != null)
         {
             hashCode = hashCode * 59 + Created.GetHashCode();
         }
         if (Creator != null)
         {
             hashCode = hashCode * 59 + Creator.GetHashCode();
         }
         if (SubNumber != null)
         {
             hashCode = hashCode * 59 + SubNumber.GetHashCode();
         }
         if (CompanyCode != null)
         {
             hashCode = hashCode * 59 + CompanyCode.GetHashCode();
         }
         if (InventoryNumber != null)
         {
             hashCode = hashCode * 59 + InventoryNumber.GetHashCode();
         }
         if (SerialNumber != null)
         {
             hashCode = hashCode * 59 + SerialNumber.GetHashCode();
         }
         if (Location != null)
         {
             hashCode = hashCode * 59 + Location.GetHashCode();
         }
         if (Room != null)
         {
             hashCode = hashCode * 59 + Room.GetHashCode();
         }
         if (CostCenter != null)
         {
             hashCode = hashCode * 59 + CostCenter.GetHashCode();
         }
         if (CapitalisationDate != null)
         {
             hashCode = hashCode * 59 + CapitalisationDate.GetHashCode();
         }
         if (LastInventoryDate != null)
         {
             hashCode = hashCode * 59 + LastInventoryDate.GetHashCode();
         }
         if (AcquisitionValue != null)
         {
             hashCode = hashCode * 59 + AcquisitionValue.GetHashCode();
         }
         if (AssetSuperNumber != null)
         {
             hashCode = hashCode * 59 + AssetSuperNumber.GetHashCode();
         }
         if (Vendor != null)
         {
             hashCode = hashCode * 59 + Vendor.GetHashCode();
         }
         if (TypeName != null)
         {
             hashCode = hashCode * 59 + TypeName.GetHashCode();
         }
         if (Plant != null)
         {
             hashCode = hashCode * 59 + Plant.GetHashCode();
         }
         if (Quantity != null)
         {
             hashCode = hashCode * 59 + Quantity.GetHashCode();
         }
         if (Unit != null)
         {
             hashCode = hashCode * 59 + Unit.GetHashCode();
         }
         if (Untaggable != null)
         {
             hashCode = hashCode * 59 + Untaggable.GetHashCode();
         }
         if (Untagged != null)
         {
             hashCode = hashCode * 59 + Untagged.GetHashCode();
         }
         if (Page != null)
         {
             hashCode = hashCode * 59 + Page.GetHashCode();
         }
         if (PageSize != null)
         {
             hashCode = hashCode * 59 + PageSize.GetHashCode();
         }
         return(hashCode);
     }
 }
        /// <summary>
        /// Returns true if AssetFullTextAndPropertySearch instances are equal
        /// </summary>
        /// <param name="other">Instance of AssetFullTextAndPropertySearch to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(AssetFullTextAndPropertySearch other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     SearchString == other.SearchString ||
                     SearchString != null &&
                     SearchString.Equals(other.SearchString)
                     ) &&
                 (
                     SortingColumn == other.SortingColumn ||
                     SortingColumn != null &&
                     SortingColumn.Equals(other.SortingColumn)
                 ) &&
                 (
                     TagId == other.TagId ||
                     TagId != null &&
                     TagId.Equals(other.TagId)
                 ) &&
                 (
                     Name == other.Name ||
                     Name != null &&
                     Name.Equals(other.Name)
                 ) &&
                 (
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                 ) &&
                 (
                     Latitude == other.Latitude ||
                     Latitude != null &&
                     Latitude.Equals(other.Latitude)
                 ) &&
                 (
                     Longitude == other.Longitude ||
                     Longitude != null &&
                     Longitude.Equals(other.Longitude)
                 ) &&
                 (
                     AssetClass == other.AssetClass ||
                     AssetClass != null &&
                     AssetClass.Equals(other.AssetClass)
                 ) &&
                 (
                     LastModified == other.LastModified ||
                     LastModified != null &&
                     LastModified.Equals(other.LastModified)
                 ) &&
                 (
                     Created == other.Created ||
                     Created != null &&
                     Created.Equals(other.Created)
                 ) &&
                 (
                     Creator == other.Creator ||
                     Creator != null &&
                     Creator.Equals(other.Creator)
                 ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ) &&
                 (
                     InventoryNumber == other.InventoryNumber ||
                     InventoryNumber != null &&
                     InventoryNumber.Equals(other.InventoryNumber)
                 ) &&
                 (
                     SerialNumber == other.SerialNumber ||
                     SerialNumber != null &&
                     SerialNumber.Equals(other.SerialNumber)
                 ) &&
                 (
                     Location == other.Location ||
                     Location != null &&
                     Location.Equals(other.Location)
                 ) &&
                 (
                     Room == other.Room ||
                     Room != null &&
                     Room.Equals(other.Room)
                 ) &&
                 (
                     CostCenter == other.CostCenter ||
                     CostCenter != null &&
                     CostCenter.Equals(other.CostCenter)
                 ) &&
                 (
                     CapitalisationDate == other.CapitalisationDate ||
                     CapitalisationDate != null &&
                     CapitalisationDate.Equals(other.CapitalisationDate)
                 ) &&
                 (
                     LastInventoryDate == other.LastInventoryDate ||
                     LastInventoryDate != null &&
                     LastInventoryDate.Equals(other.LastInventoryDate)
                 ) &&
                 (
                     AcquisitionValue == other.AcquisitionValue ||
                     AcquisitionValue != null &&
                     AcquisitionValue.Equals(other.AcquisitionValue)
                 ) &&
                 (
                     AssetSuperNumber == other.AssetSuperNumber ||
                     AssetSuperNumber != null &&
                     AssetSuperNumber.Equals(other.AssetSuperNumber)
                 ) &&
                 (
                     Vendor == other.Vendor ||
                     Vendor != null &&
                     Vendor.Equals(other.Vendor)
                 ) &&
                 (
                     TypeName == other.TypeName ||
                     TypeName != null &&
                     TypeName.Equals(other.TypeName)
                 ) &&
                 (
                     Plant == other.Plant ||
                     Plant != null &&
                     Plant.Equals(other.Plant)
                 ) &&
                 (
                     Quantity == other.Quantity ||
                     Quantity != null &&
                     Quantity.Equals(other.Quantity)
                 ) &&
                 (
                     Unit == other.Unit ||
                     Unit != null &&
                     Unit.Equals(other.Unit)
                 ) &&
                 (
                     Untaggable == other.Untaggable ||
                     Untaggable != null &&
                     Untaggable.Equals(other.Untaggable)
                 ) &&
                 (
                     Untagged == other.Untagged ||
                     Untagged != null &&
                     Untagged.Equals(other.Untagged)
                 ) &&
                 (
                     Page == other.Page ||
                     Page != null &&
                     Page.Equals(other.Page)
                 ) &&
                 (
                     PageSize == other.PageSize ||
                     PageSize != null &&
                     PageSize.Equals(other.PageSize)
                 ));
        }
 /// <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 (InventoryOrderId != null)
         {
             hashCode = hashCode * 59 + InventoryOrderId.GetHashCode();
         }
         if (Checked != null)
         {
             hashCode = hashCode * 59 + Checked.GetHashCode();
         }
         if (LastModified != null)
         {
             hashCode = hashCode * 59 + LastModified.GetHashCode();
         }
         if (Created != null)
         {
             hashCode = hashCode * 59 + Created.GetHashCode();
         }
         if (ChangedBy != null)
         {
             hashCode = hashCode * 59 + ChangedBy.GetHashCode();
         }
         if (CommentOther != null)
         {
             hashCode = hashCode * 59 + CommentOther.GetHashCode();
         }
         if (CommentCostCenter != null)
         {
             hashCode = hashCode * 59 + CommentCostCenter.GetHashCode();
         }
         if (CommentPlant != null)
         {
             hashCode = hashCode * 59 + CommentPlant.GetHashCode();
         }
         if (CommentLocation != null)
         {
             hashCode = hashCode * 59 + CommentLocation.GetHashCode();
         }
         if (Status != null)
         {
             hashCode = hashCode * 59 + Status.GetHashCode();
         }
         if (Asset != null)
         {
             hashCode = hashCode * 59 + Asset.GetHashCode();
         }
         if (AssetNumber != null)
         {
             hashCode = hashCode * 59 + AssetNumber.GetHashCode();
         }
         if (SubNumber != null)
         {
             hashCode = hashCode * 59 + SubNumber.GetHashCode();
         }
         if (CompanyCode != null)
         {
             hashCode = hashCode * 59 + CompanyCode.GetHashCode();
         }
         return(hashCode);
     }
 }
        /// <summary>
        /// Returns true if InventoryOrderAsset instances are equal
        /// </summary>
        /// <param name="other">Instance of InventoryOrderAsset to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(InventoryOrderAsset other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     InventoryOrderId == other.InventoryOrderId ||
                     InventoryOrderId != null &&
                     InventoryOrderId.Equals(other.InventoryOrderId)
                     ) &&
                 (
                     Checked == other.Checked ||
                     Checked != null &&
                     Checked.Equals(other.Checked)
                 ) &&
                 (
                     LastModified == other.LastModified ||
                     LastModified != null &&
                     LastModified.Equals(other.LastModified)
                 ) &&
                 (
                     Created == other.Created ||
                     Created != null &&
                     Created.Equals(other.Created)
                 ) &&
                 (
                     ChangedBy == other.ChangedBy ||
                     ChangedBy != null &&
                     ChangedBy.Equals(other.ChangedBy)
                 ) &&
                 (
                     CommentOther == other.CommentOther ||
                     CommentOther != null &&
                     CommentOther.Equals(other.CommentOther)
                 ) &&
                 (
                     CommentCostCenter == other.CommentCostCenter ||
                     CommentCostCenter != null &&
                     CommentCostCenter.Equals(other.CommentCostCenter)
                 ) &&
                 (
                     CommentPlant == other.CommentPlant ||
                     CommentPlant != null &&
                     CommentPlant.Equals(other.CommentPlant)
                 ) &&
                 (
                     CommentLocation == other.CommentLocation ||
                     CommentLocation != null &&
                     CommentLocation.Equals(other.CommentLocation)
                 ) &&
                 (
                     Status == other.Status ||
                     Status != null &&
                     Status.Equals(other.Status)
                 ) &&
                 (
                     Asset == other.Asset ||
                     Asset != null &&
                     Asset.Equals(other.Asset)
                 ) &&
                 (
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                 ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ));
        }
 /// <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 (InventoryNumber != null)
         {
             hashCode = hashCode * 59 + InventoryNumber.GetHashCode();
         }
         if (SerialNumber != null)
         {
             hashCode = hashCode * 59 + SerialNumber.GetHashCode();
         }
         if (Location != null)
         {
             hashCode = hashCode * 59 + Location.GetHashCode();
         }
         if (Room != null)
         {
             hashCode = hashCode * 59 + Room.GetHashCode();
         }
         if (Description != null)
         {
             hashCode = hashCode * 59 + Description.GetHashCode();
         }
         if (CostCenter != null)
         {
             hashCode = hashCode * 59 + CostCenter.GetHashCode();
         }
         if (CapitalisationDate != null)
         {
             hashCode = hashCode * 59 + CapitalisationDate.GetHashCode();
         }
         if (LastInventoryDate != null)
         {
             hashCode = hashCode * 59 + LastInventoryDate.GetHashCode();
         }
         if (AcquisitionValue != null)
         {
             hashCode = hashCode * 59 + AcquisitionValue.GetHashCode();
         }
         if (AssetSuperNumber != null)
         {
             hashCode = hashCode * 59 + AssetSuperNumber.GetHashCode();
         }
         if (Vendor != null)
         {
             hashCode = hashCode * 59 + Vendor.GetHashCode();
         }
         if (TypeName != null)
         {
             hashCode = hashCode * 59 + TypeName.GetHashCode();
         }
         if (Plant != null)
         {
             hashCode = hashCode * 59 + Plant.GetHashCode();
         }
         if (AssetClass != null)
         {
             hashCode = hashCode * 59 + AssetClass.GetHashCode();
         }
         if (Quantity != null)
         {
             hashCode = hashCode * 59 + Quantity.GetHashCode();
         }
         if (Unit != null)
         {
             hashCode = hashCode * 59 + Unit.GetHashCode();
         }
         if (DeactivatedOn != null)
         {
             hashCode = hashCode * 59 + DeactivatedOn.GetHashCode();
         }
         if (IsDeactivated != null)
         {
             hashCode = hashCode * 59 + IsDeactivated.GetHashCode();
         }
         if (CompanyCodeCurrency != null)
         {
             hashCode = hashCode * 59 + CompanyCodeCurrency.GetHashCode();
         }
         if (AssetNumber != null)
         {
             hashCode = hashCode * 59 + AssetNumber.GetHashCode();
         }
         if (SubNumber != null)
         {
             hashCode = hashCode * 59 + SubNumber.GetHashCode();
         }
         if (CompanyCode != null)
         {
             hashCode = hashCode * 59 + CompanyCode.GetHashCode();
         }
         return(hashCode);
     }
 }
        /// <summary>
        /// Returns true if SapInventoryAsset instances are equal
        /// </summary>
        /// <param name="other">Instance of SapInventoryAsset to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(SapInventoryAsset other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     InventoryNumber == other.InventoryNumber ||
                     InventoryNumber != null &&
                     InventoryNumber.Equals(other.InventoryNumber)
                     ) &&
                 (
                     SerialNumber == other.SerialNumber ||
                     SerialNumber != null &&
                     SerialNumber.Equals(other.SerialNumber)
                 ) &&
                 (
                     Location == other.Location ||
                     Location != null &&
                     Location.Equals(other.Location)
                 ) &&
                 (
                     Room == other.Room ||
                     Room != null &&
                     Room.Equals(other.Room)
                 ) &&
                 (
                     Description == other.Description ||
                     Description != null &&
                     Description.Equals(other.Description)
                 ) &&
                 (
                     CostCenter == other.CostCenter ||
                     CostCenter != null &&
                     CostCenter.Equals(other.CostCenter)
                 ) &&
                 (
                     CapitalisationDate == other.CapitalisationDate ||
                     CapitalisationDate != null &&
                     CapitalisationDate.Equals(other.CapitalisationDate)
                 ) &&
                 (
                     LastInventoryDate == other.LastInventoryDate ||
                     LastInventoryDate != null &&
                     LastInventoryDate.Equals(other.LastInventoryDate)
                 ) &&
                 (
                     AcquisitionValue == other.AcquisitionValue ||
                     AcquisitionValue != null &&
                     AcquisitionValue.Equals(other.AcquisitionValue)
                 ) &&
                 (
                     AssetSuperNumber == other.AssetSuperNumber ||
                     AssetSuperNumber != null &&
                     AssetSuperNumber.Equals(other.AssetSuperNumber)
                 ) &&
                 (
                     Vendor == other.Vendor ||
                     Vendor != null &&
                     Vendor.Equals(other.Vendor)
                 ) &&
                 (
                     TypeName == other.TypeName ||
                     TypeName != null &&
                     TypeName.Equals(other.TypeName)
                 ) &&
                 (
                     Plant == other.Plant ||
                     Plant != null &&
                     Plant.Equals(other.Plant)
                 ) &&
                 (
                     AssetClass == other.AssetClass ||
                     AssetClass != null &&
                     AssetClass.Equals(other.AssetClass)
                 ) &&
                 (
                     Quantity == other.Quantity ||
                     Quantity != null &&
                     Quantity.Equals(other.Quantity)
                 ) &&
                 (
                     Unit == other.Unit ||
                     Unit != null &&
                     Unit.Equals(other.Unit)
                 ) &&
                 (
                     DeactivatedOn == other.DeactivatedOn ||
                     DeactivatedOn != null &&
                     DeactivatedOn.Equals(other.DeactivatedOn)
                 ) &&
                 (
                     IsDeactivated == other.IsDeactivated ||
                     IsDeactivated != null &&
                     IsDeactivated.Equals(other.IsDeactivated)
                 ) &&
                 (
                     CompanyCodeCurrency == other.CompanyCodeCurrency ||
                     CompanyCodeCurrency != null &&
                     CompanyCodeCurrency.Equals(other.CompanyCodeCurrency)
                 ) &&
                 (
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                 ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ));
        }
Beispiel #12
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 (TagId != null)
         {
             hashCode = hashCode * 59 + TagId.GetHashCode();
         }
         if (SecondTagId != null)
         {
             hashCode = hashCode * 59 + SecondTagId.GetHashCode();
         }
         if (IsUntaggable != null)
         {
             hashCode = hashCode * 59 + IsUntaggable.GetHashCode();
         }
         if (Latitude != null)
         {
             hashCode = hashCode * 59 + Latitude.GetHashCode();
         }
         if (Longitude != null)
         {
             hashCode = hashCode * 59 + Longitude.GetHashCode();
         }
         if (LastModified != null)
         {
             hashCode = hashCode * 59 + LastModified.GetHashCode();
         }
         if (Created != null)
         {
             hashCode = hashCode * 59 + Created.GetHashCode();
         }
         if (Creator != null)
         {
             hashCode = hashCode * 59 + Creator.GetHashCode();
         }
         if (Comment != null)
         {
             hashCode = hashCode * 59 + Comment.GetHashCode();
         }
         if (ShareTags != null)
         {
             hashCode = hashCode * 59 + ShareTags.GetHashCode();
         }
         if (SapAsset != null)
         {
             hashCode = hashCode * 59 + SapAsset.GetHashCode();
         }
         if (AssetNumber != null)
         {
             hashCode = hashCode * 59 + AssetNumber.GetHashCode();
         }
         if (SubNumber != null)
         {
             hashCode = hashCode * 59 + SubNumber.GetHashCode();
         }
         if (CompanyCode != null)
         {
             hashCode = hashCode * 59 + CompanyCode.GetHashCode();
         }
         return(hashCode);
     }
 }
Beispiel #13
0
        /// <summary>
        /// Returns true if Asset instances are equal
        /// </summary>
        /// <param name="other">Instance of Asset to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(Asset other)
        {
            if (ReferenceEquals(null, other))
            {
                return(false);
            }
            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return
                ((
                     TagId == other.TagId ||
                     TagId != null &&
                     TagId.Equals(other.TagId)
                     ) &&
                 (
                     SecondTagId == other.SecondTagId ||
                     SecondTagId != null &&
                     SecondTagId.Equals(other.SecondTagId)
                 ) &&
                 (
                     IsUntaggable == other.IsUntaggable ||
                     IsUntaggable != null &&
                     IsUntaggable.Equals(other.IsUntaggable)
                 ) &&
                 (
                     Latitude == other.Latitude ||
                     Latitude != null &&
                     Latitude.Equals(other.Latitude)
                 ) &&
                 (
                     Longitude == other.Longitude ||
                     Longitude != null &&
                     Longitude.Equals(other.Longitude)
                 ) &&
                 (
                     LastModified == other.LastModified ||
                     LastModified != null &&
                     LastModified.Equals(other.LastModified)
                 ) &&
                 (
                     Created == other.Created ||
                     Created != null &&
                     Created.Equals(other.Created)
                 ) &&
                 (
                     Creator == other.Creator ||
                     Creator != null &&
                     Creator.Equals(other.Creator)
                 ) &&
                 (
                     Comment == other.Comment ||
                     Comment != null &&
                     Comment.Equals(other.Comment)
                 ) &&
                 (
                     ShareTags == other.ShareTags ||
                     ShareTags != null &&
                     ShareTags.Equals(other.ShareTags)
                 ) &&
                 (
                     SapAsset == other.SapAsset ||
                     SapAsset != null &&
                     SapAsset.Equals(other.SapAsset)
                 ) &&
                 (
                     AssetNumber == other.AssetNumber ||
                     AssetNumber != null &&
                     AssetNumber.Equals(other.AssetNumber)
                 ) &&
                 (
                     SubNumber == other.SubNumber ||
                     SubNumber != null &&
                     SubNumber.Equals(other.SubNumber)
                 ) &&
                 (
                     CompanyCode == other.CompanyCode ||
                     CompanyCode != null &&
                     CompanyCode.Equals(other.CompanyCode)
                 ));
        }