Exemple #1
0
 public int GetHashCode(ItemWithQuantity <TValue> obj)
 {
     return(_valueComparer.GetHashCode(obj.Item)
            ^ obj.Quantity);
 }
Exemple #2
0
 public bool Equals(ItemWithQuantity <TValue> x, ItemWithQuantity <TValue> y)
 {
     return((x.Quantity == y.Quantity) &&
            _valueComparer.Equals(x.Item, y.Item));
 }