Reports whether the interval can be transformed into the given interval by moving each endpoint a small distance. The empty interval is considered to be positioned arbitrarily on the real line, so any interval with a small enough length will match the empty interval.
Returns the midpoint of the interval. Behaviour is undefined for empty intervals.
Returns the closest point in the interval to the given point p. The interval must be non-empty.
Returns true iff the interval contains p.
Returns true iff the interval strictly contains p.
Reports whether the interval is empty.
Returns the length of the interval. The length of an empty interval is negative.
Generates a human readable string.
Interval represents a closed interval on ℝ. Zero-length intervals (where lo == hi) represent single points. If lo > hi then the interval is empty.