private int compareEnds(Interval<T> other){
		if (end == null && other.end == null)
			return 0;
		if (end == null)
			return 1;
		if (other.end == null)
			return -1;
		int compare = end.compareTo(other.end);
		if (compare != 0)
			return compare;
		if (isEndInclusive ^ other.isEndInclusive)
			return isEndInclusive ? 1 : -1;
		return 0;
	}
private int compareEnds ( Interval < T > other ) { if ( end == null && other . end == null ) return 0 ; if ( end == null ) return 1 ; if ( other . end == null ) return - 1 ; int compare = end . compareTo ( other . end ) ; if ( compare != 0 ) return compare ; if ( isEndInclusive ^ other . isEndInclusive ) return isEndInclusive ? 1 : - 1 ; return 0 ; }
A {@link Comparator} that only considers the end points of the intervals. It can not and must
not be used as a standalone {@link Comparator}. It only serves to create a more readable and
modular code.