/// <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 (AdditionalData != null) { hashCode = hashCode * 59 + AdditionalData.GetHashCode(); } if (InvoiceDate != null) { hashCode = hashCode * 59 + InvoiceDate.GetHashCode(); } if (InvoiceNumber != null) { hashCode = hashCode * 59 + InvoiceNumber.GetHashCode(); } if (TextQualifiers != null) { hashCode = hashCode * 59 + TextQualifiers.GetHashCode(); } return(hashCode); } }
public virtual int _GetUniqueIdentifier() { var hashCode = 399326290; hashCode = hashCode * -1521134295 + (Id?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (DeliveryDate?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (OrderQuantity?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (OrderDate?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (InvoiceId?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (InvoiceDate?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (FundedRate?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (InterestRate?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (TotalValue?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (FundingValue?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (PaymentId?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (PayementDate?.GetHashCode() ?? 0); hashCode = hashCode * -1521134295 + (CreditNoteNumber?.GetHashCode() ?? 0); return(hashCode); }
public override int GetHashCode() { unchecked { var hashCode = (InvoiceId != null ? InvoiceId.GetHashCode() : 0); hashCode = (hashCode * 397) ^ InvoiceNumber; hashCode = (hashCode * 397) ^ (InvoiceNumberAsString != null ? InvoiceNumberAsString.GetHashCode() : 0); hashCode = (hashCode * 397) ^ Total.GetHashCode(); hashCode = (hashCode * 397) ^ Subtotal.GetHashCode(); hashCode = (hashCode * 397) ^ Tax.GetHashCode(); hashCode = (hashCode * 397) ^ TaxPercentage.GetHashCode(); hashCode = (hashCode * 397) ^ InvoiceDate.GetHashCode(); hashCode = (hashCode * 397) ^ (ContractName != null ? ContractName.GetHashCode() : 0); hashCode = (hashCode * 397) ^ PeriodStartDate.GetHashCode(); hashCode = (hashCode * 397) ^ PeriodEndDate.GetHashCode(); hashCode = (hashCode * 397) ^ (Currency != null ? Currency.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (From != null ? From.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (To != null ? To.GetHashCode() : 0); hashCode = (hashCode * 397) ^ (LineItems?.Sum(x => x.GetHashCode()) ?? 0); return(hashCode); } }
public override int GetHashCode() { var hashCode = -133760364; hashCode = hashCode * -1521134295 + base.GetHashCode(); hashCode = hashCode * -1521134295 + CreationDate.GetHashCode(); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(CreatedBy); hashCode = hashCode * -1521134295 + ModificationDate.GetHashCode(); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(ModifiedBy); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(IctsReference); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Tag); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Serial); hashCode = hashCode * -1521134295 + EqualityComparer <ProductDto> .Default.GetHashCode(Product); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Description); hashCode = hashCode * -1521134295 + InvoiceDate.GetHashCode(); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(InvoiceNumber); hashCode = hashCode * -1521134295 + Price.GetHashCode(); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(PaidBy); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Owner); hashCode = hashCode * -1521134295 + InstallDate.GetHashCode(); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(InstalledBy); hashCode = hashCode * -1521134295 + EqualityComparer <string> .Default.GetHashCode(Remark); hashCode = hashCode * -1521134295 + TeamAsset.GetHashCode(); return(hashCode); }