Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
LayerByLayerSweep.h
Go to the documentation of this file.
1
33#pragma once
34
38
39namespace ogdf {
40
41class SugiyamaLayout;
42
59public:
61 int& nCrossings);
62
65 int& nCrossings) override {
66 const Hierarchy& constH = H;
67 return reduceCrossings(sugi, constH, nCrossings);
68 }
69
72
73 virtual ~LayerByLayerSweep() { }
74
76 virtual LayerByLayerSweep* clone() const = 0;
77
83 virtual void init(const HierarchyLevels& levels) { }
84
91 virtual void call(Level& L) = 0;
92
99 void operator()(Level& L) { call(L); }
100
102 virtual void cleanup() override { }
103
104
105 class CrossMinMaster;
106 class CrossMinWorker;
107
109};
110
111}
Declaration of Hierarchy class.
Declaration of HierarchyLevels class.
Declaration of interface for two-layer crossing minimization algorithms.
Representation of proper hierarchies used by Sugiyama-layout.
Definition Hierarchy.h:43
Representation of proper hierarchies used by Sugiyama-layout.
Interface of two-layer crossing minimization algorithms.
virtual void call(Level &L)=0
Performs crossing minimization for level L.
virtual void cleanup() override
Performs clean-up.
virtual const HierarchyLevels * reduceCrossings(const SugiyamaLayout &sugi, Hierarchy &H, int &nCrossings) override
Template method implementation of reduceCrossings from LayeredCrossMinModule.
virtual LayerByLayerSweep * clone() const =0
Returns a new instance of the two-layer crossing minimization module with the same option settings.
LayerByLayerSweep()
Initializes a two-layer crossing minimization module.
virtual void init(const HierarchyLevels &levels)
Initializes the crossing minimization module for hierarchy levels levels.
virtual const HierarchyLevels * reduceCrossings(const SugiyamaLayout &sugi, const Hierarchy &H, int &nCrossings)
void operator()(Level &L)
Performs crossing minimization for level L.
Interface of crossing minimization algorithms for layered graphs.
Representation of levels in hierarchies.
Definition Level.h:60
Sugiyama's layout algorithm.
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition config.h:101
#define OGDF_MALLOC_NEW_DELETE
Makes the class use malloc for memory allocation.
Definition memory.h:91
static MultilevelBuilder * getDoubleFactoredZeroAdjustedMerger()
The namespace for all OGDF objects.