68 OGDF_ASSERT(c->graphOf() == m_isContained.graphOf());
69 bool &isContained = m_isContained[c];
70 if (isContained ==
false) {
72 m_clusters.pushFront(c);
85 for(it = m_clusters.begin(); it.
valid(); ++it) {
86 m_isContained[*it] =
false;
99 OGDF_ASSERT(c->graphOf() == m_isContained.graphOf());
100 return m_isContained[c];
152 itV = m_clusters.pushBack(c);
179 for(it = m_clusters.begin(); it.
valid(); ++it) {
194 return m_it[c].valid();
247 itV = m_clusters.pushBack(c);
274 for(it = m_clusters.begin(); it.
valid(); ++it) {
289 return m_it[c].valid();
297 return m_clusters.size();
void insert(cluster c)
Inserts cluster c into S.
ListPure< cluster > m_clusters
The list of clusters contained in S.
bool valid() const
Returns true iff the iterator points to an element.
ClusterArray< ListIterator< cluster > > m_it
m_it[c] contains the list iterator pointing to c if c is contained in S, an invalid list iterator oth...
ClusterSet(const ClusterGraph &C)
Creates an empty cluster set associated with clustered graph C.
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
SListPure< cluster > m_clusters
The list of clusters contained in S.
void insert(cluster c)
Inserts cluster c into S.
ClusterSetPure(const ClusterGraph &C)
Creates an empty cluster set associated with clustered graph C.
Encapsulates a pointer to an ogdf::SList element.
int size() const
Returns the size of S.
void clear()
Removes all clusters from S.
const List< cluster > & clusters() const
Returns a reference to the list of clusters contained in S.
void clear()
Removes all clusters from S.
Representation of clustered graphs.
bool isMember(cluster c) const
Returns true if cluster c is contained in S, false otherwise.
const SListPure< cluster > & clusters() const
Returns a reference to the list of clusters contained in S.
Doubly linked lists (maintaining the length of the list).
ClusterArray< bool > m_isContained
m_isContained[c] is true iff c is contained in S
Encapsulates a pointer to a list element.
void insert(cluster c)
Inserts cluster c into S.
List< cluster > m_clusters
The list of clusters contained in S.
bool isMember(cluster c) const
Returns true if cluster c is contained in S, false otherwise.
const ListPure< cluster > & clusters() const
Returns a reference to the list of clusters contained in S.
Representation of clusters in a clustered graph.
ClusterSetSimple(const ClusterGraph &C)
Creates an empty cluster set associated with clustered graph C.
Declaration and implementation of ClusterArray class.
The namespace for all OGDF objects.
ClusterArray< ListIterator< cluster > > m_it
m_it[c] contains the list iterator pointing to c if c is contained in S, an invalid list iterator oth...
bool isMember(cluster c) const
Returns true if cluster c is contained in S, false otherwise.
void clear()
Removes all clusters from S.
bool valid() const
Returns true iff the iterator points to an element.
#define OGDF_ASSERT(expr)
Assert condition expr. See doc/build.md for more information.
Declaration of doubly linked lists and iterators.