Open
Graph Drawing
Framework

 v. 2020.02 (Catalpa)
 

GraphML.h
Go to the documentation of this file.
1 
32 #pragma once
33 
34 #include <ogdf/basic/Graph.h>
36 #include <ogdf/basic/HashArray.h>
37 #include <string>
38 
39 namespace ogdf {
40 namespace graphml {
41 
42 enum class Attribute {
43  NodeLabel = 0,
44  EdgeLabel,
45 
46  X, Y, Z,
47  Width, Height,
48  Size, // Gephi compatibility (size = max(width, height)).
49  Shape,
50 
51  NodeLabelX,
52  NodeLabelY,
53  NodeLabelZ,
54 
64  R, G, B, // Gephi compatibility (fill compounds).
65 
66  NodeWeight,
67  EdgeWeight,
68 
69  NodeType,
70  EdgeType,
71 
72  NodeId,
73  Template,
74 
75  EdgeArrow,
77  EdgeBends,
78 
79  Unknown // Has to be the last one!
80 };
81 
82 std::string toString(const Attribute &attr);
83 std::string toString(const Shape &shape);
84 std::string toString(const EdgeArrow &arrow);
85 std::string toString(const Graph::NodeType &type);
86 std::string toString(const Graph::EdgeType &type);
87 
88 Attribute toAttribute(const std::string &str);
89 Shape toShape(const std::string &str);
90 EdgeArrow toArrow(const std::string &str);
91 Graph::NodeType toNodeType(const std::string &str);
92 Graph::EdgeType toEdgeType(const std::string &str);
93 
94 }
95 }
Declaration and implementation of HashArray class.
Declaration of class GraphAttributes which extends a Graph by additional attributes.
std::string toString(const Attribute &attr)
EdgeArrow
Types for edge arrows.
Definition: graphics.h:186
Shape
Types for node shapes.
Definition: graphics.h:149
EdgeType
The type of edges (only used in derived classes).
Definition: Graph_d.h:538
Includes declaration of graph class.
Shape toShape(const std::string &str)
Graph::NodeType toNodeType(const std::string &str)
Attribute toAttribute(const std::string &str)
EdgeArrow toArrow(const std::string &str)
The namespace for all OGDF objects.
Graph::EdgeType toEdgeType(const std::string &str)
NodeType
The type of nodes.
Definition: Graph_d.h:545