@@ -315,7 +315,18 @@ Returns a past the end const_iterator in reverse.
315315** Returns** : past the end const_iterator.
316316
317317## Members of Interval  
318- ___ You can implement your own interval if you provide all the same functions.___ 
318+ ___ You can implement your own interval if you provide the same functions, except (within, operator-, size, operator!=).___ 
319+ 
320+ There are 6 types of intervals:
321+ -  open: (a, b)
322+ -  left_open: (a, b] 
323+ -  right_open: [ a, b)
324+ -  closed: [ a, b] 
325+ -  closed_adjacent: [ a, b]  (counts adjacent intervals as overlapping)
326+ -  dynamic: Can be any of the above, depending on the input.
327+ 
328+ Which can be picked with the second template parameter of interval:
329+ ` lib_interval_tree::interval<int, lib_interval_tree::open> ` 
319330
320331 -  [ Members of Interval] ( #members-of-interval ) 
321332 -  [ using value_type] ( #using-value_type ) 
@@ -324,7 +335,7 @@ ___You can implement your own interval if you provide all the same functions.___
324335 -  [ friend bool operator!=(interval const& lhs, interval const& other)] ( #friend-bool-operatorinterval-const-lhs-interval-const-other-1 ) 
325336 -  [ value_type low() const] ( #value_type-low-const ) 
326337 -  [ value_type high() const] ( #value_type-high-const ) 
327-  -  [ bool overlaps(value_type l, value_type h) const] ( #bool-overlapsvalue_type-l-value_type-h-const ) 
338+  -  [ \[\[ deprecated \]\]   bool overlaps(value_type l, value_type h) const] ( #bool-overlapsvalue_type-l-value_type-h-const ) 
328339 -  [ bool overlaps_exclusive(value_type l, value_type h) const] ( #bool-overlaps_exclusivevalue_type-l-value_type-h-const ) 
329340 -  [ bool overlaps(interval const& other) const] ( #bool-overlapsinterval-const-other-const ) 
330341 -  [ bool overlaps_exclusive(interval const& other) const] ( #bool-overlaps_exclusiveinterval-const-other-const ) 
@@ -346,22 +357,23 @@ Comparison operator.
346357Lower bound.
347358### value_type high() const  
348359Upper bound.
349- ### bool overlaps(value_type l, value_type h) const  
360+ ### \[\[ deprecated \]\]   bool overlaps(value_type l, value_type h) const 
350361Overlap these bounds with this interval (closed)?
362+ Is deprecated because the overlapping only works with closed intervals.
351363### bool overlaps_exclusive(value_type l, value_type h) const  
352364Overlap these bounds with this interval excluding borders?
353365### bool overlaps(interval const& other) const  
354366Like overlaps with lower and upper bound.
355367### bool overlaps_exclusive(interval const& other) const  
356368Like overlaps with lower and upper bound.
357369### bool within(value_type value) const  
358- Is the value within the interval (closed) ?
370+ Is the value within the interval?
359371### bool within(interval const& other) const  
360372Is the interval within the interval?
361373### value_type operator-(interval const& other) const  
362374Calculates the distance between the two intervals.
363375Overlapping intervals have 0 distance.
364376### value_type size() const  
365- Returns high - low .
377+ Returns The amount of elements in the interval when integral, or the distance between the 2 bounds when floating point .
366378### interval join(interval const& other) const  
367379Joins 2 intervals and whatever is inbetween.
0 commit comments