title: What is the equivalent of Qtimer in C++ using std or boost libraries?
body: <p>I have to perform some task every 5 seconds till the program exits. I don't want to use a thread here.</p>
  
  <p>In QT I could do like this</p>
  
  <pre><code>QTimer *timer = new QTimer(this);
  connect(timer, SIGNAL(timeout()), this, SLOT(update()));
  timer-&gt;start(1000);
  </code></pre>
  
  <p>but how do I do this in c++ using std or boost libraries?</p>
  
  <p>Thank you</p>