chore: Add course material

This commit is contained in:
2026-10-05 11:27:21 +02:00
parent 971813c351
commit e8241fd1ff
660 changed files with 26658 additions and 1 deletions
+33
View File
@@ -0,0 +1,33 @@
#ifndef TIMERSET_H
#define TIMERSET_H
#include <ctime>
#include <thread>
#include <vector>
class Timer;
class TimerSet {
public:
void pollAllTimers();
void addATimer(Timer *);
private:
TimerSet();
std::vector<Timer *> timers;
std::time_t previousTime;
// Exercise 5.1 Threading two new members
std::thread pollingThread;
void poll10Hz();
// Meyer's Singleton
public:
static TimerSet &Instance();
private:
TimerSet(const TimerSet &);
TimerSet &operator=(const TimerSet &);
};
#endif