|
Jlm
|
#include <GraphWriter.hpp>


Public Member Functions | |
| ~InOutNode () override=default | |
| void | SetShape (std::string) override |
| InputPort & | CreateInputPort () |
| size_t | NumInputPorts () const |
| InputPort & | GetInputPort (size_t index) |
| OutputPort & | CreateOutputPort () |
| size_t | NumOutputPorts () const |
| OutputPort & | GetOutputPort (size_t index) |
| Graph & | CreateSubgraph () |
| size_t | NumSubgraphs () const |
| Graph & | GetSubgraph (size_t index) |
| void | SetHtmlTableAttribute (std::string name, std::string value) |
| void | SetFillColor (std::string color) override |
| void | Finalize () override |
| void | OutputSubgraphs (std::ostream &out, OutputFormat format, size_t indent) const override |
| void | OutputASCII (std::ostream &out, size_t indent) const override |
| void | OutputDot (std::ostream &out, size_t indent) const override |
| void | outputJson (std::ostream &out, size_t indent) const override |
Public Member Functions inherited from jlm::util::graph::Node | |
| ~Node () override=default | |
| const char * | GetIdPrefix () const override |
| Node & | GetNode () override |
| Graph & | GetGraph () override |
| void | OutputDotPortId (std::ostream &out) const override |
Public Member Functions inherited from jlm::util::graph::Port | |
| ~Port () override=default | |
| virtual bool | CanBeEdgeHead () const |
| virtual bool | CanBeEdgeTail () const |
| const std::vector< Edge * > & | GetConnections () const |
| bool | HasOutgoingEdges () const |
| bool | HasIncomingEdges () const |
| void | OutputIncomingEdgesASCII (std::ostream &out) const |
Public Member Functions inherited from jlm::util::graph::GraphElement | |
| virtual | ~GraphElement ()=default |
| GraphElement () | |
| GraphElement (const GraphElement &other)=delete | |
| GraphElement (GraphElement &&other)=delete | |
| GraphElement & | operator= (const GraphElement &other)=delete |
| GraphElement & | operator= (GraphElement &&other)=delete |
| void | PrintFullId (std::ostream &out) const |
| std::string | GetFullId () const |
| const Graph & | GetGraph () const |
| void | SetLabel (std::string label) |
| void | AppendToLabel (std::string_view text, std::string_view sep="\n") |
| bool | HasLabel () const |
| const std::string & | GetLabel () const |
| std::string_view | GetLabelOr (std::string_view otherwise) const |
| size_t | GetUniqueIdSuffix () const |
| template<typename T > | |
| void | SetProgramObject (const T &object) |
| void | RemoveProgramObject () |
| bool | HasProgramObject () const noexcept |
| uintptr_t | GetProgramObject () const noexcept |
| void | SetAttribute (const std::string &attribute, std::string value) |
| void | SetAttributeObject (const std::string &attribute, uintptr_t object) |
| template<typename T > | |
| void | SetAttributeObject (const std::string &attribute, const T &object) |
| void | SetAttributeGraphElement (const std::string &attribute, const GraphElement &element) |
| bool | HasAttribute (const std::string &attribute) const |
| std::optional< std::string_view > | GetAttributeString (const std::string &attribute) const |
| std::optional< uintptr_t > | GetAttributeObject (const std::string &attribute) const |
| const GraphElement * | GetAttributeGraphElement (const std::string &attribute) const |
| bool | RemoveAttribute (const std::string &attribute) |
| bool | IsFinalized () const |
| void | OutputAttributes (std::ostream &out, AttributeOutputFormat format) const |
| void | outputJsonObjectOpening (std::ostream &out, size_t indent, bool &firstField) const |
Private Member Functions | |
| InOutNode (Graph &graph, size_t inputPorts, size_t outputPorts) | |
Private Attributes | |
| friend | Graph |
| std::unordered_map< std::string, std::string > | HtmlTableAttributes_ |
| std::vector< std::unique_ptr< InputPort > > | InputPorts_ |
| std::vector< std::unique_ptr< OutputPort > > | OutputPorts_ |
| std::vector< Graph * > | SubGraphs_ |
Additional Inherited Members | |
Protected Member Functions inherited from jlm::util::graph::Node | |
| Node (Graph &graph) | |
Protected Member Functions inherited from jlm::util::graph::Port | |
| Port () | |
Class representing a node where data flows into a set of input ports, and results flow out of a set of output ports. For complex operations, the node can also contain one or more sub-graphs.
Definition at line 558 of file GraphWriter.hpp.
|
private |
Definition at line 839 of file GraphWriter.cpp.
|
overridedefault |
| InputPort & jlm::util::graph::InOutNode::CreateInputPort | ( | ) |
Definition at line 856 of file GraphWriter.cpp.
| OutputPort & jlm::util::graph::InOutNode::CreateOutputPort | ( | ) |
Definition at line 877 of file GraphWriter.cpp.
| Graph & jlm::util::graph::InOutNode::CreateSubgraph | ( | ) |
Creates a new subgraph and
Definition at line 898 of file GraphWriter.cpp.
|
overridevirtual |
Claims a unique id suffix for the element, if it doesn't already have one.
Reimplemented from jlm::util::graph::GraphElement.
Definition at line 931 of file GraphWriter.cpp.
| InputPort & jlm::util::graph::InOutNode::GetInputPort | ( | size_t | index | ) |
Definition at line 870 of file GraphWriter.cpp.
| OutputPort & jlm::util::graph::InOutNode::GetOutputPort | ( | size_t | index | ) |
Definition at line 891 of file GraphWriter.cpp.
| Graph & jlm::util::graph::InOutNode::GetSubgraph | ( | size_t | index | ) |
index, which must be lower than NumSubgraphs() Definition at line 912 of file GraphWriter.cpp.
| size_t jlm::util::graph::InOutNode::NumInputPorts | ( | ) | const |
Definition at line 864 of file GraphWriter.cpp.
| size_t jlm::util::graph::InOutNode::NumOutputPorts | ( | ) | const |
Definition at line 885 of file GraphWriter.cpp.
| size_t jlm::util::graph::InOutNode::NumSubgraphs | ( | ) | const |
Definition at line 906 of file GraphWriter.cpp.
|
overridevirtual |
Outputs the node in ASCII format to the ostream out, indented by indent levels. In this format, attributes are ignored, and edges are only included implicitly, by listing the origins of all edges pointing into this node.
Reimplemented from jlm::util::graph::Node.
Definition at line 954 of file GraphWriter.cpp.
|
overridevirtual |
Outputs the node in Dot format to the ostream out, indented by indent levels. This format includes all attributes.
Reimplemented from jlm::util::graph::Node.
Definition at line 995 of file GraphWriter.cpp.
|
overridevirtual |
Outputs the node in JSON format to the ostream out, indented by indent levels. This format includes all attributes.
Reimplemented from jlm::util::graph::Node.
Definition at line 1098 of file GraphWriter.cpp.
|
overridevirtual |
Prints all sub graphs of the node, to the given ostream out, in the given format. All lines printed by this function are indented by at least indent levels. This function is recursive, as sub graphs may have nodes with sub graphs of their own.
Reimplemented from jlm::util::graph::Node.
Definition at line 944 of file GraphWriter.cpp.
|
overridevirtual |
Helper function for setting the background color of the Port using the correct dot attributes.
| color | an X11 color name or an RGB value in hex, prefixed by '#' |
Reimplemented from jlm::util::graph::Node.
Definition at line 925 of file GraphWriter.cpp.
| void jlm::util::graph::InOutNode::SetHtmlTableAttribute | ( | std::string | name, |
| std::string | value | ||
| ) |
Set attributes on the HTML-like table used to render the node in dot. See the GraphViz manual's list of table attributes: https://graphviz.org/doc/info/shapes.html#table
| name | the name of the attribute |
| value | the value the attribute should take |
Definition at line 919 of file GraphWriter.cpp.
|
overridevirtual |
InOutNodes use HTML tables when rendering, so setting the shape is disabled
Reimplemented from jlm::util::graph::Node.
Definition at line 850 of file GraphWriter.cpp.
|
private |
Definition at line 560 of file GraphWriter.hpp.
|
private |
Definition at line 640 of file GraphWriter.hpp.
|
private |
Definition at line 642 of file GraphWriter.hpp.
|
private |
Definition at line 643 of file GraphWriter.hpp.
|
private |
Definition at line 644 of file GraphWriter.hpp.