/* * Copyright (C) 2012-2018 Team Kodi * This file is part of Kodi - https://kodi.tv * * SPDX-License-Identifier: GPL-2.0-or-later * See LICENSES/README.md for more information. */ #pragma once #include "XBDateTime.h" #include class CRegExp; namespace PVR { class CPVRChannel; class CPVRTimerInfoTag; class CPVREpgInfoTag; class CPVRTimerRuleMatcher { public: CPVRTimerRuleMatcher(const std::shared_ptr& timerRule, const CDateTime& start); virtual ~CPVRTimerRuleMatcher(); std::shared_ptr GetTimerRule() const { return m_timerRule; } std::shared_ptr GetChannel() const; CDateTime GetNextTimerStart() const; bool Matches(const std::shared_ptr& epgTag) const; private: bool MatchSeriesLink(const std::shared_ptr& epgTag) const; bool MatchChannel(const std::shared_ptr& epgTag) const; bool MatchStart(const std::shared_ptr& epgTag) const; bool MatchEnd(const std::shared_ptr& epgTag) const; bool MatchDayOfWeek(const std::shared_ptr& epgTag) const; bool MatchSearchText(const std::shared_ptr& epgTag) const; const std::shared_ptr m_timerRule; CDateTime m_start; mutable std::unique_ptr m_textSearch; }; } // namespace PVR