aboutsummaryrefslogtreecommitdiff
path: root/Node.h
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-06-04 10:38:14 +0200
committerLoek Le Blansch <loek@pipeframe.xyz>2024-06-04 10:38:14 +0200
commitc084bee21f66e6322d4d55b8700f0779f2c58d0d (patch)
tree49190903b19e283149a45e6f1e54a13405367aed /Node.h
parentd762fa59c4182355da40cbc415181a362b89117f (diff)
parent760520d490ef9a382aee9b0338ba289b1538974b (diff)
Merge branch 'node' of github.com:lonkaars/depa into node
Diffstat (limited to 'Node.h')
-rw-r--r--Node.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/Node.h b/Node.h
new file mode 100644
index 0000000..f1845a9
--- /dev/null
+++ b/Node.h
@@ -0,0 +1,32 @@
+#pragma once
+#include <string>
+#include <vector>
+
+#include "Observer.h"
+#include "Net.h"
+
+
+
+class Node: Observer {
+ protected:
+ std::string label;
+ std::string type;
+
+ std::vector<Net*> inputs;
+ Net* output;
+
+ public:
+ Node(/* args */);
+ virtual ~Node();
+ void update();
+ virtual void addInput(Net*);
+ virtual void setOutput(Net*);
+ virtual void compare() = 0;
+};
+
+class GateAnd: public Node {
+ public:
+ GateAnd(){};
+ ~GateAnd(){};
+ void compare();
+};