aboutsummaryrefslogtreecommitdiff
path: root/GateAnd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'GateAnd.cpp')
-rw-r--r--GateAnd.cpp19
1 files changed, 0 insertions, 19 deletions
diff --git a/GateAnd.cpp b/GateAnd.cpp
index 487f8bc..c48d19c 100644
--- a/GateAnd.cpp
+++ b/GateAnd.cpp
@@ -1,13 +1,10 @@
#include "GateAnd.h"
-#include "Exception.h"
GateAnd GateAnd::instance(GateAnd::type);
GateAnd::GateAnd(const char * type) : Node(type) { }
SignalLevel GateAnd::level() {
- if (this->inputs.size() < 1) throw CircuitException("AndGate input size error");
-
for (int i = 0; i < this->inputs.size(); i++){
SignalLevel l = this->inputs[i]->getLevel();
@@ -17,22 +14,6 @@ SignalLevel GateAnd::level() {
return HIGH;
}
-// Concrete Nodes:
-void GateAnd::sim() {
- SignalLevel new_out = this->level();
-
- if (new_out == UNDEFINED) return;
-
- printf("io size: %lu\n", this->inputs.size());
- // TODO: fix segfault somewhere below
-
-
-
- if (this->output->getLevel() == new_out) return;
-
- this->output->setLevel(new_out);
-}
-
GateAnd::GateAnd(const GateAnd * prototype) : Node() { }
GateAnd * GateAnd::clone() const {