version 0.0.1
This commit is contained in:
23
include/Threads/Thread.hpp
Normal file
23
include/Threads/Thread.hpp
Normal file
@@ -0,0 +1,23 @@
|
||||
#pragma once
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
class Thread {
|
||||
public:
|
||||
/**
|
||||
* @brief Construct a new Thread object
|
||||
*/
|
||||
inline Thread() : _quit(false), _running(true) {}
|
||||
|
||||
/**
|
||||
* @brief quit the thread
|
||||
*/
|
||||
inline void quit() { _quit = true; }
|
||||
|
||||
inline bool is_running() { return _running; }
|
||||
|
||||
protected:
|
||||
bool _quit;
|
||||
bool _running;
|
||||
uint64_t _cycles_old;
|
||||
};
|
||||
Reference in New Issue
Block a user