scheduler.py

changeset 8
7b2d2eac6a48
parent 7
e189d4a6cb8c
child 9
aa121291eb0e
--- a/scheduler.py	Sat Jan 20 14:04:51 2018 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,25 +0,0 @@
-#
-# Borgend scheduler
-#
-
-from Queue import Queue
-import sched
-import ui
-
-
-class Scheduler:
-
-    def __init__(self, backups):
-        self.backups=backups
-        self.eventqueue=Queue()
-        self.t=Thread(target=self.__scheduler)
-        t.start()
-
-    def __scheduler(sched):
-        timeout=???
-        q=sched.eventqueue
-        while True:
-            timeout, timerevent=next_timed_event(sched);
-            t=Timer(timeout, lambda: q.put(timerevent));
-            event=sq.get(True):
-            # Decide what to do

mercurial