Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

ogdf::UMLCrossingMinimizationModule Class Referenceabstract

Base class for UML crossing minimization algorithms. More...

#include <ogdf/uml/UMLCrossingMinimizationModule.h>

+ Inheritance diagram for ogdf::UMLCrossingMinimizationModule:

Public Member Functions

 UMLCrossingMinimizationModule ()
 Initializes a UML crossing minimization module (default constructor). More...
 
 UMLCrossingMinimizationModule (const UMLCrossingMinimizationModule &cmm)
 Initializes a UML crossing minimization module (copy constructor). More...
 
virtual ~UMLCrossingMinimizationModule ()
 Destructor. More...
 
ReturnType call (PlanRepUML &prUML, int cc, int &crossingNumber, const EdgeArray< int > *pCostOrig=nullptr)
 Computes a planarized representation of the input graph. More...
 
virtual UMLCrossingMinimizationModuleclone () const =0
 Returns a new instance of the UML crossing minimization module with the same option settings. More...
 
ReturnType operator() (PlanRepUML &prUML, int cc, int &crossingNumber, const EdgeArray< int > *pCostOrig=nullptr)
 Computes a planarized representation of the input graph. More...
 
- Public Member Functions inherited from ogdf::Module
 Module ()
 Initializes a module. More...
 
virtual ~Module ()
 
- Public Member Functions inherited from ogdf::Timeouter
 Timeouter ()
 timeout is turned of by default More...
 
 Timeouter (bool t)
 timeout is turned off (false) or on (true) (with 0 second) More...
 
 Timeouter (const Timeouter &t)
 
 Timeouter (double t)
 timeout is set to the given value (seconds) More...
 
 ~Timeouter ()
 
bool isTimeLimit () const
 returns whether any time limit is set or not More...
 
Timeouteroperator= (const Timeouter &t)
 
double timeLimit () const
 returns the current time limit for the call More...
 
void timeLimit (bool t)
 shorthand to turn timelimit off or on (with 0 seconds) More...
 
void timeLimit (double t)
 sets the time limit for the call (in seconds); <0 means no limit. More...
 

Static Public Member Functions

static bool checkCrossingGens (const PlanRepUML &prUML)
 Checks if the planarized represenation contains crossing generalizations. More...
 
- Static Public Member Functions inherited from ogdf::Module
static bool isSolution (ReturnType ret)
 Returns true iff ret indicates that the module returned a feasible solution. More...
 

Protected Member Functions

virtual ReturnType doCall (PlanRepUML &prUML, int cc, const EdgeArray< int > *pCostOrig, int &crossingNumber)=0
 Actual algorithm call that needs to be implemented by derived classes. More...
 

Additional Inherited Members

- Public Types inherited from ogdf::Module
enum  ReturnType { ReturnType::Feasible, ReturnType::Optimal, ReturnType::NoFeasibleSolution, ReturnType::TimeoutFeasible, ReturnType::TimeoutInfeasible, ReturnType::Error }
 The return type of a module. More...
 
- Protected Attributes inherited from ogdf::Timeouter
double m_timeLimit
 Time limit for module calls (< 0 means no limit). More...
 

Detailed Description

Base class for UML crossing minimization algorithms.

Definition at line 41 of file UMLCrossingMinimizationModule.h.

Constructor & Destructor Documentation

◆ UMLCrossingMinimizationModule() [1/2]

ogdf::UMLCrossingMinimizationModule::UMLCrossingMinimizationModule ( )
inline

Initializes a UML crossing minimization module (default constructor).

Definition at line 44 of file UMLCrossingMinimizationModule.h.

◆ UMLCrossingMinimizationModule() [2/2]

ogdf::UMLCrossingMinimizationModule::UMLCrossingMinimizationModule ( const UMLCrossingMinimizationModule cmm)
inline

Initializes a UML crossing minimization module (copy constructor).

Definition at line 47 of file UMLCrossingMinimizationModule.h.

◆ ~UMLCrossingMinimizationModule()

virtual ogdf::UMLCrossingMinimizationModule::~UMLCrossingMinimizationModule ( )
inlinevirtual

Destructor.

Definition at line 50 of file UMLCrossingMinimizationModule.h.

Member Function Documentation

◆ call()

ReturnType ogdf::UMLCrossingMinimizationModule::call ( PlanRepUML prUML,
int  cc,
int &  crossingNumber,
const EdgeArray< int > *  pCostOrig = nullptr 
)
inline

Computes a planarized representation of the input graph.

Parameters
prUMLrepresents the input graph as well as the computed planarized representation after the call. prUML has to be initialzed as a PlanRep of the input graph and is modified to obatain the planarized representation (crossings are replaced by dummy vertices with degree four).
ccis the index of the connected component in prUML that is considered.
crossingNumberis assigned the number of crossings.
pCostOrigpoints to an edge array (of the original graph) that gives the cost of each edge. May be a 0-pointer, in which case all edges have cost 1.
Returns
the status of the result.

Definition at line 67 of file UMLCrossingMinimizationModule.h.

◆ checkCrossingGens()

static bool ogdf::UMLCrossingMinimizationModule::checkCrossingGens ( const PlanRepUML prUML)
static

Checks if the planarized represenation contains crossing generalizations.

◆ clone()

virtual UMLCrossingMinimizationModule* ogdf::UMLCrossingMinimizationModule::clone ( ) const
pure virtual

Returns a new instance of the UML crossing minimization module with the same option settings.

Implemented in ogdf::SubgraphPlanarizerUML.

◆ doCall()

virtual ReturnType ogdf::UMLCrossingMinimizationModule::doCall ( PlanRepUML prUML,
int  cc,
const EdgeArray< int > *  pCostOrig,
int &  crossingNumber 
)
protectedpure virtual

Actual algorithm call that needs to be implemented by derived classes.

Parameters
prUMLrepresents the input graph as well as the computed planarized representation after the call. prUML has to be initialzed as a PlanRep of the input graph and is modified to obatain the planarized representation (crossings are replaced by dummy vertices with degree four).
ccis the index of the connected component in prUML that is considered.
crossingNumberis assigned the number of crossings.
pCostOrigpoints to an edge array (of the original graph) that gives the cost of each edge. May be a 0-pointer, in which case all edges have cost 1.
Returns
the status of the result.

Implemented in ogdf::SubgraphPlanarizerUML.

◆ operator()()

ReturnType ogdf::UMLCrossingMinimizationModule::operator() ( PlanRepUML prUML,
int  cc,
int &  crossingNumber,
const EdgeArray< int > *  pCostOrig = nullptr 
)
inline

Computes a planarized representation of the input graph.

Parameters
prUMLrepresents the input graph as well as the computed planarized representation after the call. prUML has to be initialzed as a PlanRep of the input graph and is modified to obatain the planarized representation (crossings are replaced by dummy vertices with degree four).
ccis the index of the connected component in prUML that is considered.
crossingNumberis assigned the number of crossings.
pCostOrigpoints to an edge array (of the original graph) that gives the cost of each edge. May be a 0-pointer, in which case all edges have cost 1.
Returns
the status of the result.

Definition at line 84 of file UMLCrossingMinimizationModule.h.


The documentation for this class was generated from the following file: