1
Files
lecture-operating-system-de…/c_os/user/PreemptiveLoopThread.h
2022-07-04 22:05:07 +02:00

23 lines
501 B
C++

#ifndef __pre_loopthread_include__
#define __pre_loopthread_include__
#include "kernel/Globals.h"
#include "kernel/threads/Thread.h"
class PreemptiveLoopThread : public Thread {
private:
int id;
PreemptiveLoopThread(const PreemptiveLoopThread& copy) = delete; // Verhindere Kopieren
public:
// Gibt der Loop einen Stack und eine Id.
PreemptiveLoopThread(int i) : id(i) {}
// Zaehlt einen Zaehler hoch und gibt ihn auf dem Bildschirm aus.
void run() override;
};
#endif