Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
BarycenterHeuristic.h
Go to the documentation of this file.
1
32#pragma once
33
34#include <ogdf/basic/Graph.h>
36#include <ogdf/basic/basic.h>
40
41namespace ogdf {
42class Level;
43
45
49public:
52
55
57 virtual LayerByLayerSweep* clone() const override { return new BarycenterHeuristic(*this); }
58
60 virtual void init(const HierarchyLevels& levels) override { m_weight.init(levels.hierarchy()); }
61
63 virtual void call(Level& L) override;
64
66 virtual void cleanup() override { m_weight.init(); }
67
68private:
70};
71
72}
Includes declaration of graph class.
Declaration of graph copy classes.
Declaration of Hierarchy class.
Declaration of HierarchyLevels class.
Declaration of interface for two-layer crossing minimization algorithms.
Basic declarations, included by all source files.
The barycenter heuristic for 2-layer crossing minimization.
virtual LayerByLayerSweep * clone() const override
Returns a new instance of the barycenter heuristic with the same option settings.
virtual void call(Level &L) override
Calls the barycenter heuristic for level L.
BarycenterHeuristic(const BarycenterHeuristic &crossMin)
Creates a new instance of the barycenter heuristic.
NodeArray< double > m_weight
The barycenter weight of the nodes.
virtual void init(const HierarchyLevels &levels) override
Initializes crossing minimization for hierarchy H.
virtual void cleanup() override
Does some clean-up after calls.
BarycenterHeuristic()
Creates a new instance of the barycenter heuristic.
Representation of proper hierarchies used by Sugiyama-layout.
const Hierarchy & hierarchy() const override
Interface of two-layer crossing minimization algorithms.
Representation of levels in hierarchies.
Definition Level.h:66
RegisteredArray for nodes, edges and adjEntries of a graph.
Definition Graph_d.h:659
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF dynamic library (shared object / DLL),...
Definition config.h:117
The namespace for all OGDF objects.