Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
EmbedderModule.h
Go to the documentation of this file.
1
32#pragma once
33
34#include <ogdf/basic/Module.h>
37
38namespace ogdf {
39
50public:
53
54 virtual ~EmbedderModule() { }
55
64 if (G.numberOfNodes() > 1 && G.numberOfEdges() > 1) {
66 doCall(G, adjExternal);
67 } else if (G.numberOfEdges() == 1) {
68 adjExternal = G.firstEdge()->adjSource();
69 }
70 };
71
74
76protected:
82 virtual void doCall(Graph& G, adjEntry& adjExternal) = 0;
83};
84
85}
Declares base class for all module types.
Declares base class for modules with timeout functionality.
Class for adjacency list elements.
Definition Graph_d.h:79
Base class for embedder algorithms.
EmbedderModule()
Initializes an embedder module.
void call(Graph &G, adjEntry &adjExternal)
Calls the embedder algorithm for graph G.
void operator()(Graph &G, adjEntry &adjExternal)
Calls the embedder algorithm for graph G.
virtual void doCall(Graph &G, adjEntry &adjExternal)=0
Calls the embedder algorithm for graph G.
Data type for general directed graphs (adjacency list representation).
Definition Graph_d.h:521
Base class for modules.
Definition Module.h:47
class for timeout funtionality.
Definition Timeouter.h:46
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition config.h:101
Declaration of extended graph algorithms.
bool isPlanar(const Graph &G)
Returns true, if G is planar, false otherwise.
#define OGDF_MALLOC_NEW_DELETE
Makes the class use malloc for memory allocation.
Definition memory.h:91
#define OGDF_ASSERT(expr)
Assert condition expr. See doc/build.md for more information.
Definition basic.h:41
static MultilevelBuilder * getDoubleFactoredZeroAdjustedMerger()
The namespace for all OGDF objects.