コード例 #1
0
 public int CompareTo(GrepMatch other)
 {
     if (other == null)
     {
         return(1);
     }
     else
     {
         return(StartLocation.CompareTo(other.StartLocation));
     }
 }
コード例 #2
0
 public int CompareTo(object obj)
 {
     if (obj == null)
     {
         return(1);
     }
     if (obj is GrepMatch)
     {
         return(StartLocation.CompareTo(((GrepMatch)obj).StartLocation));
     }
     else
     {
         return(1);
     }
 }