Regina Calculation Engine
Protected Types | Protected Member Functions | List of all members
regina::detail::FaceListSuite< dim, subdim > Class Template Reference

Internal class that helps a triangulation store its lists of faces. More...

#include <triangulation/detail/triangulation.h>

Inheritance diagram for regina::detail::FaceListSuite< dim, subdim >:
regina::FaceList< dim, subdim >

Protected Types

typedef std::vector< Face< dim, subdim > * >::const_iterator Iterator
 An iterator type for iterating through this list of faces. More...
 

Protected Member Functions

void deleteFaces ()
 Deletes all faces of dimension subdim and below. More...
 
void swapFaces (FaceListSuite< dim, subdim > &other)
 Swaps all faces of dimension subdim and below with those of the given triangulation. More...
 
void fillFVector (std::vector< size_t > &result) const
 Fills the given vector with the first (subdim + 1) elements of the f-vector. More...
 
bool sameFVector (const FaceListSuite< dim, subdim > &other) const
 Tests whether this and the given triangulation have the same number of k-faces, for each facial dimension ksubdim. More...
 
bool sameDegrees (const FaceListSuite< dim, subdim > &other) const
 Tests whether this and the given triangulation have the same k-face degree sequences, for each facial dimension ksubdim. More...
 
size_t size () const
 Returns the number of subdim-faces in the triangulation. More...
 
Face< dim, subdim > * operator[] (size_t index) const
 Returns the requested subdim-face. More...
 
Iterator begin () const
 Returns an iterator pointing to the first subdim-face. More...
 
Iterator end () const
 Returns an iterator pointing beyond the last subdim-face. More...
 
void push_back (Face< dim, subdim > *face)
 Pushes the given face onto the end of this list. More...
 
void destroy ()
 Destroys all faces in this list, and clears the list itself. More...
 
void swap (FaceList< dim, subdim > &other)
 Swaps all faces in this list with those in the given list. More...
 
bool sameDegrees (const FaceList< dim, subdim > &other) const
 Tests whether this and the given triangulation have the same subdim-face degree sequences. More...
 
template<typename Iterator >
void reorderFaces (Iterator begin, Iterator end)
 Reorders this list of faces. More...
 

Detailed Description

template<int dim, int subdim>
class regina::detail::FaceListSuite< dim, subdim >

Internal class that helps a triangulation store its lists of faces.

This class is used with dim-dimensional triangulations. It provides storage for all faces of dimension subdim and below. The triangulation class Triangulation<dim> then derives from FaceListSuite<dim, dim-1>.

Member Function Documentation

◆ deleteFaces()

template<int dim>
void regina::detail::FaceListSuite< dim >::deleteFaces ( )
inlineprotected

Deletes all faces of dimension subdim and below.

This routine destroys the corresponding Face objects and clears the lists that contain them.

◆ fillFVector()

template<int dim>
void regina::detail::FaceListSuite< dim >::fillFVector ( std::vector< size_t > &  result) const
inlineprotected

Fills the given vector with the first (subdim + 1) elements of the f-vector.

Specifically, this routine pushes the values f[0], ..., f[subdim] onto the end of the given vector, where f[k] denotes the number of k-faces that this object stores.

Parameters
resultthe vector in which the results will be placed.

◆ sameDegrees()

template<int dim, int subdim>
bool regina::detail::FaceListSuite< dim >::sameDegrees ( const FaceListSuite< dim, subdim > &  other) const
inlineprotected

Tests whether this and the given triangulation have the same k-face degree sequences, for each facial dimension ksubdim.

For the purposes of this routine, degree sequences are considered to be unordered.

Precondition
This and the given triangulation are known to have the same number of k-faces as each other, for each facial dimension ksubdim.
Parameters
otherthe triangulation to compare against this.
Returns
true if and only if all degree sequences considered are equal.

◆ sameFVector()

template<int dim, int subdim>
bool regina::detail::FaceListSuite< dim >::sameFVector ( const FaceListSuite< dim, subdim > &  other) const
inlineprotected

Tests whether this and the given triangulation have the same number of k-faces, for each facial dimension ksubdim.

Parameters
otherthe triangulation to compare against this.
Returns
true if and only if the face counts considered are identical for both triangluations.

◆ swapFaces()

template<int dim, int subdim>
void regina::detail::FaceListSuite< dim >::swapFaces ( FaceListSuite< dim, subdim > &  other)
inlineprotected

Swaps all faces of dimension subdim and below with those of the given triangulation.

Parameters
otherthe face storage for the triangulation whose faces are to be swapped with this.

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

Copyright © 1999-2021, The Regina development team
This software is released under the GNU General Public License, with some additional permissions; see the source code for details.
For further information, or to submit a bug or other problem, please contact Ben Burton (bab@maths.uq.edu.au).