2 #include "nlohmann/json_fwd.hpp"
3 #include "util/uuid.hpp"
4 #include "util/uuid_provider.hpp"
5 #include "common/lut.hpp"
20 enum class Direction {
39 Direction direction = Direction::INPUT;
41 static const std::vector<std::pair<Pin::Direction, std::string>> direction_names;
52 json serialize()
const;
53 UUID get_uuid()
const;
65 static Unit new_from_file(
const std::string &filename);
69 std::string manufacturer;
70 std::map<UUID, Pin> pins;
71 json serialize()
const;
72 UUID get_uuid()
const;
std::vector< std::string > names
The Pin's alternate names.
Definition: unit.hpp:50
basic_json<> json
default JSON class
Definition: json_fwd.hpp:61
std::string primary_name
The Pin's primary name.
Definition: unit.hpp:38
A Pin represents a logical pin of a Unit.
Definition: unit.hpp:18
a class to store JSON values
Definition: json.hpp:166
This class encapsulates a UUID and allows it to be uses as a value type.
Definition: uuid.hpp:16
A Unit is the template for a Gate inside of an Entity.
Definition: unit.hpp:60
unsigned int swap_group
Pins of the same swap_group can be pinswapped.
Definition: unit.hpp:46
Interface for objects that have a UUID.
Definition: uuid_provider.hpp:9