int main(int argc, const char *argv[])
{
    TimerThread t;
    t.setTimer(3,1);
    t.setTimerCallback(&func);

    t.startTimerThread();

    sleep(10);
    t.cancelTimerThread();
    return 0;
}
Esempio n. 2
0
int main(int argc, const char *argv[])
{
    TimerThread foo;
    foo.setTimer(3, 1);
    foo.setTimerCallback(&foobar);

    foo.startTimerThread();

    sleep(10);

    foo.cancelTimerThread();
    return 0;
}