Open
Graph Drawing
Framework

 v. snapshot-2017-02-16
 

ogdf::FaceSetPure Class Reference

Face sets. More...

#include <ogdf/basic/FaceSet.h>

Public Member Functions

 FaceSetPure (const CombinatorialEmbedding &E)
 Creates an empty node set associated with combinatorial embedding E. More...
 
 ~FaceSetPure ()
 
void clear ()
 Removes all faces from S. More...
 
const ListPure< face > & faces () const
 Returns a reference to the list of faces contained in S. More...
 
void insert (face f)
 Inserts face f into S. More...
 
bool isMember (face f) const
 Returns true if face f is contained in S, false otherwise. More...
 
void remove (face f)
 Removes face f from S. More...
 

Private Attributes

ListPure< face > m_faces
 The list of faces contained in S. More...
 
FaceArray< ListIterator< face > > m_it
 m_it[f] contains the list iterator pointing to f if f is contained in S, an invalid list iterator otherwise. More...
 

Detailed Description

Face sets.

A face set maintains a subset S of the faces contained in an associated combinatorial embedding. This kind of face set provides efficient operations for testing membership, insertion and deletion of elements, and clearing the set.

In contrast to FaceSet, a FaceSetPure does not provide efficient access to the number of faces stored in the set.

See also

Definition at line 138 of file FaceSet.h.

Constructor & Destructor Documentation

◆ FaceSetPure()

ogdf::FaceSetPure::FaceSetPure ( const CombinatorialEmbedding &  E)
inlineexplicit

Creates an empty node set associated with combinatorial embedding E.

Definition at line 141 of file FaceSet.h.

◆ ~FaceSetPure()

ogdf::FaceSetPure::~FaceSetPure ( )
inline

Definition at line 144 of file FaceSet.h.

Member Function Documentation

◆ clear()

void ogdf::FaceSetPure::clear ( )
inline

Removes all faces from S.

After this operation, S is empty and still associated with the same combinatorial embedding. The runtime of this operations is O(k), where k is the number of faces in S before this operation.

Definition at line 181 of file FaceSet.h.

◆ faces()

const ListPure<face>& ogdf::FaceSetPure::faces ( ) const
inline

Returns a reference to the list of faces contained in S.

This list can be used for iterating over all faces in S.

Definition at line 204 of file FaceSet.h.

◆ insert()

void ogdf::FaceSetPure::insert ( face  f)
inline

Inserts face f into S.

This operation has constant runtime.

Precondition
f is a face in the associated combinatorial embedding.

Definition at line 152 of file FaceSet.h.

◆ isMember()

bool ogdf::FaceSetPure::isMember ( face  f) const
inline

Returns true if face f is contained in S, false otherwise.

This operation has constant runtime.

Precondition
f is a face in the associated combinatorial embedding.

Definition at line 195 of file FaceSet.h.

◆ remove()

void ogdf::FaceSetPure::remove ( face  f)
inline

Removes face f from S.

This operation has constant runtime.

Precondition
f is a face in the associated combinatorial embedding.

Definition at line 165 of file FaceSet.h.

Member Data Documentation

◆ m_faces

ListPure<face> ogdf::FaceSetPure::m_faces
private

The list of faces contained in S.

Definition at line 214 of file FaceSet.h.

◆ m_it

FaceArray<ListIterator<face> > ogdf::FaceSetPure::m_it
private

m_it[f] contains the list iterator pointing to f if f is contained in S, an invalid list iterator otherwise.

Definition at line 211 of file FaceSet.h.


The documentation for this class was generated from the following file: