Horizon
via.hpp
1 #pragma once
2 #include "common/common.hpp"
3 #include "common/junction.hpp"
4 #include "nlohmann/json_fwd.hpp"
5 #include "pool/padstack.hpp"
6 #include "util/uuid.hpp"
7 #include "util/uuid_ptr.hpp"
8 #include <fstream>
9 #include <map>
10 #include <set>
11 #include <vector>
12 
13 namespace horizon {
14 using json = nlohmann::json;
15 
16 class Via {
17 public:
18  Via(const UUID &uu, const json &j, class Board *brd = nullptr, class ViaPadstackProvider *vpp = nullptr);
19  Via(const UUID &uu, const Padstack *ps);
20  Via(shallow_copy_t sh, const Via &other);
21 
22  UUID uuid;
23 
24  uuid_ptr<Net> net_set = nullptr;
25  uuid_ptr<Junction> junction = nullptr;
26  uuid_ptr<const Padstack> vpp_padstack;
27  Padstack padstack;
28  void expand(const class Board &brd);
29 
30  ParameterSet parameter_set;
31 
32  bool from_rules = true;
33  bool locked = false;
34 
35  json serialize() const;
36 };
37 } // namespace horizon
horizon::uuid_ptr
Definition: uuid_ptr.hpp:8
horizon::Board
Definition: board.hpp:42
horizon::shallow_copy_t
Definition: common.hpp:270
horizon::ViaPadstackProvider
Definition: via_padstack_provider.hpp:13
horizon::Padstack
Definition: padstack.hpp:21
horizon::Via
Definition: via.hpp:16
nlohmann::basic_json
a class to store JSON values
Definition: json.hpp:166
horizon::UUID
This class encapsulates a UUID and allows it to be uses as a value type.
Definition: uuid.hpp:16
nlohmann::json
basic_json<> json
default JSON class
Definition: json_fwd.hpp:61