template<class E = empty_edget>
class graph_nodet< E >
This class represents a node in a directed graph.
See grapht for more information.
Definition at line 34 of file graph.h.
template<class E = empty_edget>
Node with attributes suitable for Graphviz DOT format.
Derived types may override this function to produce more informative DOT diagrams than the default implementation, which displays only the node index. The return value should be a list of node attributes within square brackets that can be parsed by dot
. Here is a sample implementation for a fictional node type with is_evil()
and is_pink()
functions:
std::stringstream ss;
ss << "[shape=\"" << is_evil() ? "box" : "diamond"
<< "\", color=\"" << is_pink() ? "#e91e63" : "#9c27b0"
<< "\", label=\"this is node " << std::to_string(idx)
<< "\"]";
return ss.str();
Reimplemented in scope_treet::scope_nodet.
Definition at line 80 of file graph.h.