Пример #1
0
 /// <summary>
 /// Compare to other object.
 /// </summary>
 /// <param name="other"></param>
 /// <returns></returns>
 public int CompareTo(ModelBase <ID> other)
 {
     return(other is null ? 1 : this.GetHashCode().CompareTo(other.GetHashCode()));
 }
Пример #2
0
 /// <summary>
 /// Compare objects.
 /// </summary>
 /// <param name="other"></param>
 /// <returns></returns>
 public virtual bool Equals(ModelBase <ID> other)
 {
     return(other != null && other == this || this.CompareTo(other) == 0);
 }