50 m_cnClusters = cnClusters;
91 return m_cnClusters == 0 && m_cnEdges == 0;
95 m_cnClusters = m_cnEdges = std::numeric_limits<int>::max();
116 enum class Type { Compound, Node, AuxNode };
120 Adjacency() { m_u =
nullptr; m_v =
nullptr; m_weight = 0; }
136 ClusterCrossing() { m_uc =
nullptr; m_u =
nullptr; m_cNode =
nullptr; m_uNode =
nullptr; }
159 m_type = Type::Compound;
169 m_origCluster =
nullptr;
190 int pos()
const {
return m_pos; }
203 void store() { m_storedChild = m_child; }
207 void removeAuxChildren();
247 void simplifyAdjacencies();
248 void removeAuxNodes();
275 void createClusterTree(
cluster cOrig);
288 enum class NodeType { Node, ClusterTop, ClusterBottom, Dummy, ClusterTopBottom };
316 return e->
source() != origNode(chain(e).front()->source());
320 return type(v) == NodeType::Dummy && v->
outdeg() == 1;
331 RCCrossings reduceCrossings(
int i,
bool dirTopDown);
332 void storeCurrentPos();
336 void removeTopBottomEdges();
349 void assignAeLevel(
cluster c,
int &count);
355 void assignPos(
const LHTreeNode *vNode,
int &count);
358 void computeRanking();
359 void createDummyNodes();
360 void createVirtualClusters();
361 void createVirtualClusters(
366 void removeAuxNodes();
EdgeArray< edge > m_origEdge
bool isVirtual(cluster c) const
void setChild(int i, LHTreeNode *p)
bool verticalSegment(edge e) const
The parameterized class Array implements dynamic arrays of type E.
Derived class of GraphObserver providing additional functionality to handle clustered graphs...
ClusterArray< node > m_bottomNode
EdgeArray< bool > m_vertical
node top(cluster cOrig) const
NodeArray< int > m_aeLevel
cluster copy(cluster cOrig) const
Data type for general directed graphs (adjacency list representation).
Array< LHTreeNode * > m_storedChild
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Array< LHTreeNode * > m_child
Array< ENGLayer > m_layer
const LHTreeNode * root() const
cluster parent()
Returns the parent of the cluster.
void setRoot(LHTreeNode *r)
edge origEdge(edge e) const
cluster originalCluster(node v) const
Represents layer in an extended nesting graph.
static int compare(const RCCrossings &x, const RCCrossings &y)
RCCrossings(int cnClusters, int cnEdges)
int outdeg() const
Returns the outdegree of the node.
int topRank(cluster c) const
RCCrossings operator-(const RCCrossings &cr) const
void setParent(LHTreeNode *p)
Dynamic arrays indexed with edges.
node origNode(node v) const
int numberOfLayers() const
bool operator<=(const RCCrossings &cr) const
ClusterArray< int > m_topRank
int aeLevel(node v) const
node bottom(cluster cOrig) const
cluster parent(cluster c) const
ClusterArray< int > m_bottomRank
ClusterArray< cluster > m_mark
NodeArray< int > m_auxDeg
Adjacency(node u, LHTreeNode *vNode, int weight=1)
List< ClusterCrossing > m_upperClusterCrossing
Representation of clustered graphs.
cluster original(cluster cCopy) const
cluster originalCluster() const
const ENGLayer & layer(int i) const
bool isLongEdgeDummy(node v) const
LHTreeNode(LHTreeNode *parent, node v, Type t=Type::Node)
Declaration and implementation of EdgeArray class.
int numberOfChildren() const
const ClusterGraphCopy & getClusterGraph() const
bool isReversed(edge e) const
Doubly linked lists (maintaining the length of the list).
const ClusterGraph & getOriginalClusterGraph() const
const LHTreeNode * parent() const
ClusterArray< node > m_topNode
cluster parent(node v) const
RCCrossings & setInfinity()
Class for the representation of edges.
int bottomRank(cluster c) const
Dynamic arrays indexed with clusters.
EdgeArray< List< edge > > m_copyEdge
NodeArray< node > m_origNode
const ClusterGraph & getOriginalClusterGraph() const
Class for the representation of nodes.
const LHTreeNode * layerHierarchyTree(int i) const
const LHTreeNode * down() const
#define OGDF_NEW_DELETE
Makes the class use OGDF's memory allocator.
const LHTreeNode * up() const
const ClusterGraph * m_pCG
SListPure< cluster > m_markedClusters
RCCrossings operator+(const RCCrossings &cr) const
ClusterArray< LHTreeNode * > m_markTree
List< Adjacency > m_lowerAdj
ClusterArray< cluster > m_original
Representation of clusters in a clustered graph.
NodeArray< bool > m_aeVisited
SListPure< cluster > m_markedClustersTree
NodeType type(node v) const
List< ClusterCrossing > m_lowerClusterCrossing
NodeArray< NodeType > m_type
const ExtendedNestingGraph * m_pH
node source() const
Returns the source node of the edge.
Declaration and implementation of ClusterArray class.
The namespace for all OGDF objects.
LHTreeNode * child(int i)
List< Adjacency > m_upperAdj
RCCrossings & operator+=(const RCCrossings &cr)
LHTreeNode(cluster c, LHTreeNode *up)
const List< edge > & chain(edge e) const
ClusterCrossing(node uc, LHTreeNode *cNode, node u, LHTreeNode *uNode, edge e)
bool operator<(const RCCrossings &cr) const
std::ostream & operator<<(std::ostream &os, const ogdf::Array< E, INDEX > &a)
Prints array a to output stream os.
ClusterArray< cluster > m_copy
const LHTreeNode * child(int i) const