From 78d29f8f1d7761c81ef62c0a14abc9f0c4e76bf8 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 26 Mar 2016 14:31:55 -0400 Subject: [PATCH] Rules: Stubbed ::parseRuleHolidays --- src/Rules.cpp | 12 ++++++++++++ src/Rules.h | 1 + 2 files changed, 13 insertions(+) diff --git a/src/Rules.cpp b/src/Rules.cpp index d3a3d918..2531c34d 100644 --- a/src/Rules.cpp +++ b/src/Rules.cpp @@ -313,6 +313,10 @@ void Rules::parseRule (const std::string& input) else if (tokens.size () == 2 && tokens[1] == "theme:") parseRuleTheme (lines); + // define holidays: + else if (tokens.size () == 2 && tokens[1] == "holidays:") + parseRuleHolidays (lines); + // Error. else throw format ("Unrecognized rule type '{1}'", join (" ", tokens)); @@ -348,6 +352,14 @@ void Rules::parseRuleTag (const std::vector & lines) } } +//////////////////////////////////////////////////////////////////////////////// +void Rules::parseRuleHolidays (const std::vector & lines) +{ + for (auto& line : lines) + { + } +} + //////////////////////////////////////////////////////////////////////////////// unsigned int Rules::getIndentation (const std::string& line) { diff --git a/src/Rules.h b/src/Rules.h index c445eb53..4ce13420 100644 --- a/src/Rules.h +++ b/src/Rules.h @@ -60,6 +60,7 @@ private: void parseRuleTheme (const std::vector &); void parseRuleExclusions (const std::vector &); void parseRuleTag (const std::vector &); + void parseRuleHolidays (const std::vector &); unsigned int getIndentation (const std::string&); std::vector tokenizeLine (const std::string&);