コード例 #1
0
 public bool Overlaps(Interval <T> other)
 {
     return(From.CompareTo(other.To) <= 0 &&
            To.CompareTo(other.From) >= 0);
 }
コード例 #2
0
 public bool Contains(Interval <T> other)
 {
     return(From.CompareTo(other.From) <= 0 &&
            To.CompareTo(other.To) >= 0);
 }