Remove unused outerRange

outerRange is no longer used, since the filter was simply started based on the
first line in the database now.
This commit is contained in:
Shaun Ruffell 2019-12-02 21:53:37 -06:00 committed by lauft
parent 3ec09f9be1
commit bd1f7aef99

View file

@ -485,31 +485,6 @@ std::vector <Range> subtractRanges (
return results; return results;
} }
////////////////////////////////////////////////////////////////////////////////
// From a set of intervals, find the earliest start and the latest end, and
// return these in a Range.
Range outerRange (const std::vector <Interval>& intervals)
{
Range outer;
for (auto& interval : intervals)
{
if (interval.start < outer.start || outer.start.toEpoch () == 0)
outer.start = interval.start;
// Deliberately mixed start/end.
if (interval.start > outer.end)
outer.end = interval.start;
if (interval.end > outer.end)
outer.end = interval.end;
if (! interval.is_ended ())
outer.end = Datetime ();
}
return outer;
}
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
// An interval matches a filter interval if the start/end overlaps, and all // An interval matches a filter interval if the start/end overlaps, and all
// filter interval tags are found in the interval. // filter interval tags are found in the interval.