Пример #1
0
 public int GetHashCode(Suggestion obj)
 {
     return(EqualityComparer <T> .Default.GetHashCode(GetItem(obj)));
 }
Пример #2
0
 public bool Equals(Suggestion x, Suggestion y)
 {
     return(EqualityComparer <T> .Default.Equals(GetItem(x), GetItem(y)));
 }
Пример #3
0
 private T GetItem(Suggestion suggestion)
 {
     return(suggestion.UserData as T);
 }
Пример #4
0
 public int Compare(Suggestion x, Suggestion y)
 {
     return(Comparer <T> .Default.Compare(GetItem(x), GetItem(y)));
 }
Пример #5
0
 public SuggestionEventArgs(Suggestion value)
 {
     Value = value ?? throw new ArgumentNullException(nameof(value));
 }