(self, *args, **kwargs)
Starts the timer.

        If the callback returns True the timer will be restarted.
Starts the timer.
Starts the timer .
def start(self, *args, **kwargs):
        """Starts the timer.

        If the callback returns True the timer will be restarted.
        """

        @wraps(self.callback)
        def callback():
            os.read(self.timer, 8)
            repeat = self.callback(*args, **kwargs)
            if not repeat:
                self.stop()

        spec = timerfd.itimerspec(self.interval, self.interval)
        timerfd.settime(self.timer, 0, spec)

        self.loop.remove_watcher(self.timer)
        self.loop.add_watcher(self.timer, callback)
def start ( self , * args , * * kwargs ) : @ wraps ( self . callback ) def callback ( ) : os . read ( self . timer , 8 ) repeat = self . callback ( * args , * * kwargs ) if not repeat : self . stop ( ) spec = timerfd . itimerspec ( self . interval , self . interval ) timerfd . settime ( self . timer , 0 , spec ) self . loop . remove_watcher ( self . timer ) self . loop . add_watcher ( self . timer , callback )