示例#1
0
 public override int GetHashCode()
 {
     unchecked
     {
         int hash = 17;
         hash = hash * 23 + (CardNumber == null ? 0 : CardNumber.GetHashCode());
         hash = hash * 23 + (CardType == null ? 0 : CardType.GetHashCode());
         hash = hash * 23 + (ExpMonth == default(byte) ? 0 : ExpMonth.GetHashCode());
         hash = hash * 23 + (ExpYear == default(short) ? 0 : ExpYear.GetHashCode());
         hash = hash * 23 + (ModifiedDate == default(DateTime) ? 0 : ModifiedDate.GetHashCode());
         return(hash);
     }
 }
示例#2
0
        public override int GetHashCode()
        {
            int hashCode = 1370361237;

            if (Id != null)
            {
                hashCode += Id.GetHashCode();
            }

            if (CardBrand != null)
            {
                hashCode += CardBrand.GetHashCode();
            }

            if (Last4 != null)
            {
                hashCode += Last4.GetHashCode();
            }

            if (ExpMonth != null)
            {
                hashCode += ExpMonth.GetHashCode();
            }

            if (ExpYear != null)
            {
                hashCode += ExpYear.GetHashCode();
            }

            if (CardholderName != null)
            {
                hashCode += CardholderName.GetHashCode();
            }

            if (BillingAddress != null)
            {
                hashCode += BillingAddress.GetHashCode();
            }

            if (Fingerprint != null)
            {
                hashCode += Fingerprint.GetHashCode();
            }

            if (CardType != null)
            {
                hashCode += CardType.GetHashCode();
            }

            if (PrepaidType != null)
            {
                hashCode += PrepaidType.GetHashCode();
            }

            if (Bin != null)
            {
                hashCode += Bin.GetHashCode();
            }

            return(hashCode);
        }