Data type for general directed graphs (adjacency list representation). More...
#include <ogdf/basic/Graph_d.h>
Inheritance diagram for ogdf::Graph:Public Types | |
| enum | EdgeType { association = 0, generalization = 1, dependency = 2 } |
| The type of edges (only used in derived classes). More... | |
| enum | NodeType { vertex, dummy, generalizationMerger, generalizationExpander, highDegreeExpander, lowDegreeExpander, associationClass } |
| The type of nodes. More... | |
Public Member Functions | |
| Graph () | |
| Constructs an empty graph. | |
| Graph (const Graph &G) | |
| Constructs a graph that is a copy of G. | |
| virtual | ~Graph () |
| Destructor. | |
Access methods | |
| bool | empty () const |
| Returns true iff the graph is empty, i.e., contains no nodes. | |
| int | numberOfNodes () const |
| Returns the number of nodes in the graph. | |
| int | numberOfEdges () const |
| Returns the number of edges in the graph. | |
| int | maxNodeIndex () const |
| Returns the largest used node index. | |
| int | maxEdgeIndex () const |
| Returns the largest used edge index. | |
| int | maxAdjEntryIndex () const |
| Returns the largest used adjEntry index. | |
| int | nodeArrayTableSize () const |
| Returns the table size of node arrays associated with this graph. | |
| int | edgeArrayTableSize () const |
| Returns the table size of edge arrays associated with this graph. | |
| int | adjEntryArrayTableSize () const |
| Returns the table size of adjEntry arrays associated with this graph. | |
| node | firstNode () const |
| Returns the first node in the list of all nodes. | |
| node | lastNode () const |
| Returns the last node in the list of all nodes. | |
| edge | firstEdge () const |
| Returns the first edge in the list of all edges. | |
| edge | lastEdge () const |
| Returns the last edge in the list of all edges. | |
| node | chooseNode () const |
| Returns a randomly chosen node. | |
| edge | chooseEdge () const |
| Returns a randomly chosen edge. | |
| template<class NODELIST > | |
| void | allNodes (NODELIST &nodes) const |
| Returns a list with all nodes of the graph. | |
| template<class EDGELIST > | |
| void | allEdges (EDGELIST &edges) const |
| Returns a list with all edges of the graph. | |
| template<class EDGELIST > | |
| void | adjEdges (node v, EDGELIST &edges) const |
| Returns a list with all edges adjacent to node v. | |
| template<class ADJLIST > | |
| void | adjEntries (node v, ADJLIST &entries) const |
| Returns a list with all entries in the adjacency list of node v. | |
| template<class EDGELIST > | |
| void | inEdges (node v, EDGELIST &edges) const |
| Returns a list with all incoming edges of node v. | |
| template<class EDGELIST > | |
| void | outEdges (node v, EDGELIST &edges) const |
| Returns a list with all outgoing edges of node v. | |
Creation of new nodes and edges | |
| node | newNode () |
| Creates a new node and returns it. | |
| node | newNode (int index) |
| Creates a new node with predefined index and returns it. | |
| edge | newEdge (node v, node w) |
| Creates a new edge (v,w) and returns it. | |
| edge | newEdge (node v, node w, int index) |
| Creates a new edge (v,w) with predefined index and returns it. | |
| edge | newEdge (adjEntry adjSrc, adjEntry adjTgt, Direction dir=ogdf::after) |
| Creates a new edge at predefined positions in the adjacency lists. | |
| edge | newEdge (node v, adjEntry adjTgt) |
| Creates a new edge at predefined positions in the adjacency lists. | |
| edge | newEdge (adjEntry adjSrc, node w) |
| Creates a new edge at predefined positions in the adjacency lists. | |
Removing nodes and edges | |
| void | delNode (node v) |
| Removes node v and all incident edges from the graph. | |
| void | delEdge (edge e) |
| Removes edge e from the graph. | |
| void | clear () |
| Removes all nodes and all edges from the graph. | |
Hiding edges | |
These methods are used for temporarily hiding edges. Edges are removed from the list of all edges and their corresponding adfjacency entries from the repsective adjacency lists, but the edge objects themselves are not destroyed; hiddenedges can later be reactivated with restoreEdge(). | |
| void | hideEdge (edge e) |
| Hides the edge e. | |
| void | restoreEdge (edge e) |
| Restores a hidden edge e. | |
| void | restoreAllEdges () |
| Restores all hidden edges. | |
Advanced modification methods | |
| virtual edge | split (edge e) |
| Splits edge e into two edges introducing a new node. | |
| void | unsplit (node u) |
| Undoes a split operation. | |
| virtual void | unsplit (edge eIn, edge eOut) |
| Undoes a split operation. | |
| node | splitNode (adjEntry adjStartLeft, adjEntry adjStartRight) |
| Splits a node while preserving the order of adjacency entries. | |
| node | contract (edge e) |
| Contracts edge e while preserving the order of adjacency entries. | |
| void | move (edge e, adjEntry adjSrc, Direction dirSrc, adjEntry adjTgt, Direction dirTgt) |
| Moves edge e to a different adjacency list. | |
| void | moveTarget (edge e, node w) |
| Moves the target node of edge e to node w. | |
| void | moveTarget (edge e, adjEntry adjTgt, Direction dir) |
| Moves the target node of edge e to a specific position in an adjacency list. | |
| void | moveSource (edge e, node w) |
| Moves the source node of edge e to node w. | |
| void | moveSource (edge e, adjEntry adjSrc, Direction dir) |
| Moves the source node of edge e to a specific position in an adjacency list. | |
| edge | searchEdge (node v, node w) const |
| Searches and returns an edge connecting nodes v and w. | |
| void | reverseEdge (edge e) |
| Reverses the edge e, i.e., exchanges source and target node. | |
| void | reverseAllEdges () |
| Reverses all edges in the graph. | |
| template<class NODELIST > | |
| void | collaps (NODELIST &nodes) |
| Collapses all nodes in the list nodes to the first node in the list. | |
| template<class ADJ_ENTRY_LIST > | |
| void | sort (node v, const ADJ_ENTRY_LIST &newOrder) |
| Sorts the adjacency list of node v according to newOrder. | |
| void | reverseAdjEdges (node v) |
| Reverses the adjacency list of v. | |
| void | moveAdj (adjEntry adjMove, Direction dir, adjEntry adjPos) |
| Moves adjacency entry adjMove before or after adjPos. | |
| void | moveAdjAfter (adjEntry adjMove, adjEntry adjAfter) |
| Moves adjacency entry adjMove after adjAfter. | |
| void | moveAdjBefore (adjEntry adjMove, adjEntry adjBefore) |
| Moves adjacency entry adjMove before adjBefore. | |
| void | reverseAdjEdges () |
| Reverses all adjacency lists. | |
| void | swapAdjEdges (adjEntry adj1, adjEntry adj2) |
| Exchanges two entries in an adjacency list. | |
Input and output | |
| bool | readGML (const char *fileName) |
| Reads a graph in GML format from file fileName. | |
| bool | readGML (istream &is) |
| Reads a graph in GML format from input stream is. | |
| void | writeGML (const char *fileName) const |
| Writes the graph in GML format to file fileName. | |
| void | writeGML (ostream &os) const |
| Writes the graph in GML format to output stream os. | |
| bool | readLEDAGraph (const char *fileName) |
| Reads a graph in LEDA format from file fileName. | |
| bool | readLEDAGraph (istream &is) |
| Read a graph in LEDA format from input stream is. | |
Miscellaneous | |
| int | genus () const |
| Returns the genus of the graph's embedding. | |
| bool | representsCombEmbedding () const |
| Returns true iff the graph represents a combinatorial embedding. | |
| bool | consistencyCheck () const |
| Checks the consistency of the data structure. | |
Registering arrays and observers | |
| ListIterator< NodeArrayBase * > | registerArray (NodeArrayBase *pNodeArray) const |
| Registers a node array. | |
| ListIterator< EdgeArrayBase * > | registerArray (EdgeArrayBase *pEdgeArray) const |
| Registers an edge array. | |
| ListIterator< AdjEntryArrayBase * > | registerArray (AdjEntryArrayBase *pAdjArray) const |
| Registers an adjEntry array. | |
| ListIterator< GraphObserver * > | registerStructure (GraphObserver *pStructure) const |
| Registers a graph observer (e.g. a ClusterGraph). | |
| void | unregisterArray (ListIterator< NodeArrayBase * > it) const |
| Unregisters a node array. | |
| void | unregisterArray (ListIterator< EdgeArrayBase * > it) const |
| Unregisters an edge array. | |
| void | unregisterArray (ListIterator< AdjEntryArrayBase * > it) const |
| unregisters an adjEntry array. | |
| void | unregisterStructure (ListIterator< GraphObserver * > it) const |
| Unregisters a graph observer. | |
| void | resetEdgeIdCount (int maxId) |
| Resets the edge id count to maxId. | |
Operators | |
| Graph & | operator= (const Graph &G) |
| Assignment operator. | |
Static Public Member Functions | |
| static int | nextPower2 (int start, int idCount) |
| Returns the smallest power of 2 which is >= 2^start and > idCount. | |
Protected Member Functions | |
| void | assign (const Graph &G, NodeArray< node > &mapNode, EdgeArray< edge > &mapEdge) |
| void | construct (const Graph &G, NodeArray< node > &mapNode, EdgeArray< edge > &mapEdge) |
| void | constructInitByActiveNodes (const List< node > &nodes, const NodeArray< bool > &activeNodes, NodeArray< node > &mapNode, EdgeArray< edge > &mapEdge) |
| void | constructInitByNodes (const Graph &G, const List< node > &nodes, NodeArray< node > &mapNode, EdgeArray< edge > &mapEdge) |
| Constructs a copy of the subgraph of G induced by nodes. | |
Private Member Functions | |
| void | copy (const Graph &G, NodeArray< node > &mapNode, EdgeArray< edge > &mapEdge) |
| void | copy (const Graph &G) |
| edge | createEdgeElement (node v, node w, adjEntry adjSrc, adjEntry adjTgt) |
| void | moveAdj (adjEntry adj, node w) |
| node | pureNewNode () |
| bool | readToEndOfLine (istream &is) |
| void | reinitArrays () |
| void | reinitStructures () |
| void | resetAdjEntryIndex (int newIndex, int oldIndex) |
Private Attributes | |
| int | m_edgeArrayTableSize |
| The current table size of edge arrays associated with this graph. | |
| int | m_edgeIdCount |
| The Index that will be assigned to the next created edge. | |
| GraphList< EdgeElement > | m_edges |
| The list of all edges. | |
| GraphList< EdgeElement > | m_hiddenEdges |
| The list of hidden edges. | |
| int | m_nEdges |
| The number of edges in the graph. | |
| int | m_nNodes |
| The number of nodes in the graph. | |
| int | m_nodeArrayTableSize |
| The current table size of node arrays associated with this graph. | |
| int | m_nodeIdCount |
| The Index that will be assigned to the next created node. | |
| GraphList< NodeElement > | m_nodes |
| The list of all nodes. | |
| ListPure< AdjEntryArrayBase * > | m_regAdjArrays |
| The registered adjEntry arrays. | |
| ListPure< EdgeArrayBase * > | m_regEdgeArrays |
| The registered edge arrays. | |
| ListPure< NodeArrayBase * > | m_regNodeArrays |
| The registered node arrays. | |
| ListPure< GraphObserver * > | m_regStructures |
| The registered graph structures. | |
Data type for general directed graphs (adjacency list representation).
Besides the usage of iteration macros defined in Graph_d.h, the following code is recommended for further iteration tasks.
Iteration over all outgoing edges e of node v:
Iteration over all ingoing edges e of node v:
Iteration over all nodes x reachable by an outgoing edge e of node v (without self-loops):
Iteration over all nodes x reachable by an outgoing edge e of node v (with self-loops):
Iteration over all nodes x reachable by an ingoing edge e of node v (without self-loops):
The type of nodes.
| vertex | |
| dummy | |
| generalizationMerger | |
| generalizationExpander | |
| highDegreeExpander | |
| lowDegreeExpander | |
| associationClass |
Reimplemented in ogdf::ExtendedNestingGraph.
| ogdf::Graph::Graph | ( | ) |
Constructs an empty graph.
| ogdf::Graph::Graph | ( | const Graph & | G | ) |
Constructs a graph that is a copy of G.
The constructor assures that the adjacency lists of nodes in the constructed graph are in the same order as the adjacency lists in G. This is in particular important when dealing with embedded graphs.
| G | is the graph that will be copied. |
|
virtual |
Destructor.
|
inline |
Returns a list with all edges adjacent to node v.
| EDGELIST | is the type of edge list, which is returned. |
| v | is the node whose incident edges are queried. |
| edges | is assigned the list of all edges incident to v (including incoming and outcoming edges). |
|
inline |
Returns a list with all entries in the adjacency list of node v.
| ADJLIST | is the type of adjacency entry list, which is returned. |
| v | is the node whose adjacency entries are queried. |
| entries | is assigned the list of all adjacency entries in the adjacency list of v. |
|
inline |
|
inline |
|
inline |
|
protected |
| edge ogdf::Graph::chooseEdge | ( | ) | const |
Returns a randomly chosen edge.
| node ogdf::Graph::chooseNode | ( | ) | const |
Returns a randomly chosen node.
| void ogdf::Graph::clear | ( | ) |
Removes all nodes and all edges from the graph.
|
inline |
Collapses all nodes in the list nodes to the first node in the list.
Parallel edges are removed.
| NODELIST | is the type of input node list. |
| nodes | is the list of nodes that will be collapsed. This list will be empty after the call. |
| bool ogdf::Graph::consistencyCheck | ( | ) | const |
Checks the consistency of the data structure.
Reimplemented in ogdf::GraphCopy, and ogdf::PlanRepExpansion.
|
protected |
|
protected |
|
protected |
Constructs a copy of the subgraph of G induced by nodes.
This method preserves the order in the adjacency lists, i.e., if G is embedded, its embedding induces the embedding of the copy.
Contracts edge e while preserving the order of adjacency entries.
| e | is the edge to be contracted. |
|
private |
|
private |
| void ogdf::Graph::delEdge | ( | edge | e | ) |
Removes edge e from the graph.
| e | is the egde that will be deleted. |
| void ogdf::Graph::delNode | ( | node | v | ) |
Removes node v and all incident edges from the graph.
| v | is the node that will be deleted. |
|
inline |
|
inline |
|
inline |
|
inline |
| int ogdf::Graph::genus | ( | ) | const |
Returns the genus of the graph's embedding.
The genus of a graph is defined as follows. Let \(G\) be a graph with \(m\) edges, \(n\) nodes, \(c\) connected components, \(nz\) isolated vertices, and \(fc\) face cycles. Then,
\[ genus(G) = (m/2 + 2c - n -nz -fc)/2 \]
| void ogdf::Graph::hideEdge | ( | edge | e | ) |
Hides the edge e.
The edge e is removed from the list of all edges and adjacency lists of nodes, but not deleted; e can be restored by calling restoreEdge(e).
| e | is the edge that will be hidden. |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
| void ogdf::Graph::move | ( | edge | e, |
| adjEntry | adjSrc, | ||
| Direction | dirSrc, | ||
| adjEntry | adjTgt, | ||
| Direction | dirTgt | ||
| ) |
Moves edge e to a different adjacency list.
The source adjacency entry of e is moved to the adjacency list containing adjSrc and is inserted before or after adjSrc, and its target adjacency entry to the adjacency list containing adjTgt and is inserted before or after adjTgt; e is afterwards an edge from owner(adjSrc) to owner(adjTgt).
| e | is the edge to be moved. |
| adjSrc | is the adjaceny entry before or after which the source adjacency entry of e will be inserted. |
| dirSrc | specifies if the source adjacency entry of e will be inserted before or after adjSrc. |
| adjTgt | is the adjaceny entry before or after which the target adjacency entry of e will be inserted. |
| dirTgt | specifies if the target adjacency entry of e will be inserted before or after adjTgt. |
Moves adjacency entry adjMove before or after adjPos.
| adjMove | is an entry in the adjacency list of a node in this graph. |
| adjPos | is an entry in the same adjacency list as adjMove. |
| dir | specifies if adjMove is moved before or after adjPos. |
Moves adjacency entry adjMove after adjAfter.
| adjMove | is an entry in the adjacency list of a node in this graph. |
| adjAfter | is an entry in the same adjacency list as adjMove. |
Moves adjacency entry adjMove before adjBefore.
| adjMove | is an entry in the adjacency list of a node in this graph. |
| adjBefore | is an entry in the same adjacency list as adjMove. |
Moves the source node of edge e to node w.
If e=(v,u) before, then e=(w,u) afterwards.
| e | is the edge whose source node is moved. |
| w | is the new source node of e. |
Moves the source node of edge e to a specific position in an adjacency list.
Let w be the node containing adjSrc. If e=(v,u) before, then e=(w,u) afterwards. Inserts the adjacency entry before or after adjSrc according to dir.
| e | is the edge whose source node is moved. |
| adjSrc | is the adjacency entry before or after which the source adjacency entry of e is inserted. |
| dir | specifies if the source adjacency entry of e is inserted before or after adjSrc. |
Moves the target node of edge e to node w.
If e=(v,u) before, then e=(v,w) afterwards.
| e | is the edge whose target node is moved. |
| w | is the new target node of e. |
Moves the target node of edge e to a specific position in an adjacency list.
Let w be the node containing adjTgt. If e=(v,u) before, then e=(v,w) afterwards. Inserts the adjacency entry before or after adjTgt according to dir.
| e | is the edge whose target node is moved. |
| adjTgt | is the adjacency entry before or after which the target adjacency entry of e is inserted. |
| dir | specifies if the target adjacency entry of e is inserted before or after adjTgt. |
Creates a new edge (v,w) and returns it.
| v | is the source node of the newly created edge. |
| w | is the target node of the newly created edge. |
Reimplemented in ogdf::GraphCopy, and ogdf::GraphCopySimple.
Creates a new edge (v,w) with predefined index and returns it.
| v | is the source node of the newly created edge. |
| w | is the target node of the newly created edge. |
| index | is the index that will be assigned to the newly created edge. |
| edge ogdf::Graph::newEdge | ( | adjEntry | adjSrc, |
| adjEntry | adjTgt, | ||
| Direction | dir = ogdf::after |
||
| ) |
Creates a new edge at predefined positions in the adjacency lists.
Let v be the node whose adjacency list contains adjSrc, and w the node whose adjacency list contains adjTgt. Then, the created edge is (v,w).
| adjSrc | is the adjacency entry after which the new edge is inserted in the adjacency list of v. |
| adjTgt | is the adjacency entry after which the new edge is inserted in the adjacency list of w. |
| dir | specifies if the edge is inserted before or after the given adjacency entries. |
Creates a new edge at predefined positions in the adjacency lists.
Let w be the node whose adjacency list contains adjTgt. Then, the created edge is (v,w).
| v | is the source node of the new edge; the edge is added at the end of the adjacency list of v. |
| adjTgt | is the adjacency entry after which the new edge is inserted in the adjacency list of w. |
Reimplemented in ogdf::GraphCopy.
Creates a new edge at predefined positions in the adjacency lists.
Let v be the node whose adjacency list contains adjSrc. Then, the created edge is (v,w).
| adjSrc | is the adjacency entry after which the new edge is inserted in the adjacency list of v. |
| w | is the source node of the new edge; the edge is added at the end of the adjacency list of w. |
Reimplemented in ogdf::GraphCopy.
| node ogdf::Graph::newNode | ( | ) |
Creates a new node and returns it.
Reimplemented in ogdf::GraphCopy, ogdf::GraphCopySimple, and ogdf::EdgeWeightedGraph< T >.
| node ogdf::Graph::newNode | ( | int | index | ) |
Creates a new node with predefined index and returns it.
| index | is the index that will be assigned to the newly created node. |
|
static |
Returns the smallest power of 2 which is >= 2^start and > idCount.
|
inline |
|
inline |
|
inline |
Assignment operator.
The assignment operature assures that the adjacency lists of nodes in the constructed graph are in the same order as the adjacency lists in G. This is in particular important when dealing with embedded graphs.
| G | is the graph to be copied. |
|
inline |
|
private |
| bool ogdf::Graph::readGML | ( | const char * | fileName | ) |
Reads a graph in GML format from file fileName.
| fileName | is the name of the input file. |
| bool ogdf::Graph::readGML | ( | istream & | is | ) |
Reads a graph in GML format from input stream is.
| is | is the input file stream. |
| bool ogdf::Graph::readLEDAGraph | ( | const char * | fileName | ) |
Reads a graph in LEDA format from file fileName.
| fileName | is the name of the input file. |
| bool ogdf::Graph::readLEDAGraph | ( | istream & | is | ) |
Read a graph in LEDA format from input stream is.
| is | is the input file stream. |
|
private |
| ListIterator<NodeArrayBase*> ogdf::Graph::registerArray | ( | NodeArrayBase * | pNodeArray | ) | const |
Registers a node array.
| pNodeArray | is a pointer to the node array's base; this node array must be associated with this graph. |
| ListIterator<EdgeArrayBase*> ogdf::Graph::registerArray | ( | EdgeArrayBase * | pEdgeArray | ) | const |
Registers an edge array.
| pEdgeArray | is a pointer to the edge array's base; this edge array must be associated with this graph. |
| ListIterator<AdjEntryArrayBase*> ogdf::Graph::registerArray | ( | AdjEntryArrayBase * | pAdjArray | ) | const |
Registers an adjEntry array.
| pAdjArray | is a pointer to the adjacency entry array's base; this adjacency entry array must be associated with this graph. |
| ListIterator<GraphObserver*> ogdf::Graph::registerStructure | ( | GraphObserver * | pStructure | ) | const |
Registers a graph observer (e.g. a ClusterGraph).
| pStructure | is a pointer to the graph observer that shall be registered; this graph observer must be associated with this graph. |
|
private |
|
private |
|
inline |
|
private |
| void ogdf::Graph::resetEdgeIdCount | ( | int | maxId | ) |
Resets the edge id count to maxId.
The next edge will get edge id maxId+1. Use this function with caution! It is provided as an efficient way to reduce the edge id count. The Graph class increments the edge id count whenever an edge is created; free edge ids resulting from removing edges are not reused (there is not something like a freelist).
This function is , e.g., useful, when a lot of edges has been added and all these edges are removed again (without creating other new edges meanwile). Then, it is safe to reduce the edge id count to the value it had before, cf. the following code snippet:
Reducing the edge id count will reduce the memory consumption of edge arrays associated with the graph.
| maxId | is an upper bound of the edge ids in the graph. |
| void ogdf::Graph::restoreAllEdges | ( | ) |
Restores all hidden edges.
| void ogdf::Graph::restoreEdge | ( | edge | e | ) |
Restores a hidden edge e.
| e | is the hidden edge that will be restored. |
|
inline |
| void ogdf::Graph::reverseAdjEdges | ( | ) |
Reverses all adjacency lists.
| void ogdf::Graph::reverseAllEdges | ( | ) |
Reverses all edges in the graph.
| void ogdf::Graph::reverseEdge | ( | edge | e | ) |
Reverses the edge e, i.e., exchanges source and target node.
| e | is the edge to be reveresed. |
Searches and returns an edge connecting nodes v and w.
| v | is the source node of the edge to be searched. |
| w | is the target node of the edge to be searched. |
|
inline |
Sorts the adjacency list of node v according to newOrder.
| ADJ_ENTRY_LIST | is the type of the input adjacency entry list. |
| v | is the node whose adjacency list will be sorted. |
| newOrder | is the list of adjacency entries of v in the new order. |
Splits edge e into two edges introducing a new node.
Let e=(v,w). Then, the resulting two edges are e=(v,u) and e'=(u,w), where u is a new node.
| e | is the edge to be split. |
Reimplemented in ogdf::PlanRep, ogdf::GraphCopy, ogdf::PlanRepExpansion, ogdf::PlanRepUML, ogdf::PlanRepInc, and ogdf::ClusterPlanRep.
Splits a node while preserving the order of adjacency entries.
This method splits a node v into two nodes vl and vr. Node vl receives all adjacent edges of v from adjStartLeft until the edge preceding adjStartRight, and vr the remaining nodes (thus adjStartRight is the first edge that goes to vr). The order of adjacency entries is preserved. Additionally, a new edge (vl,vr) is created, such that this edge is inserted before adjStartLeft and adjStartRight in the the adjacency lists of vl and vr.
Node v is modified to become node vl, and node vr is returned. This method is useful when modifying combinatorial embeddings.
| adjStartLeft | is the first entry that goes to the left node. |
| adjStartRight | is the first entry that goes to the right node. |
| void ogdf::Graph::unregisterArray | ( | ListIterator< NodeArrayBase * > | it | ) | const |
Unregisters a node array.
| it | is an iterator pointing to the entry in the list of registered node arrays for the node array to be unregistered. |
| void ogdf::Graph::unregisterArray | ( | ListIterator< EdgeArrayBase * > | it | ) | const |
Unregisters an edge array.
| it | is an iterator pointing to the entry in the list of registered edge arrays for the edge array to be unregistered. |
| void ogdf::Graph::unregisterArray | ( | ListIterator< AdjEntryArrayBase * > | it | ) | const |
unregisters an adjEntry array.
| it | is an iterator pointing to the entry in the list of registered adjacency entry arrays for the adjacency entry array to be unregistered. |
| void ogdf::Graph::unregisterStructure | ( | ListIterator< GraphObserver * > | it | ) | const |
Unregisters a graph observer.
| it | is an iterator pointing to the entry in the list of registered graph observers for the graph observer to be unregistered. |
| void ogdf::Graph::unsplit | ( | node | u | ) |
Undoes a split operation.
Removes node u by joining the two edges adjacent to u. The outgoing edge of u is removed and the incoming edge e is reused
| u | is the node to be unsplit. |
Undoes a split operation.
For two edges eIn = (x,u) and eOut = (u,y), removes node u by joining eIn and eOut. Edge eOut is removed and eIn is reused.
| eIn | is the (only) incoming edge of u. |
| eOut | is the (only) outgoing edge of u. |
Reimplemented in ogdf::GraphCopy, and ogdf::PlanRepExpansion.
| void ogdf::Graph::writeGML | ( | const char * | fileName | ) | const |
Writes the graph in GML format to file fileName.
| fileName | is the name of the output file. |
Reimplemented in ogdf::CompactionConstraintGraph< ATYPE >, and ogdf::CompactionConstraintGraphBase.
| void ogdf::Graph::writeGML | ( | ostream & | os | ) | const |
Writes the graph in GML format to output stream os.
| os | is the output file stream. |
Reimplemented in ogdf::CompactionConstraintGraph< ATYPE >, and ogdf::CompactionConstraintGraphBase.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |
|
mutableprivate |