示例#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 (AmountPaid != null)
         {
             hashCode = hashCode * 59 + AmountPaid.GetHashCode();
         }
         if (CardPaymentMethodSpecificOutput != null)
         {
             hashCode = hashCode * 59 + CardPaymentMethodSpecificOutput.GetHashCode();
         }
         if (MobilePaymentMethodSpecificOutput != null)
         {
             hashCode = hashCode * 59 + MobilePaymentMethodSpecificOutput.GetHashCode();
         }
         if (PaymentMethod != null)
         {
             hashCode = hashCode * 59 + PaymentMethod.GetHashCode();
         }
         if (RedirectPaymentMethodSpecificOutput != null)
         {
             hashCode = hashCode * 59 + RedirectPaymentMethodSpecificOutput.GetHashCode();
         }
         return(hashCode);
     }
 }
示例#2
0
        public override int GetHashCode()
        {
            unchecked
            {
                var hashCode = Billing != null?Billing.GetHashCode() : 0;

                hashCode = (hashCode * 397) ^ (CartHash != null ? CartHash.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (CartTax != null ? CartTax.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (CreatedVia != null ? CreatedVia.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (Currency != null ? Currency.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ CustomerId;
                hashCode = (hashCode * 397) ^ (CustomerIpAddress != null ? CustomerIpAddress.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (CustomerNote != null ? CustomerNote.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (CustomerUserAgent != null ? CustomerUserAgent.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (DiscountTax != null ? DiscountTax.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (DiscountTotal != null ? DiscountTotal.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ Id;
                hashCode = (hashCode * 397) ^ (Number != null ? Number.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (OrderKey != null ? OrderKey.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ ParentId;
                hashCode = (hashCode * 397) ^ (PaymentMethod != null ? PaymentMethod.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (PaymentMethodTitle != null ? PaymentMethodTitle.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ PricesIncludeTax.GetHashCode();
                hashCode = (hashCode * 397) ^ (Shipping != null ? Shipping.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (ShippingTax != null ? ShippingTax.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (ShippingTotal != null ? ShippingTotal.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (Status != null ? Status.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (Total != null ? Total.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (TotalTax != null ? TotalTax.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (TransactionId != null ? TransactionId.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (Version != null ? Version.GetHashCode() : 0);
                return(hashCode);
            }
        }
示例#3
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 (CustomerId != null)
         {
             hashCode = hashCode * 59 + CustomerId.GetHashCode();
         }
         if (ExpiryMonth != null)
         {
             hashCode = hashCode * 59 + ExpiryMonth.GetHashCode();
         }
         if (ExpiryYear != null)
         {
             hashCode = hashCode * 59 + ExpiryYear.GetHashCode();
         }
         if (BillingDetails != null)
         {
             hashCode = hashCode * 59 + BillingDetails.GetHashCode();
         }
         if (Id != null)
         {
             hashCode = hashCode * 59 + Id.GetHashCode();
         }
         if (Last4 != null)
         {
             hashCode = hashCode * 59 + Last4.GetHashCode();
         }
         if (PaymentMethod != null)
         {
             hashCode = hashCode * 59 + PaymentMethod.GetHashCode();
         }
         if (Fingerprint != null)
         {
             hashCode = hashCode * 59 + Fingerprint.GetHashCode();
         }
         if (Name != null)
         {
             hashCode = hashCode * 59 + Name.GetHashCode();
         }
         if (CvvCheck != null)
         {
             hashCode = hashCode * 59 + CvvCheck.GetHashCode();
         }
         if (AvsCheck != null)
         {
             hashCode = hashCode * 59 + AvsCheck.GetHashCode();
         }
         return(hashCode);
     }
 }
示例#4
0
        public virtual int _GetUniqueIdentifier()
        {
            var hashCode = 399326290;

            hashCode = hashCode * -1521134295 + (Id?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (PaymentMethod?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (CardholderName?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (CardNumber?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (CCV?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (ExpirationMonth?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (ExpirationYear?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (IBANNumber?.GetHashCode() ?? 0);
            hashCode = hashCode * -1521134295 + (BankName?.GetHashCode() ?? 0);
            return(hashCode);
        }
示例#5
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 (Name != null)
         {
             hashCode = hashCode * 59 + Name.GetHashCode();
         }
         if (Status != null)
         {
             hashCode = hashCode * 59 + Status.GetHashCode();
         }
         if (StatusReason != null)
         {
             hashCode = hashCode * 59 + StatusReason.GetHashCode();
         }
         if (ValidFor != null)
         {
             hashCode = hashCode * 59 + ValidFor.GetHashCode();
         }
         if (EngagedParty != null)
         {
             hashCode = hashCode * 59 + EngagedParty.GetHashCode();
         }
         if (PartyRoleType != null)
         {
             hashCode = hashCode * 59 + PartyRoleType.GetHashCode();
         }
         if (Account != null)
         {
             hashCode = hashCode * 59 + Account.GetHashCode();
         }
         if (PaymentMethod != null)
         {
             hashCode = hashCode * 59 + PaymentMethod.GetHashCode();
         }
         if (ContactMedium != null)
         {
             hashCode = hashCode * 59 + ContactMedium.GetHashCode();
         }
         if (Characteristic != null)
         {
             hashCode = hashCode * 59 + Characteristic.GetHashCode();
         }
         if (CreditProfile != null)
         {
             hashCode = hashCode * 59 + CreditProfile.GetHashCode();
         }
         if (Agreement != null)
         {
             hashCode = hashCode * 59 + Agreement.GetHashCode();
         }
         if (RelatedParty != null)
         {
             hashCode = hashCode * 59 + RelatedParty.GetHashCode();
         }
         return(hashCode);
     }
 }