public override bool Equals(object obj) { if (obj == null) { return(false); } if (obj == this) { return(true); } return(obj is Invoice other && ((Id == null && other.Id == null) || (Id?.Equals(other.Id) == true)) && ((Version == null && other.Version == null) || (Version?.Equals(other.Version) == true)) && ((LocationId == null && other.LocationId == null) || (LocationId?.Equals(other.LocationId) == true)) && ((OrderId == null && other.OrderId == null) || (OrderId?.Equals(other.OrderId) == true)) && ((PrimaryRecipient == null && other.PrimaryRecipient == null) || (PrimaryRecipient?.Equals(other.PrimaryRecipient) == true)) && ((PaymentRequests == null && other.PaymentRequests == null) || (PaymentRequests?.Equals(other.PaymentRequests) == true)) && ((DeliveryMethod == null && other.DeliveryMethod == null) || (DeliveryMethod?.Equals(other.DeliveryMethod) == true)) && ((InvoiceNumber == null && other.InvoiceNumber == null) || (InvoiceNumber?.Equals(other.InvoiceNumber) == true)) && ((Title == null && other.Title == null) || (Title?.Equals(other.Title) == true)) && ((Description == null && other.Description == null) || (Description?.Equals(other.Description) == true)) && ((ScheduledAt == null && other.ScheduledAt == null) || (ScheduledAt?.Equals(other.ScheduledAt) == true)) && ((PublicUrl == null && other.PublicUrl == null) || (PublicUrl?.Equals(other.PublicUrl) == true)) && ((NextPaymentAmountMoney == null && other.NextPaymentAmountMoney == null) || (NextPaymentAmountMoney?.Equals(other.NextPaymentAmountMoney) == true)) && ((Status == null && other.Status == null) || (Status?.Equals(other.Status) == true)) && ((Timezone == null && other.Timezone == null) || (Timezone?.Equals(other.Timezone) == true)) && ((CreatedAt == null && other.CreatedAt == null) || (CreatedAt?.Equals(other.CreatedAt) == true)) && ((UpdatedAt == null && other.UpdatedAt == null) || (UpdatedAt?.Equals(other.UpdatedAt) == true)) && ((CustomFields == null && other.CustomFields == null) || (CustomFields?.Equals(other.CustomFields) == true))); }
public override int GetHashCode() { int hashCode = 1321207967; if (Id != null) { hashCode += Id.GetHashCode(); } if (Version != null) { hashCode += Version.GetHashCode(); } if (LocationId != null) { hashCode += LocationId.GetHashCode(); } if (OrderId != null) { hashCode += OrderId.GetHashCode(); } if (PrimaryRecipient != null) { hashCode += PrimaryRecipient.GetHashCode(); } if (PaymentRequests != null) { hashCode += PaymentRequests.GetHashCode(); } if (DeliveryMethod != null) { hashCode += DeliveryMethod.GetHashCode(); } if (InvoiceNumber != null) { hashCode += InvoiceNumber.GetHashCode(); } if (Title != null) { hashCode += Title.GetHashCode(); } if (Description != null) { hashCode += Description.GetHashCode(); } if (ScheduledAt != null) { hashCode += ScheduledAt.GetHashCode(); } if (PublicUrl != null) { hashCode += PublicUrl.GetHashCode(); } if (NextPaymentAmountMoney != null) { hashCode += NextPaymentAmountMoney.GetHashCode(); } if (Status != null) { hashCode += Status.GetHashCode(); } if (Timezone != null) { hashCode += Timezone.GetHashCode(); } if (CreatedAt != null) { hashCode += CreatedAt.GetHashCode(); } if (UpdatedAt != null) { hashCode += UpdatedAt.GetHashCode(); } if (CustomFields != null) { hashCode += CustomFields.GetHashCode(); } return(hashCode); }