Exemple #1
0
 public static void AddTuple<T1, T2, T3, T4>(this ICollection<Tuple<T1, T2, T3, T4>> collection, T1 first, T2 second,
                                             T3 third, T4 fourth)
 {
     collection.Add(Tuple.From(first, second, third, fourth));
 }
Exemple #2
0
 public static void AddTuple<T1, T2>(this ICollection<Pair<T1, T2>> collection, T1 first, T2 second)
 {
     collection.Add(Tuple.From(first, second));
 }
Exemple #3
0
 public static Triple<T1, T2, T3> Append<T1, T2, T3>(this Tuple<T1, T2> tuple, T3 item)
 {
     return Tuple.From(tuple.Item1, tuple.Item2, item);
 }
Exemple #4
0
 public static Quad<T1, T2, T3, T4> Append<T1, T2, T3, T4>(this Tuple<T1, T2, T3> tuple, T4 item)
 {
     return Tuple.From(tuple.Item1, tuple.Item2, tuple.Item3, item);
 }
Exemple #5
0
 public bool Equals(Tuple<T1, T2> obj)
 {
     if (ReferenceEquals(null, obj)) return false;
     if (ReferenceEquals(this, obj)) return true;
     return Equals(obj.Item1, Item1) && Equals(obj.Item2, Item2);
 }