Open
Graph Drawing
Framework

 v. 2022.02 (Dogwood)
 

ogdf::PQBasicKey< T, X, Y > Class Template Referenceabstract

#include <ogdf/basic/pqtree/PQBasicKey.h>

+ Inheritance diagram for ogdf::PQBasicKey< T, X, Y >:

Public Member Functions

 PQBasicKey ()
 Constructor. More...
 
PQNode< T, X, Y > * nodePointer ()
 The function nodePointer() returns a pointer to an element of type PQNode. More...
 
virtual std::ostream & print (std::ostream &os)
 The function print() is a virtual function, that can be overloaded by the user in order to print out the information stored at any of the derived classes. More...
 
void setNodePointer (PQNode< T, X, Y > *pqNode)
 The function setNodePointer() sets the private member m_nodePointer. More...
 
virtual X userStructInfo ()=0
 Returns the information of any node. More...
 
virtual Y userStructInternal ()=0
 Returns the information of any internal node. More...
 
virtual T userStructKey ()=0
 Returns the key of a leaf. More...
 
- Public Member Functions inherited from ogdf::PQBasicKeyRoot
 PQBasicKeyRoot ()
 
 ~PQBasicKeyRoot ()
 

Private Attributes

PQNode< T, X, Y > * m_nodePointer
 Stores the adress of a node. More...
 

Detailed Description

template<class T, class X, class Y>
class ogdf::PQBasicKey< T, X, Y >

Definition at line 111 of file PQBasicKey.h.

Constructor & Destructor Documentation

◆ PQBasicKey()

template<class T , class X , class Y >
ogdf::PQBasicKey< T, X, Y >::PQBasicKey ( )
inline

Constructor.

Definition at line 114 of file PQBasicKey.h.

Member Function Documentation

◆ nodePointer()

template<class T , class X , class Y >
PQNode<T,X,Y>* ogdf::PQBasicKey< T, X, Y >::nodePointer ( )
inline

The function nodePointer() returns a pointer to an element of type PQNode.

This element can be either of type leaf or PQInternalNode. PQBasicKey, or rather its derived classes store informations of this PQNode. The user is able identify with the help of this function for every information its corresponding node. Nevertheless, the private member m_nodePointer that stores the pointer to this member is not set within the PQ-tree, unless it is a derived class template of type leafKey.

Setting the m_nodePointer has to be done explicitly by the client with the help of the function setNodePointer(). This offers as much freedom to the client as possible, since this enables the client to keep control over the informations stored at different nodes and to access nodes with specified informations in constant time.

Definition at line 135 of file PQBasicKey.h.

◆ print()

template<class T , class X , class Y >
virtual std::ostream& ogdf::PQBasicKey< T, X, Y >::print ( std::ostream &  os)
inlinevirtual

The function print() is a virtual function, that can be overloaded by the user in order to print out the information stored at any of the derived classes.

Deriving this function, the user can choose any format for printing out the information. Currently, the return value of the function print() is an empty string.

Reimplemented in ogdf::booth_lueker::PlanarLeafKey< X >, and ogdf::booth_lueker::PlanarLeafKey< booth_lueker::IndInfo * >.

Definition at line 144 of file PQBasicKey.h.

◆ setNodePointer()

template<class T , class X , class Y >
void ogdf::PQBasicKey< T, X, Y >::setNodePointer ( PQNode< T, X, Y > *  pqNode)
inline

The function setNodePointer() sets the private member m_nodePointer.

The private member m_nodePointer stores the address of the corresponding node in the PQTree. Using this function enables the client to identify certain informations with a node in the PQ-tree.

Definition at line 153 of file PQBasicKey.h.

◆ userStructInfo()

template<class T , class X , class Y >
virtual X ogdf::PQBasicKey< T, X, Y >::userStructInfo ( )
pure virtual

◆ userStructInternal()

template<class T , class X , class Y >
virtual Y ogdf::PQBasicKey< T, X, Y >::userStructInternal ( )
pure virtual

◆ userStructKey()

template<class T , class X , class Y >
virtual T ogdf::PQBasicKey< T, X, Y >::userStructKey ( )
pure virtual

Member Data Documentation

◆ m_nodePointer

template<class T , class X , class Y >
PQNode<T,X,Y>* ogdf::PQBasicKey< T, X, Y >::m_nodePointer
private

Stores the adress of a node.

This node has to be specified by the client via the function setNodePointer.

Definition at line 168 of file PQBasicKey.h.


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