/// <summary>
 /// Returns the hashcode of this Object
 /// </summary>
 /// <returns>Hash code (int)</returns>
 public override int GetHashCode()
 {
     // Credit: http://stackoverflow.com/a/263416/677735
     unchecked             // Overflow is fine, just wrap
     {
         int hash = 41;
         // Suitable nullity checks etc, of course :)
         if (Id != null)
         {
             hash = hash * 59 + Id.GetHashCode();
         }
         if (Name != null)
         {
             hash = hash * 59 + Name.GetHashCode();
         }
         if (Description != null)
         {
             hash = hash * 59 + Description.GetHashCode();
         }
         if (Content != null)
         {
             hash = hash * 59 + Content.GetHashCode();
         }
         if (ContributorId != null)
         {
             hash = hash * 59 + ContributorId.GetHashCode();
         }
         if (PaperId != null)
         {
             hash = hash * 59 + PaperId.GetHashCode();
         }
         if (Comments != null)
         {
             hash = hash * 59 + Comments.GetHashCode();
         }
         if (AuditEntered != null)
         {
             hash = hash * 59 + AuditEntered.GetHashCode();
         }
         if (AuditEnteredBy != null)
         {
             hash = hash * 59 + AuditEnteredBy.GetHashCode();
         }
         if (AuditUpdated != null)
         {
             hash = hash * 59 + AuditUpdated.GetHashCode();
         }
         if (AuditUpdatedBy != null)
         {
             hash = hash * 59 + AuditUpdatedBy.GetHashCode();
         }
         return(hash);
     }
 }
예제 #2
0
 /// <summary>
 /// Returns the hashcode of this Object
 /// </summary>
 /// <returns>Hash code (int)</returns>
 public override int GetHashCode()
 {
     // Credit: http://stackoverflow.com/a/263416/677735
     unchecked             // Overflow is fine, just wrap
     {
         int hash = 41;
         // Suitable nullity checks etc, of course :)
         if (Id != null)
         {
             hash = hash * 59 + Id.GetHashCode();
         }
         if (Name != null)
         {
             hash = hash * 59 + Name.GetHashCode();
         }
         if (Description != null)
         {
             hash = hash * 59 + Description.GetHashCode();
         }
         if (MyBoolean != null)
         {
             hash = hash * 59 + MyBoolean.GetHashCode();
         }
         if (MyCreditCard != null)
         {
             hash = hash * 59 + MyCreditCard.GetHashCode();
         }
         if (MyCurrency != null)
         {
             hash = hash * 59 + MyCurrency.GetHashCode();
         }
         if (MyDateTime != null)
         {
             hash = hash * 59 + MyDateTime.GetHashCode();
         }
         if (MyDouble != null)
         {
             hash = hash * 59 + MyDouble.GetHashCode();
         }
         if (MyEmail != null)
         {
             hash = hash * 59 + MyEmail.GetHashCode();
         }
         if (MyFloat != null)
         {
             hash = hash * 59 + MyFloat.GetHashCode();
         }
         if (MyImageUrl != null)
         {
             hash = hash * 59 + MyImageUrl.GetHashCode();
         }
         if (MyInteger != null)
         {
             hash = hash * 59 + MyInteger.GetHashCode();
         }
         if (MyLong != null)
         {
             hash = hash * 59 + MyLong.GetHashCode();
         }
         if (MyPhone != null)
         {
             hash = hash * 59 + MyPhone.GetHashCode();
         }
         if (MyPostalCode != null)
         {
             hash = hash * 59 + MyPostalCode.GetHashCode();
         }
         if (MyString != null)
         {
             hash = hash * 59 + MyString.GetHashCode();
         }
         if (MyTextArea != null)
         {
             hash = hash * 59 + MyTextArea.GetHashCode();
         }
         if (MyTicks != null)
         {
             hash = hash * 59 + MyTicks.GetHashCode();
         }
         if (MyUrl != null)
         {
             hash = hash * 59 + MyUrl.GetHashCode();
         }
         if (Comments != null)
         {
             hash = hash * 59 + Comments.GetHashCode();
         }
         if (AuditEntered != null)
         {
             hash = hash * 59 + AuditEntered.GetHashCode();
         }
         if (AuditEnteredBy != null)
         {
             hash = hash * 59 + AuditEnteredBy.GetHashCode();
         }
         if (AuditUpdated != null)
         {
             hash = hash * 59 + AuditUpdated.GetHashCode();
         }
         if (AuditUpdatedBy != null)
         {
             hash = hash * 59 + AuditUpdatedBy.GetHashCode();
         }
         return(hash);
     }
 }
 /// <summary>
 /// Returns the hashcode of this Object
 /// </summary>
 /// <returns>Hash code (int)</returns>
 public override int GetHashCode()
 {
     // Credit: http://stackoverflow.com/a/263416/677735
     unchecked             // Overflow is fine, just wrap
     {
         int hash = 41;
         // Suitable nullity checks etc, of course :)
         if (Id != null)
         {
             hash = hash * 59 + Id.GetHashCode();
         }
         if (Name != null)
         {
             hash = hash * 59 + Name.GetHashCode();
         }
         if (Description != null)
         {
             hash = hash * 59 + Description.GetHashCode();
         }
         if (Degree != null)
         {
             hash = hash * 59 + Degree.GetHashCode();
         }
         if (AlmaMater != null)
         {
             hash = hash * 59 + AlmaMater.GetHashCode();
         }
         if (Email != null)
         {
             hash = hash * 59 + Email.GetHashCode();
         }
         if (Evaluations != null)
         {
             hash = hash * 59 + Evaluations.GetHashCode();
         }
         if (Password != null)
         {
             hash = hash * 59 + Password.GetHashCode();
         }
         if (Comments != null)
         {
             hash = hash * 59 + Comments.GetHashCode();
         }
         if (AuditEntered != null)
         {
             hash = hash * 59 + AuditEntered.GetHashCode();
         }
         if (AuditEnteredBy != null)
         {
             hash = hash * 59 + AuditEnteredBy.GetHashCode();
         }
         if (AuditUpdated != null)
         {
             hash = hash * 59 + AuditUpdated.GetHashCode();
         }
         if (AuditUpdatedBy != null)
         {
             hash = hash * 59 + AuditUpdatedBy.GetHashCode();
         }
         return(hash);
     }
 }