ROOM » Core » C++ Classes » Term
Term Class
Reference for room::Term. Moreā¦
| Header: | #include "term.h" |
|---|---|
| CMake: | target_link_libraries(mytarget PRIVATE ROOM::room) |
Public Functions
| Term(std::string name, std::uint32_t layerId, Point position) | Constructs a terminal (pin) on a net. |
| const std::string & name() const | Returns the terminal name. |
| std::uint32_t layerId() const | Returns the layer index associated with this terminal. |
| const Point & position() const | Returns the pin location. |
Detailed Description
Member Function Documentation
Term(std::string name, std::uint32_t layerId, Point position)
Constructs a terminal (pin) on a net.
| Parameter | Description |
|---|---|
name | Terminal or pin name (for example "A" or "VDD"). |
layerId | Layer index into Lib::layers(), same convention as Shape. |
position | Pin location in database units (DBU). |
const std::string & name() const
Returns the terminal name.
Returns: Pin name string.
std::uint32_t layerId() const
Returns the layer index associated with this terminal.
Returns: Index into the parent view's layer table.
Example
room::Term pinA("A", 0, {100, 200});
room::Term pinY("Y", 0, {500, 200});
room::Net net("N1");
net.terms().push_back(pinA);
net.terms().push_back(pinY);