Exemplo n.º 1
0
 /// <inheritdoc/>
 public bool Equals(Triplet <T> other)
 {
     if (!AdvancedComparerStruct <T> .System.Equals(First, other.First))
     {
         return(false);
     }
     if (!AdvancedComparerStruct <T> .System.Equals(Second, other.Second))
     {
         return(false);
     }
     return(AdvancedComparerStruct <T> .System.Equals(Third, other.Third));
 }
Exemplo n.º 2
0
        /// <inheritdoc/>
        public int CompareTo(Triplet <T> other)
        {
            int result = AdvancedComparerStruct <T> .System.Compare(First, other.First);

            if (result != 0)
            {
                return(result);
            }
            result = AdvancedComparerStruct <T> .System.Compare(Second, other.Second);

            if (result != 0)
            {
                return(result);
            }
            return(AdvancedComparerStruct <T> .System.Compare(Third, other.Third));
        }