Defined in dot.hpp.
This nested struct represents a node in the represented graph.
Public Member Functions | |
| Node ()=default | |
| Default constructor. | |
| Node (Node &&)=default | |
| Default move constructor. | |
| Node (Node const &)=default | |
| Default copy constructor. | |
| template<typename Thing> | |
| Node (Thing &&thing) | |
| Construct from anything. | |
| template<typename Thing1, typename Thing2> | |
| Node & | add_attr (Thing1 &&key, Thing2 &&val) |
| Add an attribute to a node. | |
| Node & | operator= (Node &&)=default |
| Default move assignment. | |
| Node & | operator= (Node const &)=default |
| Default copy assignment. | |
Related Symbols | |
(Note that these are not member symbols.) | |
| std::string | to_human_readable_repr (Dot::Node const &n) |
| Return a human readable representation of a Dot::Node object. | |
|
inlineexplicit |
This constructor creates a new Node object from the parameter thing, which is converted to a string (using std::to_string if thing is not already a std::string) by the constructor.
The newly constructed Node has no attributes set.
| Thing | the type of the argument. |
| thing | the object whose string representation will be the name of the node. |
|
inline |
This function adds a new attribute, or replaces the value of an existing attribute of a Node. The arguments key and val are converted to std::string (unless they are std::string, std::string_view, or char const* already).
| Thing1 | the type of the first argument. |
| Thing2 | the type of the second argument. |
| key | the name of the attribute. |
| val | the value of the attribute. |
this.key or val are valid in DOT; see the Graphviz documentation for more details.
|
Return a human readable representation of a Dot::Node object.
| n | the Dot::Node object. |