14 #ifndef ZYPP_NG_BASE_TIMER_H_INCLUDED 15 #define ZYPP_NG_BASE_TIMER_H_INCLUDED 18 #include <zypp/zyppng/base/Base> 19 #include <zypp/zyppng/base/Signals> 24 class EventDispatcher;
72 static uint64_t
now ();
uint64_t interval() const
std::weak_ptr< Base > WeakPtr
SignalProxy< void(Timer &t)> sigExpired()
This signal is always emitted when the timer expires.
void stop()
Stops the timer if its running. The.
void setSingleShot(bool singleShot=true)
Sets the timer to trigger only once, after it has expired once.
The Timer class provides repetitive and single-shot timers.
uint64_t remaining() const
static std::shared_ptr< Timer > create()
Creates a new Timer object, the timer is not started at this point.
uint64_t expire()
Advances the internal clock of the timer, if the timer expires the sigExpired signal is emitted...
#define ZYPP_DECLARE_PRIVATE(Class)
std::shared_ptr< Base > Ptr