Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

PQBasicKey.h
Go to the documentation of this file.
1 
32 #pragma once
33 
35 
36 namespace ogdf {
37 
108 template<class T, class X, class Y>
109 class PQNode;
110 
111 template<class T, class X, class Y>
112 class PQBasicKey : public PQBasicKeyRoot {
113 public:
115  PQBasicKey() : m_nodePointer(nullptr) { }
116 
137 
145  virtual std::ostream& print(std::ostream& os) { return os; }
146 
154  void setNodePointer(PQNode<T, X, Y>* pqNode) { m_nodePointer = pqNode; }
155 
157  virtual T userStructKey() = 0;
158 
160  virtual X userStructInfo() = 0;
161 
163  virtual Y userStructInternal() = 0;
164 
165 private:
170 };
171 
172 }
ogdf
The namespace for all OGDF objects.
Definition: AugmentationModule.h:36
ogdf::PQBasicKey::userStructInfo
virtual X userStructInfo()=0
Returns the information of any node.
ogdf::PQBasicKey::m_nodePointer
PQNode< T, X, Y > * m_nodePointer
Stores the adress of a node.
Definition: PQBasicKey.h:169
PQBasicKeyRoot.h
Declaration and implementation of the class PQBasicKeyRoot.
ogdf::PQBasicKey::setNodePointer
void setNodePointer(PQNode< T, X, Y > *pqNode)
The function setNodePointer() sets the private member m_nodePointer.
Definition: PQBasicKey.h:154
ogdf::PQBasicKey::userStructInternal
virtual Y userStructInternal()=0
Returns the information of any internal node.
ogdf::PQBasicKey::print
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 ...
Definition: PQBasicKey.h:145
ogdf::PQBasicKey::userStructKey
virtual T userStructKey()=0
Returns the key of a leaf.
ogdf::PQBasicKey::nodePointer
PQNode< T, X, Y > * nodePointer()
The function nodePointer() returns a pointer to an element of type PQNode.
Definition: PQBasicKey.h:136
ogdf::PQBasicKey::PQBasicKey
PQBasicKey()
Constructor.
Definition: PQBasicKey.h:115
ogdf::PQBasicKey
Definition: PQBasicKey.h:112
ogdf::PQBasicKeyRoot
The class PQBasicKeyRoot is used as a base class of the class template basicKey.
Definition: PQBasicKeyRoot.h:44
ogdf::PQNode
The class template PQBasicKey is an abstract base class.
Definition: PQBasicKey.h:109