Open
Graph Drawing
Framework

 v.2010.10
 

Public Member Functions | Protected Member Functions | Private Attributes

ogdf::CrossingMinimizationModule Class Reference

Interface for crossing minimization algorithms. More...

#include <ogdf/module/CrossingMinimizationModule.h>

Inheritance diagram for ogdf::CrossingMinimizationModule:
ogdf::Module ogdf::Timeouter ogdf::SubgraphPlanarizer

List of all members.

Public Member Functions

 CrossingMinimizationModule ()
 Initializes a crossing minimization module.
virtual ~CrossingMinimizationModule ()
ReturnType call (PlanRep &PG, int cc, int &crossingNumber, const EdgeArray< int > *cost=0, const EdgeArray< bool > *forbid=0, const EdgeArray< unsigned int > *subgraphs=0)
 Computes a planarized representation of the input graph.
ReturnType operator() (PlanRep &PG, int cc, int &crossingNumber, const EdgeArray< int > *cost=0, const EdgeArray< bool > *forbid=0, const EdgeArray< unsigned int > *const subgraphs=0)
 Computes a planarized representation of the input graph (shorthand for call).
bool useCost () const
 Returns true iff edge costs are given.
bool useForbid () const
 Returns true iff forbidden edges are given.
bool useSubgraphs () const
void * operator new (size_t nBytes)
void * operator new (size_t, void *p)
void operator delete (void *p, size_t nBytes)

Protected Member Functions

virtual ReturnType doCall (PlanRep &PG, int cc, const EdgeArray< int > &cost, const EdgeArray< bool > &forbid, const EdgeArray< unsigned int > &subgraphs, int &crossingNumber)=0
 Actual algorithm call that needs to be implemented by derived classed.

Private Attributes

bool m_useCost
 True iff edge costs are given.
bool m_useForbid
 True iff forbidden edges are given.
bool m_useSubgraphs

Detailed Description

Interface for crossing minimization algorithms.

Definition at line 70 of file CrossingMinimizationModule.h.


Constructor & Destructor Documentation

ogdf::CrossingMinimizationModule::CrossingMinimizationModule (  )  [inline]

Initializes a crossing minimization module.

Definition at line 74 of file CrossingMinimizationModule.h.

virtual ogdf::CrossingMinimizationModule::~CrossingMinimizationModule (  )  [inline, virtual]

Definition at line 77 of file CrossingMinimizationModule.h.


Member Function Documentation

ReturnType ogdf::CrossingMinimizationModule::call ( PlanRep PG,
int  cc,
int &  crossingNumber,
const EdgeArray< int > *  cost = 0,
const EdgeArray< bool > *  forbid = 0,
const EdgeArray< unsigned int > *  subgraphs = 0 
) [inline]

Computes a planarized representation of the input graph.

Parameters:
PG represents the input graph as well as the computed planarized representation after the call. PG 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.
cc is the number of the connected component in PG that is considered.
crossingNumber is assigned the number of crossings.
forbid points to an edge array indicating which edges are not allowed to be crossed, i.e., (*forbid)[e] = true. If forbid = 0, no edges are forbidden.
cost points to an edge array that gives the cost of each edge. If cost = 0, all edges have cost 1.
subgraphs 
Returns:
the status of the result.

Definition at line 97 of file CrossingMinimizationModule.h.

virtual ReturnType ogdf::CrossingMinimizationModule::doCall ( PlanRep PG,
int  cc,
const EdgeArray< int > &  cost,
const EdgeArray< bool > &  forbid,
const EdgeArray< unsigned int > &  subgraphs,
int &  crossingNumber 
) [protected, pure virtual]

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

Parameters:
PG represents the input graph as well as the computed planarized representation after the call. PG is initialzed as a PlanRep of the input graph and has to be modified so that it represents the planarized representation (crossings are replaced by dummy vertices with degree four).
cc is the number of the connected component in PG that is considered.
crossingNumber is assigned the number of crossings.
forbid points to an edge array indicating which edges are not allowed to be crossed, i.e., (*forbid)[e] = true.
cost points to an edge array that gives the cost of each edge.
subgraphs 
Returns:
the status of the result.
void ogdf::CrossingMinimizationModule::operator delete ( void *  p,
size_t  nBytes 
) [inline]

Definition at line 162 of file CrossingMinimizationModule.h.

void* ogdf::CrossingMinimizationModule::operator new ( size_t  ,
void *  p 
) [inline]

Definition at line 162 of file CrossingMinimizationModule.h.

void* ogdf::CrossingMinimizationModule::operator new ( size_t  nBytes  )  [inline]

Definition at line 162 of file CrossingMinimizationModule.h.

ReturnType ogdf::CrossingMinimizationModule::operator() ( PlanRep PG,
int  cc,
int &  crossingNumber,
const EdgeArray< int > *  cost = 0,
const EdgeArray< bool > *  forbid = 0,
const EdgeArray< unsigned int > *const   subgraphs = 0 
) [inline]

Computes a planarized representation of the input graph (shorthand for call).

Definition at line 121 of file CrossingMinimizationModule.h.

bool ogdf::CrossingMinimizationModule::useCost (  )  const [inline]

Returns true iff edge costs are given.

Definition at line 131 of file CrossingMinimizationModule.h.

bool ogdf::CrossingMinimizationModule::useForbid (  )  const [inline]

Returns true iff forbidden edges are given.

Definition at line 134 of file CrossingMinimizationModule.h.

bool ogdf::CrossingMinimizationModule::useSubgraphs (  )  const [inline]

Definition at line 136 of file CrossingMinimizationModule.h.


Member Data Documentation

True iff edge costs are given.

Definition at line 165 of file CrossingMinimizationModule.h.

True iff forbidden edges are given.

Definition at line 166 of file CrossingMinimizationModule.h.


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