diff options
Diffstat (limited to 'include/datetime/alarm-queue-simple.h')
-rw-r--r-- | include/datetime/alarm-queue-simple.h | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/include/datetime/alarm-queue-simple.h b/include/datetime/alarm-queue-simple.h index d191aec..838d28a 100644 --- a/include/datetime/alarm-queue-simple.h +++ b/include/datetime/alarm-queue-simple.h @@ -20,6 +20,8 @@ #ifndef INDICATOR_DATETIME_ALARM_QUEUE_SIMPLE_H #define INDICATOR_DATETIME_ALARM_QUEUE_SIMPLE_H +#include <memory> // std::shared_ptr + #include <datetime/alarm-queue.h> #include <datetime/clock.h> #include <datetime/planner.h> @@ -39,20 +41,12 @@ public: const std::shared_ptr<Planner>& upcoming_planner, const std::shared_ptr<WakeupTimer>& timer); ~SimpleAlarmQueue(); - core::Signal<const Appointment&>& alarm_reached(); + core::Signal<const Appointment&, const Alarm&>& alarm_reached() override; private: - void requeue(); - bool find_next_alarm(Appointment& setme) const; - std::vector<Appointment> find_current_alarms() const; - void check_alarms(); - - std::set<std::pair<std::string,DateTime>> m_triggered; - const std::shared_ptr<Clock> m_clock; - const std::shared_ptr<Planner> m_planner; - const std::shared_ptr<WakeupTimer> m_timer; - core::Signal<const Appointment&> m_alarm_reached; - DateTime m_datetime; + class Impl; + friend class Impl; + std::unique_ptr<Impl> impl; }; |