Regina Calculation Engine
|
Helper class for storing the necessary faces of a boundary component of a dim-dimensional triangulation. More...
#include <triangulation/detail/boundarycomponent.h>
Public Member Functions | |
size_t | size () const |
Returns the number of (dim-1)-faces in this boundary component. More... | |
size_t | countRidges () const |
Returns the number of (dim-2)-faces in this boundary component. More... | |
const std::vector< Face< dim, dim-1 > * > & | facets () const |
Returns all (dim-1)-faces in this boundary component. More... | |
Face< dim, dim-1 > * | facet (size_t index) const |
Returns the requested (dim-1)-face in this boundary component. More... | |
Triangulation< dim > * | triangulation () const |
Returns the triangulation to which this boundary component belongs. More... | |
Component< dim > * | component () const |
Returns the connected component of the triangulation to which this boundary component belongs. More... | |
BoundaryComponentFaceStorage (const BoundaryComponentFaceStorage &)=delete | |
BoundaryComponentFaceStorage & | operator= (const BoundaryComponentFaceStorage &)=delete |
Static Public Attributes | |
static constexpr bool | allFaces = false |
A compile-time constant indicating whether this boundary component class stores all lower-dimensional faces (true ), or only faces of dimension dim-1 (false ). More... | |
Protected Member Functions | |
BoundaryComponentFaceStorage () | |
Default constructor that initialises the number of ridges to zero. More... | |
void | push_back (Face< dim, dim-1 > *face) |
Pushes the given face onto the end of the list of (dim-1)-faces of this boundary component. More... | |
void | push_back (Face< dim, dim-2 > *) |
Increments the number of (dim-2)-faces in this boundary component. More... | |
template<int subdim> | |
void | push_back (Face< dim, subdim > *) |
Does nothing, since this boundary component does not store lower-dimensional faces. More... | |
void | reorderAndRelabelFaces (Triangulation< dim-1 > *) const |
Reorders all lower-dimensional faces of the given triangulation so that they appear in the same order as the corresponding faces of this boundary component, and relabels these faces so that their vertices are numbered in a corresponding way. More... | |
Protected Attributes | |
std::vector< Face< dim, dim-1 > * > | facets_ |
List of all (dim-1)-simplices in the boundary component. More... | |
size_t | nRidges_ |
The number of (dim-2)-faces in the boundary component. More... | |
Helper class for storing the necessary faces of a boundary component of a dim-dimensional triangulation.
See the general BoundaryComponentFaceStorage template notes for further details.
This specialisation is used for dimensions in which only (dim-1)-dimensional faces are stored. It therefore removes the member functions for accessing lower-dimensional faces.
|
inlineprotected |
Default constructor that initialises the number of ridges to zero.
|
inline |
Returns the connected component of the triangulation to which this boundary component belongs.
|
inline |
Returns the number of (dim-2)-faces in this boundary component.
If this is an ideal or invalid vertex boundary component, then this routine will return 0.
|
inline |
Returns the requested (dim-1)-face in this boundary component.
These are the top-dimensional faces for a real boundary component.
Note that the index of a face in the boundary component need not be the index of the same face in the overall triangulation. However, the index of each (dim-1)-face in this boundary component will match the index of the corresponding top-dimensional simplex in the (dim-1)-manifold triangulation returned by build().
index | the index of the desired face, ranging from 0 to size()-1 inclusive. |
|
inline |
Returns all (dim-1)-faces in this boundary component.
The reference that is returned will remain valid only for as long as this boundary component object exists. In particular, the reference will become invalid any time that the triangulation changes (since all boundary component objects will be destroyed and others rebuilt in their place).
@return the list of all (<i>dim</i>-1)-faces.
|
inlineprotected |
Pushes the given face onto the end of the list of (dim-1)-faces of this boundary component.
This class does not take ownership of the given face.
face | the face to append to the list. |
|
inlineprotected |
Increments the number of (dim-2)-faces in this boundary component.
Since this boundary component class does not store any lower-dimensional faces, this routine does not store the given face.
|
inlineprotected |
Does nothing, since this boundary component does not store lower-dimensional faces.
subdim | the dimension of the given face. This must be between 0 and dim-3 inclusive. |
|
inlineprotected |
Reorders all lower-dimensional faces of the given triangulation so that they appear in the same order as the corresponding faces of this boundary component, and relabels these faces so that their vertices are numbered in a corresponding way.
This affects all faces of dimensions 0,...,(dim-2).
In this specialised class template, this function does nothing because faces of dimension 0,...,(dim-2) are not stored.
|
inline |
Returns the number of (dim-1)-faces in this boundary component.
These are the top-dimensional faces for a real boundary component.
|
inline |
Returns the triangulation to which this boundary component belongs.
|
static |
A compile-time constant indicating whether this boundary component class stores all lower-dimensional faces (true
), or only faces of dimension dim-1 (false
).
This is a compile-time constant only, with no linkage - any attempt to create a reference or pointer to it will give a linker error.
|
protected |
List of all (dim-1)-simplices in the boundary component.
|
protected |
The number of (dim-2)-faces in the boundary component.