Create header file for Node

This commit is contained in:
2021-01-02 15:37:05 +01:00
parent 047e9ee732
commit 004e7a9cd6
8 changed files with 31 additions and 28 deletions

24
Assignment_2/lib/Node.h Normal file
View File

@@ -0,0 +1,24 @@
#pragma once
#include <mutex>
class Node {
protected:
int data;
bool is_dummy;
std::mutex mut;
public:
Node* next;
bool deleted;
Node(int element);
static Node* Dummy();
// Dummy();
void lock();
void unlock();
bool is_smaller_than(int n);
bool is_smaller_than(Node* n);
bool is_equal(int n);
};