chiark / gitweb /
timer: add timer persistance (aka anacron-like behaviour)
[elogind.git] / src / core / timer.h
index 4168553e9d977825f88db063ece5552871cb79aa..712cced29682c4a97d6914dfad9155ad7a861df7 100644 (file)
@@ -69,18 +69,24 @@ typedef enum TimerResult {
 struct Timer {
         Unit meta;
 
+        usec_t accuracy_usec;
+
         LIST_HEAD(TimerValue, values);
         usec_t next_elapse_monotonic;
         usec_t next_elapse_realtime;
 
         TimerState state, deserialized_state;
 
-        Watch monotonic_watch;
-        Watch realtime_watch;
+        sd_event_source *monotonic_event_source;
+        sd_event_source *realtime_event_source;
 
         TimerResult result;
 
-        usec_t last_trigger_monotonic;
+        bool persistent;
+
+        dual_timestamp last_trigger;
+
+        char *stamp_path;
 };
 
 void timer_free_values(Timer *t);