Representation of levels in hierarchies.
More...
#include <ogdf/layered/Level.h>
|
| Level (HierarchyLevels *pLevels, int index, int num) |
| Creates a level with index index in hierarchy pLevels .
|
|
| ~Level () |
|
const Array< node > & | adjNodes (node v) const |
| Returns the (sorted) array of adjacent nodes of v (according to direction()).
|
|
int | high () const override |
| Returns the maximal array index (= size()-1).
|
|
int | index () const |
| Returns the array index of this level in the hierarchy.
|
|
const HierarchyLevels & | levels () const |
| Returns the hierarchy to which this level belongs.
|
|
const node & | operator[] (int i) const override |
| Returns the node at position i .
|
|
node & | operator[] (int i) override |
| Returns the node at position i .
|
|
void | recalcPos () |
|
int | size () const override |
| Returns the number of nodes on this level.
|
|
void | sort (NodeArray< double > &weight) |
| Sorts the nodes according to weight using quicksort.
|
|
void | sort (NodeArray< int > &weight, int minBucket, int maxBucket) |
| Sorts the nodes according to weight using bucket sort.
|
|
void | sortByWeightOnly (NodeArray< double > &weight) |
| Sorts the nodes according to weight (without special placement for "isolated" nodes).
|
|
template<class C > |
void | sortOrder (C &orderComparer) |
| Sorts the nodes according to orderComparer .
|
|
void | swap (int i, int j) |
| Exchanges nodes at position i and j .
|
|
virtual | ~LevelBase () |
|
Representation of levels in hierarchies.
- See also
- Hierarchy, SugiyamaLayout
Definition at line 66 of file Level.h.
◆ Level()
Creates a level with index index
in hierarchy pLevels
.
- Parameters
-
pLevels | is a pointer to the hierarchy to which the created level will belong. |
index | is the index of the level. |
num | is the number of nodes on this level. |
Definition at line 82 of file Level.h.
◆ ~Level()
◆ adjNodes()
Returns the (sorted) array of adjacent nodes of v
(according to direction()).
◆ getIsolatedNodes()
◆ high()
int ogdf::Level::high |
( |
| ) |
const |
|
inlineoverridevirtual |
◆ index()
int ogdf::Level::index |
( |
| ) |
const |
|
inline |
Returns the array index of this level in the hierarchy.
Definition at line 101 of file Level.h.
◆ levels()
Returns the hierarchy to which this level belongs.
Definition at line 107 of file Level.h.
◆ operator[]() [1/2]
const node & ogdf::Level::operator[] |
( |
int |
i | ) |
const |
|
inlineoverridevirtual |
◆ operator[]() [2/2]
node & ogdf::Level::operator[] |
( |
int |
i | ) |
|
|
inlineoverridevirtual |
◆ recalcPos()
void ogdf::Level::recalcPos |
( |
| ) |
|
◆ setIsolatedNodes()
◆ size()
int ogdf::Level::size |
( |
| ) |
const |
|
inlineoverridevirtual |
◆ sort() [1/2]
void ogdf::Level::sort |
( |
NodeArray< double > & |
weight | ) |
|
Sorts the nodes according to weight
using quicksort.
◆ sort() [2/2]
void ogdf::Level::sort |
( |
NodeArray< int > & |
weight, |
|
|
int |
minBucket, |
|
|
int |
maxBucket |
|
) |
| |
Sorts the nodes according to weight
using bucket sort.
◆ sortByWeightOnly()
void ogdf::Level::sortByWeightOnly |
( |
NodeArray< double > & |
weight | ) |
|
Sorts the nodes according to weight
(without special placement for "isolated" nodes).
◆ sortOrder()
template<class C >
void ogdf::Level::sortOrder |
( |
C & |
orderComparer | ) |
|
|
inline |
Sorts the nodes according to orderComparer
.
Definition at line 123 of file Level.h.
◆ swap()
void ogdf::Level::swap |
( |
int |
i, |
|
|
int |
j |
|
) |
| |
Exchanges nodes at position i
and j
.
◆ HierarchyLayoutModule
◆ HierarchyLevels
◆ LayerBasedUPRLayout
◆ operator<<
std::ostream & operator<< |
( |
std::ostream & |
os, |
|
|
const Level & |
L |
|
) |
| |
|
friend |
◆ m_index
The index of this level.
Definition at line 73 of file Level.h.
◆ m_nodes
The nodes on this level.
Definition at line 71 of file Level.h.
◆ m_pLevels
The hierarchy to which this level belongs.
Definition at line 72 of file Level.h.
The documentation for this class was generated from the following file: