Open
Graph Drawing
Framework

 v. snapshot-2017-02-16
 

VariableEmbeddingInserterBase.h
Go to the documentation of this file.
1 
32 #pragma once
33 
36 
37 
38 namespace ogdf {
39 
42 {
43 public:
46  : m_rrOption(RemoveReinsertType::None),
47  m_percentMostCrossed(25)
48  {}
49 
52  : EdgeInsertionModule(inserter),
53  m_rrOption(inserter.m_rrOption),
54  m_percentMostCrossed(inserter.m_percentMostCrossed)
55  {}
56 
59  {
60  m_rrOption = inserter.m_rrOption;
61  m_percentMostCrossed = inserter.m_percentMostCrossed;
62  return *this;
63  }
64 
67 
73  void removeReinsert(RemoveReinsertType rrOption) {
75  m_rrOption = rrOption;
76  }
77 
80  return m_rrOption;
81  }
82 
84 
88  void percentMostCrossed(double percent) {
89  m_percentMostCrossed = percent;
90  }
91 
93  double percentMostCrossed() const {
94  return m_percentMostCrossed;
95  }
96 
102  int runsPostprocessing() const {
104  return m_runsPostprocessing;
105  }
106 
107 protected:
109  void runsPostprocessing(int runs) {
110  m_runsPostprocessing = runs;
111  }
112 
114 
115 private:
118 
120 };
121 
122 } // end namespace ogdf
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:99
Declaration of interface for edge insertion algorithms.
RemoveReinsertType
The postprocessing method for edge insertion algorithms.
RemoveReinsertType m_rrOption
The remove-reinsert method.
Interface for edge insertion algorithms.
VariableEmbeddingInserterBase()
Creates an instance of variable embedding edge inserter with default settings.
Definition of RemoveReinsertType (used for postprocessing in edge insertion algorithms).
Common parameter functionality for ogdf::VariableEmbeddingInserter and ogdf::VariableEmbeddingInserte...
VariableEmbeddingInserterBase & operator=(const VariableEmbeddingInserterBase &inserter)
Assignment operator. Copies option settings only.
void runsPostprocessing(int runs)
Sets the number of runs performed by the remove-reinsert method.
RemoveReinsertType removeReinsert() const
Returns the current setting of the remove-reinsert postprocessing method.
double percentMostCrossed() const
Returns the current setting of option percentMostCrossed.
int m_runsPostprocessing
Runs of remove-reinsert method.
VariableEmbeddingInserterBase(const VariableEmbeddingInserterBase &inserter)
Creates an instance of variable embedding inserter with the same settings as inserter.
void percentMostCrossed(double percent)
Sets the option percentMostCrossed to percent.
double m_percentMostCrossed
The portion of most crossed edges considered.
The namespace for all OGDF objects.