#include "pins.hpp"

Pin::Pin(std::string name) : SystemElement(name), sig(nullptr) {};

bool Pin::connected() {
    return sig != nullptr;
}

void Pin::connect(Signal *signal)
{
    sig = signal;
}

Pins::Pins(void): SystemElementContainer<Pin>("pins") {}

Pins::Pins(std::vector<Pin *> pins): SystemElementContainer<Pin>("pins", pins) {}