From 610e78fedeb5de46bc6369e4a7f4fbbdeced2cf7 Mon Sep 17 00:00:00 2001 From: Shaun Ruffell Date: Sun, 5 Jan 2020 12:54:05 -0600 Subject: [PATCH] Remove getAllInclusions helper function All locations in the code that was creating Intervals for all entries in the database have been removed. This function can now be removed as well. --- src/data.cpp | 14 -------------- src/timew.h | 1 - 2 files changed, 15 deletions(-) diff --git a/src/data.cpp b/src/data.cpp index 5c109f75..51995ef7 100644 --- a/src/data.cpp +++ b/src/data.cpp @@ -311,20 +311,6 @@ std::vector getAllExclusions ( return merge (addRanges (range, results, exclusionRanges)); } -//////////////////////////////////////////////////////////////////////////////// -std::vector getAllInclusions (Database& database) -{ - std::vector all; - auto it = database.rbegin (); - auto end = database.rend (); - for ( ;it != end; ++it) - { - all.push_back (IntervalFactory::fromSerialization (*it)); - } - - return all; -} - //////////////////////////////////////////////////////////////////////////////// std::vector subset ( const Interval& filter, diff --git a/src/timew.h b/src/timew.h index 2e4ef269..74dbfaaf 100644 --- a/src/timew.h +++ b/src/timew.h @@ -40,7 +40,6 @@ Interval getFilter (const CLI&); std::vector getHolidays (const Rules&); std::vector getAllExclusions (const Rules&, const Range&); -std::vector getAllInclusions (Database&); std::vector subset (const Interval&, const std::vector &); std::vector subset (const Range&, const std::vector &); std::vector subset (const Range&, const std::vector &);